You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: api_op_DescribeGameServerInstances.go
    path of file: ./repos/aws-sdk-go-v2/service/gamelift
    
    the code of the file until where you have to start completion: // Code generated by smithy-go-codegen DO NOT EDIT.

package gamelift

import (
	"context"
	"fmt"
	awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
	"github.com/aws/aws-sdk-go-v2/service/gamelift/types"
	"github.com/aws/smithy-go/middleware"
	smithyhttp "github.com/aws/smithy-go/transport/http"
)

// This operation is used with the Amazon GameLift FleetIQ solution and game
// server groups. Retrieves status information about the Amazon EC2 instances
// assoc
    
func NewDescribeGameServerInstancesPaginator(client DescribeGameServerInstancesAPIClient, params *DescribeGameServerInstancesInput, optFns ...func(*DescribeGameServerInstancesPaginatorOptions)) *DescribeGameServerInstancesPaginator {
	if params == nil {
		params = &DescribeGameServerInstancesInput{}
	}

	options := DescribeGameServerInstancesPaginatorOptions{}
	if params.Limit != nil {
		options.Limit = *params.Limit
	}

	for _, fn := range optFns {
		fn(&options)
	}

	return &DescribeGameServerInstancesPaginator{
		options:   options,
		client:    client,
		params:    params,
		firstPage: true,
		nextToken: params.NextToken,
	}
}