Packagestencyl.api.engine.behavior
Classpublic dynamic class SceneScript
InheritanceSceneScript Inheritance Script Inheritance Object



Public Properties
 PropertyDefined By
 InheritedBACK : int = 2
[static]
Script
 InheritedFRONT : int = 0
[static]
Script
 InheritedGET_SCORES_URL : String = http://www.stencyl.com/v10/api/score/getTopEntries/
[static]
Script
 InheritedGET_SCORE_URL : String = http://www.stencyl.com/v10/api/score/getForCurrentPlayer/
[static]
Script
 InheritedlastCreatedActor : Actor = null
[static]
Script
 InheritedlastCreatedJoint : b2Joint = null
[static]
Script
 InheritedlastCreatedLabel : Label = null
[static]
Script
 InheritedlastCreatedPanel : Panel = null
[static]
Script
 InheritedlastCreatedRegion : Region = null
[static]
Script
 InheritedlastCreatedTerrainRegion : TerrainRegion = null
[static]
Script
 InheritedMIDDLE : int = 1
[static]
Script
 Inheritedmpx : Number = 0
[static]
Script
 Inheritedmpy : Number = 0
[static]
Script
 Inheritedmrx : Number = 0
[static]
Script
 Inheritedmry : Number = 0
[static]
Script
 Inheritedscene : GameState
Script
 InheritedSUBMIT_SCORE_URL : String = http://www.stencyl.com/v10/api/score/submit/
[static]
Script
 Inheritedwrapper : Behavior
Script
Public Methods
 MethodDefined By
  
SceneScript
 Inherited
abortTween(target:Object):void
[static]
Script
 Inherited
AddUnsigned(lX:*, lY:*):*
Script
 Inherited
adjustLocationForAllSounds(time:uint, volume:Number):void
Script
 Inherited
asBoolean(o:*):Boolean
[static] Accepts a literal boolean or String boolean.
Script
 Inherited
Script
 Inherited
Script
 Inherited
ConvertToWordArray(string:String):*
Script
 Inherited
createActor(type:ActorType, x:Number, y:Number, layerConst:int):Actor
Creates an actor of the given type at the given location and layer.
Script
 Inherited
createActorInNextScene(type:ActorType, x:Number, y:Number, layerConst:int):void
Creates an actor of the given type at the given location and layer when the next scene begins.
Script
 Inherited
createBoxRegion(x:int, y:int, w:int, h:int):Region
Create a rectangular Region
Script
 Inherited
createBoxTerrainRegion(x:int, y:int, w:int, h:int):TerrainRegion
Create a rectangular TerrainRegion
Script
 Inherited
createBrightnessFilter(b:Number):ColorMatrixFilter
[static]
Script
 Inherited
createCircularRegion(x:int, y:int, r:int):Region
Create a circular Region
Script
 Inherited
Create a circular TerrainRegion
Script
 Inherited
createFadeIn(duration:uint, color:uint = 0xff000000):Transition
Create a fade in transition for use in scene switching.
Script
 Inherited
createFadeOut(duration:uint, color:uint = 0xff000000):Transition
Create a fade out transition for use in scene switching.
Script
 Inherited
createGrayscaleFilter():ColorMatrixFilter
[static]
Script
 Inherited
createHingeJoint(one:b2Body, two:b2Body = null, pt:V2 = null):b2RevoluteJoint
Script
 Inherited
createHueFilter(h:Number):ColorMatrixFilter
[static]
Script
 Inherited
createLabel(font:Font, text:String, x:int, y:int):Label
Script
 Inherited
createMultilineLabel(font:Font, text:String, x:int, y:int, w:int):Panel
Script
 Inherited
createNegativeFilter():ColorMatrixFilter
[static]
Script
 Inherited
createPanel(x:int, y:int, w:int, h:int):Panel
Script
 Inherited
createRecycledActor(type:ActorType, x:Number, y:Number, layerConst:int):Actor
Creates an actor of the given type at the given location and layer.
Script
 Inherited
createSaturationFilter(s:Number):ColorMatrixFilter
[static]
Script
 Inherited
createSepiaFilter():ColorMatrixFilter
[static]
Script
 Inherited
createSlidingJoint(one:b2Body, two:b2Body = null, dir:V2 = null):b2LineJoint
Script
 Inherited
createStickJoint(one:b2Body, two:b2Body, p1:V2 = null, p2:V2 = null):b2DistanceJoint
Script
 Inherited
createTintFilter(color:uint, amount:Number = 1):ColorMatrixFilter
[static]
Script
 Inherited
Script
 Inherited
destroyJointByID(jointID:int):void
Script
 Inherited
disableBehaviorForScene(behaviorName:String):void
Disable the given Behavior (by name) for the current scene
Script
 Inherited
Script
 Inherited
Script
 Inherited
Script
 Inherited
Disable the current Behavior.
Script
 Inherited
Call this if you need to do any drawing using draw()
Script
 Inherited
draw(g:Graphics, x:Number, y:Number):void
Script
 Inherited
enableBehaviorForScene(behaviorName:String):void
Enable the given Behavior (by name) for the current scene
Script
 Inherited
Script
 Inherited
Script
 Inherited
enableDebugDrawing(debugColor:uint = 0xff000000):void
Script
 Inherited
Script
 Inherited
Script
 Inherited
F(x:*, y:*, z:*):*
Script
 Inherited
fadeInForAllSounds(time:int):void
Script
 Inherited
fadeOutForAllSounds(time:int):void
Script
 Inherited
fadeTileLayerTo(layerID:uint, alphaPct:uint, duration:uint, easing:String = linear):void
Force the given layer to fade to the given opacity over time, applying the easing function.
Script
 Inherited
FF(a:*, b:*, c:*, d:*, x:*, s:*, ac:*):*
Script
 Inherited
format(message:String, ... args):void
Script
 Inherited
forwardMessage(msg:String):void
Internal use only.
Script
 Inherited
G(x:*, y:*, z:*):*
Script
 Inherited
getActor(actorID:Number):Actor
Script
 Inherited
getActorGroup(groupID:Number):FlxGroup
Script
 Inherited
getActorsAlongLine(x1:int, y1:int, x2:int, y2:int, callback:Function):void
Script
 Inherited
getActorsAtPoint(x:int, y:int, callback:Function):void
Script
 Inherited
getActorsInArea(x:int, y:int, w:int, h:int, callback:Function):void
Script
 Inherited
Returns an Array of Actors that intersect the Region
Script
 Inherited
Script
 Inherited
getActorsOnScreen(callback:Function):void
Script
 Inherited
getActorType(actorTypeID:uint):ActorType
Script
 Inherited
getActorTypeByName(typeName:String):ActorType
Script
 Inherited
Script
 Inherited
Get all Regions in a Scene
Script
 Inherited
Get all Regions in a Scene
Script
 Inherited
Script
 Inherited
Returns the actor that represents the camera
Script
 Inherited
Get the ID of the current scene.
Script
 Inherited
Get the name of the current scene.
Script
 Inherited
getFont(fontID:uint):Font
Script
 Inherited
getFPS():uint
Script
 Inherited
getGameAttribute(name:String):*
Script
 Inherited
Script
 Inherited
Script
 Inherited
getIDForResource(name:String):uint
Script
 Inherited
getIDForScene(sceneName:String):uint
Get the ID of a scene by name.
Script
 Inherited
Returns the 'default' image for the given actor type.
Script
 Inherited
getJoint(jointID:int):b2Joint
Script
 Inherited
Returns the last actor created in this scene.
Script
 Inherited
Script
 Inherited
Script
 Inherited
Script
 Inherited
Return the last created region
Script
 Inherited
Return the last created terrain region
Script
 Inherited
Script
 Inherited
Script
 Inherited
Script
 Inherited
Script
 Inherited
Script
 Inherited
Script
 Inherited
Script
 Inherited
getMouseX():Number
Script
 Inherited
getMouseY():Number
Script
 Inherited
getPlayerName():String
Script
 Inherited
getRegion(regionID:int):Region
Get a particular Region based on internal ID
Script
 Inherited
Script
 Inherited
Get the current scene.
Script
 Inherited
Get the height (in pixels) of the current scene.
Script
 Inherited
Get the width (in pixels) of the current scene.
Script
 Inherited
getScore(scoreName:String, callback:Function = null):void
Script
 Inherited
getScores(scoreName:String, numberToGrab:uint, callback:Function = null):void
Script
 Inherited
Script
 Inherited
Script
 Inherited
x-position of the camera
Script
 Inherited
y-position of the camera
Script
 Inherited
getSound(soundID:uint):SoundClip
Script
 Inherited
Script
 Inherited
getTerrainRegion(terrainRegionID:int):TerrainRegion
Get a particular Region based on internal ID
Script
 Inherited
getTileAt(row:int, col:int, layer:int):Tile
Returns the Tile at the specified row and column, or null if no tile is found nbsp;
Script
 Inherited
Get the height (in tiles) of the current scene.
Script
 Inherited
Get the width (in tiles) of the current scene.
Script
 Inherited
Script
 Inherited
getValueForScene(behaviorName:String, attributeName:String):Object
Script
 Inherited
GG(a:*, b:*, c:*, d:*, x:*, s:*, ac:*):*
Script
 Inherited
H(x:*, y:*, z:*):*
Script
 Inherited
Handle a collision with another Actor.
Script
 Inherited
HH(a:*, b:*, c:*, d:*, x:*, s:*, ac:*):*
Script
 Inherited
hideCursor():void
Script
 Inherited
hideFPS():void
Script
 Inherited
hideTileLayer(layerID:uint):void
Force the given layer to become invisible.
Script
 Inherited
I(x:*, y:*, z:*):*
Script
 Inherited
II(a:*, b:*, c:*, d:*, x:*, s:*, ac:*):*
Script
 Inherited
init():void
Called whenever this Actor or Scene is created.
Script
 Inherited
Script
 Inherited
isBehaviorEnabledForScene(behaviorName:String):Boolean
Check if the current scene contains the given Behavior (by name) and if said behavior is enabled.
Script
 Inherited
isCtrlDown():Boolean
Script
 Inherited
isGuest():Boolean
Script
 Inherited
isInRegion(a:Actor, r:Region):Boolean
Check whether the Actor intersects the Region
Script
 Inherited
isKeyDown(abstractKey:String):Boolean
Script
 Inherited
isKeyPressed(abstractKey:String):Boolean
Script
 Inherited
isKeyReleased(abstractKey:String):Boolean
Script
 Inherited
isMouseDown():Boolean
Script
 Inherited
isMousePressed():Boolean
Script
 Inherited
isMouseReleased():Boolean
Script
 Inherited
isShiftDown():Boolean
Script
 Inherited
isTransitioning():Boolean
Script
 Inherited
kongGetUserId():Number
Script
 Inherited
Script
 Inherited
kongIsGuest():Boolean
Script
 Inherited
kongSubmitStat(statName:String, value:Number):void
Script
 Inherited
Script
 Inherited
loadGame(fileName:String, callback:Function = null):void
Script
 Inherited
Script
 Inherited
MD5(string:String):String
Script
 Inherited
mute():void
Script
 Inherited
openURLInBrowser(URL:String):void
Script
 Inherited
pauseAll():void
Script
 Inherited
preWrap(text:String, maxWidth:int, font:Font):String
Script
 Inherited
print(message:*):void
Script
 Inherited
randomFloat():Number
Script
 Inherited
randomInt(low:int, high:int):Number
Script
 Inherited
Script
 Inherited
reloadCurrentScene(leave:Transition = null, enter:Transition = null):void
Reload the current scene, using an exit transition and then an enter transition.
Script
 Inherited
removeRegion(regionID:int):void
Remove a Region from a Scene
Script
 Inherited
removeTerrainRegion(terrainRegionID:int):void
Remove a Region from a Scene
Script
 Inherited
removeTileAt(row:int, col:int, layer:int):void
Remove a tile from a scene at runtime at the specified row and column.
Script
 Inherited
retrieveSaves(callback:Function = null):void
Script
 Inherited
RotateLeft(lValue:*, iShiftBits:*):*
MD5 (Message-Digest Algorithm) http://www.webtoolkit.info/
Script
 Inherited
runLater(delay:uint, toExecute:Function):void
Runs the given function after a delay.
Script
 Inherited
runPeriodically(interval:uint, toExecute:Function):void
Runs the given function periodically (every n seconds).
Script
 Inherited
sameAs(one:*, two:*):Boolean
[static] A generic way to compare two values or objects.
Script
 Inherited
saveGame(fileName:String, displayTitle:String, callback:Function = null):void
Script
 Inherited
sayToScene(behaviorName:String, msg:String, ... args):Object
Script
 Inherited
sceneHasBehavior(behaviorName:String):Boolean
Check if the current scene contains the given Behavior (by name)
Script
 Inherited
Script
 Inherited
Script
 Inherited
setCursor(graphic:Class = null, xOffset:int = 0, yOffset:int = 0):void
Script
 Inherited
setFPS(desiredFPS:uint):void
Script
 Inherited
setGameAttribute(name:String, value:*):void
Script
 Inherited
setGravity(x:Number, y:Number):void
Script
 Inherited
setLocationForAllSounds(location:Number):void
Script
 Inherited
setOffscreenTolerance(top:int, left:int, bottom:int, right:int):void
Script
 Inherited
setScrollSpeedForBackground(xSpeed:Number, ySpeed:Number):void
Script
 Inherited
setTileAt(row:int, col:int, layer:int, tilesetID:int, tileID:int):void
Add a tile to the scene at runtime in the specified row and column
Script
 Inherited
setTimeScale(scale:Number):void
Script
 Inherited
setValueForScene(behaviorName:String, attributeName:String, value:Object):void
Script
 Inherited
setVolumeForAllSounds(volume:Number):void
Script
 Inherited
shoutToScene(msg:String, ... args):Object
Script
 Inherited
showCursor():void
Script
 Inherited
showTileLayer(layerID:uint):void
Force the given layer to show.
Script
 Inherited
simpleTweet(message:String, gameURL:String):void
Script
 Inherited
startFadeIn(color:uint = 0xffffffff, duration:Number = 1000, forceReset:Boolean = false):void
Script
 Inherited
startFadeOut(color:uint = 0xffffffff, duration:Number = 1000, forceReset:Boolean = false):void
Script
 Inherited
startShakingScreen(intensity:Number = 0.05, duration:Number = 500):void
Script
 Inherited
Script
 Inherited
stopFadeIn():void
Script
 Inherited
Script
 Inherited
Script
 Inherited
submitScore(scoreName:String, value:Number, callback:Function = null):void
Script
 Inherited
switchScene(sceneID:uint, leave:Transition = null, enter:Transition = null):void
Switch to the given scene, using an exit transition and then an enter transition.
Script
 Inherited
toPhysicalUnits(value:Number):Number
Script
 Inherited
toPixelUnits(value:Number):Number
Script
 Inherited
tween(attribute:Object = null, params:Object = null):Boolean
[static]
Script
 Inherited
tweenNumber(attributeName:String, toValue:Number, duration:Number, easing:String):Boolean
Script
 Inherited
unmute():void
Script
 Inherited
unpauseAll():void
Script
 Inherited
update():void
Called each time the game steps forward.
Script
 Inherited
Utf8Encode(string:String):String
Script
 Inherited
visitURL(URL:String, callback:Function = null):void
Script
 Inherited
WordToHex(lValue:*):*
Script
 Inherited
wordWrap(text:String, maxWidth:int, font:Font):Array
Script
Protected Methods
 MethodDefined By
 Inherited
Call this if you want to receive collision events for the actor.
Script
Constructor Detail
SceneScript()Constructor
public function SceneScript(scene:GameState)



Parameters
scene:GameState