Package | com.whirled.game |
Class | public class ServicesSubControl |
Inheritance | ServicesSubControl ![]() ![]() ![]() |
Property | Defined by | ||
---|---|---|---|
bags : BagsSubControl
[read-only]
Access the 'bags' subcontrol.
| ServicesSubControl |
Method | Defined by | ||
---|---|---|---|
![]() |
addEventListener(type:String, listener:Function, useCapture:Boolean = false, priority:int = 0, useWeakReference:Boolean = false):void
Registers an event listener.
| AbstractControl | |
checkDictionaryWord(locale:String, dictionary:String, word:String, callback:Function):void
Checks to see if the dictionary for the given locale contains the given word.
| ServicesSubControl | ||
![]() |
doBatch(fn:Function, ... args):void
Execute the specified function as a batch of commands that will be sent to the server
together.
| AbstractSubControl | |
getDictionaryLetters(locale:String, dictionary:String, count:int, callback:Function):void
Requests a list of random letters from the dictionary service.
| ServicesSubControl | ||
getDictionaryWords(locale:String, dictionary:String, count:int, callback:Function):void
Requests a set of random words from the dictionary service.
| ServicesSubControl | ||
![]() |
isConnected():Boolean
Are we connected and running inside the whirled environment, or has someone just
loaded up our SWF by itself?
| AbstractSubControl | |
![]() |
removeEventListener(type:String, listener:Function, useCapture:Boolean = false):void
Unregisters an event listener.
| AbstractControl | |
startTicker(tickerName:String, msOfDelay:int):void
Start the ticker with the specified name.
| ServicesSubControl | ||
stopTicker(tickerName:String):void
Stop the specified ticker.
| ServicesSubControl |
bags | property |
bags:BagsSubControl
[read-only]Access the 'bags' subcontrol.
Implementation public function get bags():BagsSubControl
checkDictionaryWord | () | method |
public function checkDictionaryWord(locale:String, dictionary:String, word:String, callback:Function):void
Checks to see if the dictionary for the given locale contains the given word.
Parameterslocale:String — RFC 3066 string that represents language settings, such as en-US.
|
|
dictionary:String — the dictionary to use, or null for the default.
TODO: document possible parameters.
|
|
word:String — the string contains the word to be checked
|
|
callback:Function — the function that will process the results, of the form:
function (word :String, result :Boolean) :voidwhere word is a copy of the word that was requested, and result specifies whether the word is valid given language settings |
getDictionaryLetters | () | method |
public function getDictionaryLetters(locale:String, dictionary:String, count:int, callback:Function):void
Requests a list of random letters from the dictionary service. The letters will arrive in a separate message with the specified key, as an array of strings. The returned letters aren't necessarily unique; there may be repeats in the array.
Parameterslocale:String — RFC 3066 string that represents language settings, such as en-US.
|
|
dictionary:String — the dictionary to use, or null for the default.
TODO: document possible parameters.
|
|
count:int — the number of letters to be produced
|
|
callback:Function — the function that will process the results, of the form:
function (letters :Array) :voidwhere letters is an array of strings containing letters for the given language settings (potentially empty). |
getDictionaryWords | () | method |
public function getDictionaryWords(locale:String, dictionary:String, count:int, callback:Function):void
Requests a set of random words from the dictionary service.
Parameterslocale:String — RFC 3066 string that represents language settings, such as en-US.
|
|
dictionary:String — the dictionary to use, or null for the default.
TODO: document possible parameters.
|
|
count:int — the number of words to be produced, to a maximum of 100.
|
|
callback:Function — the function that will process the results, of the form:
function (words :Array) :voidwhere words is an array of strings. This array will not contain repeated elements. If an error occured, this array will be empty. |
startTicker | () | method |
public function startTicker(tickerName:String, msOfDelay:int):void
Start the ticker with the specified name. The ticker will deliver messages (resulting in a MessageReceivedEvent being dispatched on the 'net' control) to all connected clients, at the specified delay. The value of each message is a single integer, starting with 0 and increasing by 1 with each messsage. Note: you may have a maximum of 3 tickers, and the minimum delay is 50ms. Note: When your game transitions to the GAME_ENDED state, all tickers are automatically stopped.
ParameterstickerName:String |
|
msOfDelay:int |
stopTicker | () | method |
public function stopTicker(tickerName:String):void
Stop the specified ticker.
ParameterstickerName:String |