Class Index | File Index

Classes


Class punx.Screen


Defined in: punx.dist.js.

Class Summary
Constructor Attributes Constructor Name and Description
 
punx.Screen(args)
Represents a collection of sprites to be drawn to the canvas.
Field Summary
Field Attributes Field Name and Description
 
Stage back.
 
bgs
List of {punx.Entity} instances.
 
Stage front.
 
Camera tracking X offset.
Method Summary
Method Attributes Method Name and Description
 
draw()
Draws only if updated.
 
move(a, x, y)
 
Update all sprites and remember if updated.
Class Detail
punx.Screen(args)
Represents a collection of sprites to be drawn to the canvas. Only the active screen is drawn.
Parameters:
{object} args
Construction values for public properties.
Field Detail
back
Stage back.

{Punx.Sprites[]} bgs
List of {punx.Entity} instances. Should be pre-sorted by the draw order (z-index).
Default Value:
[]

front
Stage front.

track
Camera tracking X offset.
Method Detail
draw()
Draws only if updated. Draws all entities in order.

move(a, x, y)
Parameters:
a
x
y

update()
Update all sprites and remember if updated. Called by the {Punx} update loop.

Documentation generated by JsDoc Toolkit 2.4.0 on Sun Oct 13 2013 01:37:55 GMT-0700 (PDT)