I am using xPaw's Minecraft Query:
<https://github.com/xPaw/PHP-Minecraft-Query>

I made a function to it so I can connect to our servers, however the problem is that we have multiple servers, so I have to copy and paste the function and rename the function and other parts of the code so it can connect to the other servers.

```
function get_MQ_Query() {
  define( 'MQ_SERVER_ADDR', '1stserver.com' );
  define( 'MQ_SERVER_PORT', 25565 );
  define( 'MQ_TIMEOUT', 1 );

  // require bloginfo('template_url') . 'inc/avatars/MinecraftQuery.class.php';
  require __DIR__ . '/mcQuery/MinecraftQuery.class.php';

  // Display everything in browser, because some people can't look in logs for errors
  Error_Reporting( E_ALL | E_STRICT );
  Ini_Set( 'display_errors', true );

  $Timer = MicroTime( true );
  $Query = new MinecraftQuery( );

  try
  {
    $Query->Connect( MQ_SERVER_ADDR, MQ_SERVER_PORT, MQ_TIMEOUT );
  }
  catch( MinecraftQueryException $e )
  {
    $Error = $e->getMessage();
   echo 'error. <br>'. $Error;
  }
  return $Query;
}

```

I'd like to pass an array to the class and call it 

```
$mcQuery = new mcQuery();
// Define servers
$server = [
    '1server' => '1.server.com',
    '2server' => '2.server.com',
    '3server' => '3.server.com',
    '4server' => '4.server.com'
];

```

Calling it would look like this:

```
Status: <?php echo $mcQuery->getStatus($server['1server']); ?>

```

I'm not sure how to get around into doing this though. How can I get something like that?