Packagecom.whirled.game
Classpublic class SeatingSubControl
InheritanceSeatingSubControl Inheritance AbstractSubControl Inheritance AbstractControl Inheritance flash.events.EventDispatcher

Access seating information for a seated game. Do not instantiate this class directly, access it via GameControl.game.seating.



Public Methods
 MethodDefined by
 Inherited
addEventListener(type:String, listener:Function, useCapture:Boolean = false, priority:int = 0, useWeakReference:Boolean = false):void
Registers an event listener.
AbstractControl
 Inherited
doBatch(fn:Function, ... args):void
Execute the specified function as a batch of commands that will be sent to the server together.
AbstractSubControl
  
A convenient function to get our own player position, or -1 if we're not a player.
SeatingSubControl
  
getPlayerIds():Array
Get all the players at the table, in their seated position.
SeatingSubControl
  
Get the names of the seated players, in the order of their seated position.
SeatingSubControl
  
getPlayerPosition(playerId:int):int
Get the player's position (seated index), or -1 if not a player.
SeatingSubControl
 Inherited
isConnected():Boolean
Are we connected and running inside the whirled environment, or has someone just loaded up our SWF by itself?
AbstractSubControl
 Inherited
removeEventListener(type:String, listener:Function, useCapture:Boolean = false):void
Unregisters an event listener.
AbstractControl
Events
 EventSummaryDefined by
 Inherited Event.UNLOAD Dispatched when the SWF using this control has been unloaded.AbstractControl
Method detail
getMyPosition()method
public function getMyPosition():int

A convenient function to get our own player position, or -1 if we're not a player.

Returns
int
getPlayerIds()method 
public function getPlayerIds():Array

Get all the players at the table, in their seated position. Note that the number of seats never changes during a game, even as players come and go. Absent players will be represented by a 0.

Returns
Array — an Array of ints.
getPlayerNames()method 
public function getPlayerNames():Array

Get the names of the seated players, in the order of their seated position. Note that the number of seats never changes during a game, even as players come and go. Absent players will have a name of null.

Returns
Array — an Array of Strings.
getPlayerPosition()method 
public function getPlayerPosition(playerId:int):int

Get the player's position (seated index), or -1 if not a player.

Parameters
playerId:int

Returns
int