This class provides all the settings required to create an SFSGame(*).Namespace: Sfs2X.Requests.Game
Assembly: SmartFox2 (in SmartFox2.dll) Version: 0.9.14.0
public class SFSGameSettings : RoomSettings
The SFSGame(*) object extends the Room object providing new advanced features such as Player matching, Game invitations, public and private Games, quick game joining etc... (*) = the SFSGame class exists only on the server side as extension of the SFSRoom class. On the client side it's seen as a regular Room.
OverviewThis is a quick overview of the settings that you can use to setup an SFSGame
- isGamePublic: a public game can be joined by any Player whose variables match the SFSGame Player Match Expression. Private games are based on invitations sent by the Game creator.
- minPlayersToStartGame: the minimum number of players to start the game.
- invitedPlayers: (private games only) a list of players invited in the Game
- searchableRooms: (private games only) a list of Rooms where the Game API can search for more players to invite. The API will look for more players if the number of people invited is smaller than the minPlayersToStartGame. This way you can add your friends to the game and let the system find more players to start it.
- leaveLastJoinedRoom: auto-remove players from their previous Room after successful join
- playerMatchExpression: an expression to match players willing to play the game, by default no expression is used
- spectatorMatchExpression: an expression to match spectators willing to play the game, by default no expression is used
- invitationExpiryTime: the amount of time allowed for invited players to accept / refuse
- invitationParameters: optional custom invitation parameters.These could provide details about the inviter, the game, an invitation message etc...
- notifyGameStartedViaRoomVariable: automatically update a reserved Room Variable to signal that the game is started/stopped. The Room variable uses the global setting to be broadcast outside of the Room. This can be used on the client side to show the game state in your game list.