2013-10-02 00:16:40 +00:00
<!DOCTYPE html>
< html lang = "en" >
< head >
< meta charset = "utf-8" >
< title > Phaser Class: Group< / title >
<!-- [if lt IE 9]>
< script src = "//html5shiv.googlecode.com/svn/trunk/html5.js" > < / script >
<![endif]-->
< link type = "text/css" rel = "stylesheet" href = "styles/sunlight.default.css" >
< link type = "text/css" rel = "stylesheet" href = "styles/site.cerulean.css" >
< / head >
< body >
< div class = "container-fluid" >
< div class = "navbar navbar-fixed-top navbar-inverse" >
< div class = "navbar-inner" >
< a class = "brand" href = "index.html" > Phaser< / a >
< ul class = "nav" >
< li class = "dropdown" >
2013-10-03 01:38:35 +00:00
< a href = "namespaces.list.html" class = "dropdown-toggle" data-toggle = "dropdown" > Namespaces< b
2013-10-02 00:16:40 +00:00
class="caret">< / b > < / a >
< ul class = "dropdown-menu " >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-0" >
2013-10-03 01:38:35 +00:00
< a href = "Phaser.html" > Phaser< / a >
2013-10-02 00:16:40 +00:00
< / li >
< / ul >
< / li >
< li class = "dropdown" >
< a href = "classes.list.html" class = "dropdown-toggle" data-toggle = "dropdown" > Classes< b
class="caret">< / b > < / a >
< ul class = "dropdown-menu " >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-02 00:16:40 +00:00
< a href = "Phaser.Animation.html" > Animation< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-03 01:38:35 +00:00
< a href = "Phaser.AnimationManager.html" > AnimationManager< / a >
2013-10-02 00:16:40 +00:00
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-03 01:38:35 +00:00
< a href = "Phaser.AnimationParser.html" > AnimationParser< / a >
2013-10-02 00:16:40 +00:00
< / li >
2014-04-29 14:39:02 +00:00
< li class = "class-depth-1" >
< a href = "Phaser.ArrayList.html" > ArrayList< / a >
< / li >
2014-10-09 15:12:53 +00:00
< li class = "class-depth-1" >
< a href = "Phaser.AudioSprite.html" > AudioSprite< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-11-28 15:57:09 +00:00
< a href = "Phaser.BitmapData.html" > BitmapData< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-25 15:54:40 +00:00
< a href = "Phaser.BitmapText.html" > BitmapText< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-25 15:54:40 +00:00
< a href = "Phaser.Button.html" > Button< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-03 01:38:35 +00:00
< a href = "Phaser.Cache.html" > Cache< / a >
2013-10-02 00:16:40 +00:00
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-03 01:38:35 +00:00
< a href = "Phaser.Camera.html" > Camera< / a >
2013-10-02 00:16:40 +00:00
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-03 01:38:35 +00:00
< a href = "Phaser.Canvas.html" > Canvas< / a >
2013-10-02 14:05:55 +00:00
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-03 01:38:35 +00:00
< a href = "Phaser.Circle.html" > Circle< / a >
2013-10-02 00:16:40 +00:00
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-03 01:38:35 +00:00
< a href = "Phaser.Color.html" > Color< / a >
2013-10-03 00:21:08 +00:00
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-03 01:38:35 +00:00
< a href = "Phaser.Device.html" > Device< / a >
2013-10-02 11:11:22 +00:00
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-03 01:38:35 +00:00
< a href = "Phaser.Easing.html" > Easing< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-2" >
2013-10-03 01:38:35 +00:00
< a href = "Phaser.Easing.Back.html" > Back< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-2" >
2013-10-03 01:38:35 +00:00
< a href = "Phaser.Easing.Bounce.html" > Bounce< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-2" >
2013-10-03 01:38:35 +00:00
< a href = "Phaser.Easing.Circular.html" > Circular< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-2" >
2013-10-03 01:38:35 +00:00
< a href = "Phaser.Easing.Cubic.html" > Cubic< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-2" >
2013-10-03 01:38:35 +00:00
< a href = "Phaser.Easing.Elastic.html" > Elastic< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-2" >
2013-10-03 01:38:35 +00:00
< a href = "Phaser.Easing.Exponential.html" > Exponential< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-2" >
2013-10-03 01:38:35 +00:00
< a href = "Phaser.Easing.Linear.html" > Linear< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-2" >
2013-10-03 01:38:35 +00:00
< a href = "Phaser.Easing.Quadratic.html" > Quadratic< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-2" >
2013-10-03 01:38:35 +00:00
< a href = "Phaser.Easing.Quartic.html" > Quartic< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-2" >
2013-10-03 01:38:35 +00:00
< a href = "Phaser.Easing.Quintic.html" > Quintic< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-2" >
2013-10-03 01:38:35 +00:00
< a href = "Phaser.Easing.Sinusoidal.html" > Sinusoidal< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2014-02-18 03:01:51 +00:00
< a href = "Phaser.Ellipse.html" > Ellipse< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-25 15:54:40 +00:00
< a href = "Phaser.Events.html" > Events< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-11-28 15:57:09 +00:00
< a href = "Phaser.Filter.html" > Filter< / a >
< / li >
2014-09-09 14:36:56 +00:00
< li class = "class-depth-1" >
< a href = "Phaser.FlexGrid.html" > FlexGrid< / a >
< / li >
< li class = "class-depth-1" >
< a href = "Phaser.FlexLayer.html" > FlexLayer< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-03 01:38:35 +00:00
< a href = "Phaser.Frame.html" > Frame< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-03 01:38:35 +00:00
< a href = "Phaser.FrameData.html" > FrameData< / a >
2013-10-03 00:21:08 +00:00
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-02 00:16:40 +00:00
< a href = "Phaser.Game.html" > Game< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2014-02-21 15:37:26 +00:00
< a href = "Phaser.GameObjectCreator.html" > GameObjectCreator< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-25 15:54:40 +00:00
< a href = "Phaser.GameObjectFactory.html" > GameObjectFactory< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2014-02-05 06:29:17 +00:00
< a href = "Phaser.Gamepad.html" > Gamepad< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2014-02-05 06:29:17 +00:00
< a href = "Phaser.GamepadButton.html" > GamepadButton< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-25 15:54:40 +00:00
< a href = "Phaser.Graphics.html" > Graphics< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-02 00:16:40 +00:00
< a href = "Phaser.Group.html" > Group< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2014-02-08 07:24:22 +00:00
< a href = "Phaser.Image.html" > Image< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-02 12:18:58 +00:00
< a href = "Phaser.Input.html" > Input< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-02 14:05:55 +00:00
< a href = "Phaser.InputHandler.html" > InputHandler< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-02 14:05:55 +00:00
< a href = "Phaser.Key.html" > Key< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-02 14:05:55 +00:00
< a href = "Phaser.Keyboard.html" > Keyboard< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2014-02-05 06:29:17 +00:00
< a href = "Phaser.Line.html" > Line< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-02 11:11:22 +00:00
< a href = "Phaser.LinkedList.html" > LinkedList< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-02 14:05:55 +00:00
< a href = "Phaser.Loader.html" > Loader< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-03 01:38:35 +00:00
< a href = "Phaser.LoaderParser.html" > LoaderParser< / a >
2013-10-02 14:05:55 +00:00
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-02 14:05:55 +00:00
< a href = "Phaser.Math.html" > Math< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-02 14:05:55 +00:00
< a href = "Phaser.Mouse.html" > Mouse< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-02 14:05:55 +00:00
< a href = "Phaser.MSPointer.html" > MSPointer< / a >
2013-10-02 11:11:22 +00:00
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-02 19:18:24 +00:00
< a href = "Phaser.Net.html" > Net< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
< a href = "Phaser.Particle.html" > Particle< / a >
< / li >
< li class = "class-depth-1" >
2013-10-02 19:18:24 +00:00
< a href = "Phaser.Particles.html" > Particles< / a >
< / li >
2014-10-09 15:12:53 +00:00
< li class = "class-depth-2" >
< a href = "Phaser.Particles.Arcade.html" > Arcade< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-3" >
2013-10-02 19:18:24 +00:00
< a href = "Phaser.Particles.Arcade.Emitter.html" > Emitter< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-25 15:54:40 +00:00
< a href = "Phaser.Physics.html" > Physics< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-2" >
2013-10-25 15:54:40 +00:00
< a href = "Phaser.Physics.Arcade.html" > Arcade< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-3" >
2014-03-14 06:36:05 +00:00
< a href = "Phaser.Physics.Arcade.Body.html" > Body< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-2" >
2014-03-14 06:36:05 +00:00
< a href = "Phaser.Physics.Ninja.html" > Ninja< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-3" >
2014-03-14 06:36:05 +00:00
< a href = "Phaser.Physics.Ninja.AABB.html" > AABB< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-3" >
2014-03-14 06:36:05 +00:00
< a href = "Phaser.Physics.Ninja.Body.html" > Body< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-3" >
2014-03-14 06:36:05 +00:00
< a href = "Phaser.Physics.Ninja.Circle.html" > Circle< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-3" >
2014-03-14 06:36:05 +00:00
< a href = "Phaser.Physics.Ninja.Tile.html" > Tile< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-2" >
2014-03-14 06:36:05 +00:00
< a href = "Phaser.Physics.P2.html" > P2< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-3" >
2014-03-14 06:36:05 +00:00
< a href = "Phaser.Physics.P2.Body.html" > Body< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-3" >
2014-03-14 06:36:05 +00:00
< a href = "Phaser.Physics.P2.BodyDebug.html" > BodyDebug< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-3" >
2014-03-14 06:36:05 +00:00
< a href = "Phaser.Physics.P2.CollisionGroup.html" > CollisionGroup< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-3" >
2014-03-14 06:36:05 +00:00
< a href = "Phaser.Physics.P2.ContactMaterial.html" > ContactMaterial< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-3" >
2014-03-14 06:36:05 +00:00
< a href = "Phaser.Physics.P2.DistanceConstraint.html" > DistanceConstraint< / a >
2014-02-21 15:37:26 +00:00
< / li >
2014-04-11 12:09:28 +00:00
< li class = "class-depth-3" >
< a href = "Phaser.Physics.P2.FixtureList.html" > FixtureList< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-3" >
2014-03-14 06:36:05 +00:00
< a href = "Phaser.Physics.P2.GearConstraint.html" > GearConstraint< / a >
2014-02-21 15:37:26 +00:00
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-3" >
2014-03-14 06:36:05 +00:00
< a href = "Phaser.Physics.P2.InversePointProxy.html" > InversePointProxy< / a >
2014-02-21 15:37:26 +00:00
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-3" >
2014-03-14 06:36:05 +00:00
< a href = "Phaser.Physics.P2.LockConstraint.html" > LockConstraint< / a >
2014-02-21 15:37:26 +00:00
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-3" >
2014-03-14 06:36:05 +00:00
< a href = "Phaser.Physics.P2.Material.html" > Material< / a >
2014-02-21 15:37:26 +00:00
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-3" >
2014-03-14 06:36:05 +00:00
< a href = "Phaser.Physics.P2.PointProxy.html" > PointProxy< / a >
2014-02-21 15:37:26 +00:00
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-3" >
2014-03-14 06:36:05 +00:00
< a href = "Phaser.Physics.P2.PrismaticConstraint.html" > PrismaticConstraint< / a >
2014-02-21 15:37:26 +00:00
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-3" >
2014-03-14 06:36:05 +00:00
< a href = "Phaser.Physics.P2.RevoluteConstraint.html" > RevoluteConstraint< / a >
< / li >
2014-09-09 14:36:56 +00:00
< li class = "class-depth-3" >
< a href = "Phaser.Physics.P2.RotationalSpring.html" > RotationalSpring< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-3" >
2014-03-14 06:36:05 +00:00
< a href = "Phaser.Physics.P2.Spring.html" > Spring< / a >
2014-02-21 15:37:26 +00:00
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-02 11:11:22 +00:00
< a href = "Phaser.Plugin.html" > Plugin< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-02 14:05:55 +00:00
< a href = "Phaser.PluginManager.html" > PluginManager< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-02 11:11:22 +00:00
< a href = "Phaser.Point.html" > Point< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-02 14:05:55 +00:00
< a href = "Phaser.Pointer.html" > Pointer< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-11-07 06:10:15 +00:00
< a href = "Phaser.Polygon.html" > Polygon< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2014-03-14 06:36:05 +00:00
< a href = "Phaser.QuadTree.html" > QuadTree< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-02 14:05:55 +00:00
< a href = "Phaser.RandomDataGenerator.html" > RandomDataGenerator< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-02 11:11:22 +00:00
< a href = "Phaser.Rectangle.html" > Rectangle< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-25 15:54:40 +00:00
< a href = "Phaser.RenderTexture.html" > RenderTexture< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-03 00:21:08 +00:00
< a href = "Phaser.RequestAnimationFrame.html" > RequestAnimationFrame< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2014-03-14 06:36:05 +00:00
< a href = "Phaser.RetroFont.html" > RetroFont< / a >
< / li >
2014-09-09 14:36:56 +00:00
< li class = "class-depth-1" >
< a href = "Phaser.Rope.html" > Rope< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2014-03-14 06:36:05 +00:00
< a href = "Phaser.ScaleManager.html" > ScaleManager< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-02 11:11:22 +00:00
< a href = "Phaser.Signal.html" > Signal< / a >
< / li >
2014-04-11 12:09:28 +00:00
< li class = "class-depth-1" >
< a href = "Phaser.SignalBinding.html" > SignalBinding< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2014-02-05 06:29:17 +00:00
< a href = "Phaser.SinglePad.html" > SinglePad< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-03 00:21:08 +00:00
< a href = "Phaser.Sound.html" > Sound< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-03 00:21:08 +00:00
< a href = "Phaser.SoundManager.html" > SoundManager< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-25 15:54:40 +00:00
< a href = "Phaser.Sprite.html" > Sprite< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2014-02-18 03:01:51 +00:00
< a href = "Phaser.SpriteBatch.html" > SpriteBatch< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-02 11:11:22 +00:00
< a href = "Phaser.Stage.html" > Stage< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-02 11:11:22 +00:00
< a href = "Phaser.State.html" > State< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-02 11:11:22 +00:00
< a href = "Phaser.StateManager.html" > StateManager< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-25 15:54:40 +00:00
< a href = "Phaser.Text.html" > Text< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-11-28 15:57:09 +00:00
< a href = "Phaser.Tile.html" > Tile< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-11-28 15:57:09 +00:00
< a href = "Phaser.Tilemap.html" > Tilemap< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-11-28 15:57:09 +00:00
< a href = "Phaser.TilemapLayer.html" > TilemapLayer< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-11-28 15:57:09 +00:00
< a href = "Phaser.TilemapParser.html" > TilemapParser< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-11-28 15:57:09 +00:00
< a href = "Phaser.Tileset.html" > Tileset< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-25 15:54:40 +00:00
< a href = "Phaser.TileSprite.html" > TileSprite< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-03 01:38:35 +00:00
< a href = "Phaser.Time.html" > Time< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-11-28 15:57:09 +00:00
< a href = "Phaser.Timer.html" > Timer< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2014-02-05 06:29:17 +00:00
< a href = "Phaser.TimerEvent.html" > TimerEvent< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-02 14:05:55 +00:00
< a href = "Phaser.Touch.html" > Touch< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-03 01:38:35 +00:00
< a href = "Phaser.Tween.html" > Tween< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-03 01:38:35 +00:00
< a href = "Phaser.TweenManager.html" > TweenManager< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-03 01:38:35 +00:00
< a href = "Phaser.Utils.html" > Utils< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-2" >
2013-10-03 01:38:35 +00:00
< a href = "Phaser.Utils.Debug.html" > Debug< / a >
< / li >
2014-04-10 22:13:43 +00:00
< li class = "class-depth-1" >
2013-10-02 11:11:22 +00:00
< a href = "Phaser.World.html" > World< / a >
< / li >
2013-10-02 00:16:40 +00:00
< / ul >
< / li >
2014-09-09 14:36:56 +00:00
2013-10-02 00:16:40 +00:00
< / ul >
< / div >
< / div >
< div class = "row-fluid" >
< div class = "span8" >
< div id = "main" >
< h1 class = "page-title" > Class: Group< / h1 >
< section >
< header >
< h2 >
2013-10-03 01:38:35 +00:00
< span class = "ancestors" > < a href = "Phaser.html" > Phaser< / a > .< / span >
2013-10-02 00:16:40 +00:00
Group
< / h2 >
2014-10-09 15:12:53 +00:00
< div class = "class-description" > < p > Phaser.Group< / p > < / div >
2013-10-02 00:16:40 +00:00
< / header >
< article >
< div class = "container-overview" >
< dt >
2014-03-14 06:36:05 +00:00
< h4 class = "name" id = "Group" > < span class = "type-signature" > < / span > new Group< span class = "signature" > (game, parent, < span class = "optional" > name< / span > , < span class = "optional" > addToStage< / span > , < span class = "optional" > enableBody< / span > , < span class = "optional" > physicsBodyType< / span > )< / span > < span class = "type-signature" > < / span > < / h4 >
2013-10-02 00:16:40 +00:00
< / dt >
< dd >
< div class = "description" >
2014-10-09 15:12:53 +00:00
< p > A Group is a container for display objects that allows for fast pooling and object recycling.
Groups can be nested within other Groups and have their own local transforms.< / p >
2013-10-02 00:16:40 +00:00
< / div >
< h5 > Parameters:< / h5 >
< table class = "params table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
2013-10-02 10:22:20 +00:00
< th > Argument< / th >
2013-10-02 00:16:40 +00:00
2013-10-02 10:22:20 +00:00
< th > Default< / th >
2013-10-02 00:16:40 +00:00
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
< td class = "name" > < code > game< / code > < / td >
< td class = "type" >
< span class = "param-type" > < a href = "Phaser.Game.html" > Phaser.Game< / a > < / span >
< / td >
2013-10-02 10:22:20 +00:00
< td class = "attributes" >
2013-10-02 00:16:40 +00:00
2013-10-02 10:22:20 +00:00
< / td >
< td class = "default" >
< / td >
2013-10-02 00:16:40 +00:00
< td class = "description last" > < p > A reference to the currently running game.< / p > < / td >
< / tr >
< tr >
< td class = "name" > < code > parent< / code > < / td >
< td class = "type" >
2014-02-18 03:01:51 +00:00
< span class = "param-type" > < a href = "Phaser.Group.html" > Phaser.Group< / a > < / span >
|
< span class = "param-type" > < a href = "Phaser.Sprite.html" > Phaser.Sprite< / a > < / span >
2014-02-21 15:37:26 +00:00
|
< span class = "param-type" > null< / span >
2013-10-02 00:16:40 +00:00
< / td >
2013-10-02 10:22:20 +00:00
< td class = "attributes" >
2013-10-02 00:16:40 +00:00
2013-10-02 10:22:20 +00:00
< / td >
2013-10-02 00:16:40 +00:00
2013-10-02 10:22:20 +00:00
< td class = "default" >
< / td >
2014-07-18 11:45:51 +00:00
< td class = "description last" > < p > The parent Group, DisplayObject or DisplayObjectContainer that this Group will be added to. If < code > undefined< / code > it will use game.world. If null it won't be added to anything.< / p > < / td >
2013-10-02 00:16:40 +00:00
< / tr >
< tr >
< td class = "name" > < code > name< / code > < / td >
< td class = "type" >
< span class = "param-type" > string< / span >
< / td >
2013-10-02 10:22:20 +00:00
< td class = "attributes" >
< optional>< br >
< / td >
2013-10-02 00:16:40 +00:00
2013-10-02 10:22:20 +00:00
< td class = "default" >
group
< / td >
2013-10-02 00:16:40 +00:00
2013-10-02 10:22:20 +00:00
< td class = "description last" > < p > A name for this Group. Not used internally but useful for debugging.< / p > < / td >
2013-10-02 00:16:40 +00:00
< / tr >
< tr >
2014-02-18 03:01:51 +00:00
< td class = "name" > < code > addToStage< / code > < / td >
2013-10-02 00:16:40 +00:00
< td class = "type" >
< span class = "param-type" > boolean< / span >
< / td >
2013-10-02 10:22:20 +00:00
< td class = "attributes" >
< optional>< br >
2013-10-02 00:16:40 +00:00
2013-10-02 10:22:20 +00:00
< / td >
2013-10-02 00:16:40 +00:00
2013-10-02 10:22:20 +00:00
< td class = "default" >
false
< / td >
2014-02-18 03:01:51 +00:00
< td class = "description last" > < p > If set to true this Group will be added directly to the Game.Stage instead of Game.World.< / p > < / td >
2013-10-02 00:16:40 +00:00
< / tr >
2014-03-14 06:36:05 +00:00
< tr >
< td class = "name" > < code > enableBody< / code > < / td >
< td class = "type" >
< span class = "param-type" > boolean< / span >
< / td >
< td class = "attributes" >
< optional>< br >
< / td >
< td class = "default" >
false
< / td >
< td class = "description last" > < p > If true all Sprites created with < code > Group.create< / code > or < code > Group.createMulitple< / code > will have a physics body created on them. Change the body type with physicsBodyType.< / p > < / td >
< / tr >
< tr >
< td class = "name" > < code > physicsBodyType< / code > < / td >
< td class = "type" >
< span class = "param-type" > number< / span >
< / td >
< td class = "attributes" >
< optional>< br >
< / td >
< td class = "default" >
0
< / td >
< td class = "description last" > < p > If enableBody is true this is the type of physics body that is created on new Sprites. Phaser.Physics.ARCADE, Phaser.Physics.P2, Phaser.Physics.NINJA, etc.< / p > < / td >
< / tr >
2013-10-02 00:16:40 +00:00
< / tbody >
< / table >
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-21" > line 21< / a >
2013-10-02 00:16:40 +00:00
< / li > < / ul > < / dd >
< / dl >
< / dd >
< / div >
2014-10-22 20:49:44 +00:00
< h3 class = "subsection-title" > Extends< / h3 >
< ul >
< li > PIXI.DisplayObjectContainer< / li >
< / ul >
2013-10-02 00:16:40 +00:00
< h3 class = "subsection-title" > Members< / h3 >
< dl >
2013-10-23 13:00:28 +00:00
< dt >
2013-11-07 06:10:15 +00:00
< h4 class = "name" id = "RETURN_CHILD" > < span class = "type-signature" > < static, constant> < / span > RETURN_CHILD< span class = "type-signature" > :number< / span > < / h4 >
2013-10-23 13:00:28 +00:00
< / dt >
< dd >
2013-11-07 06:10:15 +00:00
< h5 > Type:< / h5 >
< ul >
< li >
< span class = "param-type" > number< / span >
< / li >
< / ul >
2013-10-23 13:00:28 +00:00
< dl class = "details" >
2013-11-07 06:10:15 +00:00
2013-10-23 13:00:28 +00:00
2013-11-07 06:10:15 +00:00
2013-10-23 13:00:28 +00:00
2013-11-07 06:10:15 +00:00
2013-10-23 13:00:28 +00:00
2013-11-07 06:10:15 +00:00
2013-10-23 13:00:28 +00:00
2013-11-07 06:10:15 +00:00
2013-10-23 13:00:28 +00:00
2013-11-07 06:10:15 +00:00
2013-10-23 13:00:28 +00:00
2013-11-07 06:10:15 +00:00
2013-10-23 13:00:28 +00:00
2013-11-07 06:10:15 +00:00
2013-10-23 13:00:28 +00:00
2013-11-07 06:10:15 +00:00
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-183" > line 183< / a >
2013-11-07 06:10:15 +00:00
< / li > < / ul > < / dd >
2013-10-23 13:00:28 +00:00
2013-11-07 06:10:15 +00:00
2013-10-23 13:00:28 +00:00
2013-11-07 06:10:15 +00:00
2013-10-23 13:00:28 +00:00
2013-11-07 06:10:15 +00:00
< / dl >
2013-10-23 13:00:28 +00:00
2013-11-07 06:10:15 +00:00
< / dd >
2013-10-23 13:00:28 +00:00
2013-11-07 06:10:15 +00:00
2013-10-23 13:00:28 +00:00
2013-11-07 06:10:15 +00:00
< dt >
< h4 class = "name" id = "RETURN_NONE" > < span class = "type-signature" > < static, constant> < / span > RETURN_NONE< span class = "type-signature" > :number< / span > < / h4 >
< / dt >
< dd >
< h5 > Type:< / h5 >
< ul >
< li >
< span class = "param-type" > number< / span >
2013-10-23 13:00:28 +00:00
2013-11-07 06:10:15 +00:00
< / li >
< / ul >
2013-10-23 13:00:28 +00:00
2013-11-07 06:10:15 +00:00
< dl class = "details" >
2013-10-23 13:00:28 +00:00
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-171" > line 171< / a >
2013-10-23 13:00:28 +00:00
< / li > < / ul > < / dd >
< / dl >
< / dd >
2013-10-02 00:16:40 +00:00
< dt >
2013-11-07 06:10:15 +00:00
< h4 class = "name" id = "RETURN_TOTAL" > < span class = "type-signature" > < static, constant> < / span > RETURN_TOTAL< span class = "type-signature" > :number< / span > < / h4 >
2013-10-02 00:16:40 +00:00
< / dt >
< dd >
2013-11-07 06:10:15 +00:00
< h5 > Type:< / h5 >
< ul >
< li >
< span class = "param-type" > number< / span >
< / li >
< / ul >
2013-10-02 00:16:40 +00:00
< dl class = "details" >
2013-11-07 06:10:15 +00:00
2013-10-02 00:16:40 +00:00
2013-11-07 06:10:15 +00:00
2013-10-02 00:16:40 +00:00
2013-11-07 06:10:15 +00:00
2013-10-02 00:16:40 +00:00
2013-11-07 06:10:15 +00:00
2013-10-02 00:16:40 +00:00
2013-11-07 06:10:15 +00:00
2013-10-02 00:16:40 +00:00
2013-11-07 06:10:15 +00:00
2013-10-02 00:16:40 +00:00
2013-11-07 06:10:15 +00:00
2013-10-02 00:16:40 +00:00
2013-11-07 06:10:15 +00:00
2013-10-02 00:16:40 +00:00
2013-11-07 06:10:15 +00:00
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-177" > line 177< / a >
2013-11-07 06:10:15 +00:00
< / li > < / ul > < / dd >
2013-10-02 00:16:40 +00:00
2013-11-07 06:10:15 +00:00
< / dl >
< / dd >
2013-10-02 00:16:40 +00:00
2013-11-07 06:10:15 +00:00
< dt >
< h4 class = "name" id = "SORT_ASCENDING" > < span class = "type-signature" > < static, constant> < / span > SORT_ASCENDING< span class = "type-signature" > :number< / span > < / h4 >
< / dt >
< dd >
< h5 > Type:< / h5 >
< ul >
< li >
2013-10-02 00:16:40 +00:00
< span class = "param-type" > number< / span >
2013-11-07 06:10:15 +00:00
< / li >
< / ul >
2013-10-02 00:16:40 +00:00
2013-11-07 06:10:15 +00:00
< dl class = "details" >
2013-10-02 00:16:40 +00:00
2013-11-07 06:10:15 +00:00
2013-10-02 00:16:40 +00:00
2013-11-07 06:10:15 +00:00
2013-10-02 00:16:40 +00:00
2013-11-07 06:10:15 +00:00
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-189" > line 189< / a >
2013-11-07 06:10:15 +00:00
< / li > < / ul > < / dd >
2013-10-02 00:16:40 +00:00
< / dl >
2013-11-07 06:10:15 +00:00
< / dd >
< dt >
< h4 class = "name" id = "SORT_DESCENDING" > < span class = "type-signature" > < static, constant> < / span > SORT_DESCENDING< span class = "type-signature" > :number< / span > < / h4 >
< / dt >
< dd >
< h5 > Type:< / h5 >
< ul >
< li >
< span class = "param-type" > number< / span >
< / li >
< / ul >
< dl class = "details" >
2013-10-02 00:16:40 +00:00
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-195" > line 195< / a >
2013-11-01 18:16:52 +00:00
< / li > < / ul > < / dd >
< / dl >
< / dd >
< dt >
2014-02-05 06:29:17 +00:00
< h4 class = "name" id = "alive" > < span class = "type-signature" > < / span > alive< span class = "type-signature" > < / span > < / h4 >
2013-11-01 18:16:52 +00:00
< / dt >
< dd >
< dl class = "details" >
< h5 class = "subsection-title" > Properties:< / h5 >
< dl >
< table class = "props table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
2014-02-05 06:29:17 +00:00
< td class = "name" > < code > alive< / code > < / td >
2013-11-01 18:16:52 +00:00
< td class = "type" >
2014-02-05 06:29:17 +00:00
< span class = "param-type" > boolean< / span >
2013-11-01 18:16:52 +00:00
< / td >
2014-02-05 06:29:17 +00:00
< td class = "description last" > < p > The alive property is useful for Groups that are children of other Groups and need to be included/excluded in checks like forEachAlive.< / p > < / td >
2013-11-01 18:16:52 +00:00
< / tr >
< / tbody >
< / table >
< / dl >
2014-02-05 06:29:17 +00:00
< dt class = "tag-default" > Default Value:< / dt >
< dd class = "tag-default" > < ul class = "dummy" > < li > true< / li > < / ul > < / dd >
2013-11-01 18:16:52 +00:00
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-71" > line 71< / a >
2013-10-02 00:16:40 +00:00
< / li > < / ul > < / dd >
< / dl >
< / dd >
< dt >
2014-02-05 06:29:17 +00:00
< h4 class = "name" id = "alpha" > < span class = "type-signature" > < / span > alpha< span class = "type-signature" > < / span > < / h4 >
2013-10-02 00:16:40 +00:00
< / dt >
< dd >
< dl class = "details" >
< h5 class = "subsection-title" > Properties:< / h5 >
< dl >
< table class = "props table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
2014-02-05 06:29:17 +00:00
< td class = "name" > < code > alpha< / code > < / td >
2013-10-02 00:16:40 +00:00
< td class = "type" >
2013-11-07 06:10:15 +00:00
< span class = "param-type" > number< / span >
2013-10-02 00:16:40 +00:00
< / td >
2014-02-05 06:29:17 +00:00
< td class = "description last" > < p > The alpha value of the Group container.< / p > < / td >
2013-10-02 00:16:40 +00:00
< / tr >
< / tbody >
< / table >
< / dl >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-1867" > line 1867< / a >
2013-10-02 00:16:40 +00:00
< / li > < / ul > < / dd >
< / dl >
< / dd >
< dt >
2014-02-05 06:29:17 +00:00
< h4 class = "name" id = "angle" > < span class = "type-signature" > < / span > angle< span class = "type-signature" > < / span > < / h4 >
2013-10-02 00:16:40 +00:00
< / dt >
< dd >
2013-11-07 06:10:15 +00:00
< div class = "description" >
2014-02-05 06:29:17 +00:00
< p > The angle of rotation of the Group container. This will adjust the Group container itself by modifying its rotation.
This will have no impact on the rotation value of its children, but it will update their worldTransform and on-screen position.< / p >
2013-11-07 06:10:15 +00:00
< / div >
2013-10-02 00:16:40 +00:00
< dl class = "details" >
< h5 class = "subsection-title" > Properties:< / h5 >
< dl >
< table class = "props table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
2014-02-05 06:29:17 +00:00
< td class = "name" > < code > angle< / code > < / td >
2013-10-02 00:16:40 +00:00
< td class = "type" >
2014-02-05 06:29:17 +00:00
< span class = "param-type" > number< / span >
2013-10-02 00:16:40 +00:00
< / td >
2014-02-05 06:29:17 +00:00
< td class = "description last" > < p > The angle of rotation given in degrees, where 0 degrees = to the right.< / p > < / td >
2013-10-02 00:16:40 +00:00
< / tr >
< / tbody >
< / table >
< / dl >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-1808" > line 1808< / a >
2014-02-18 03:01:51 +00:00
< / li > < / ul > < / dd >
< / dl >
< / dd >
< dt >
< h4 class = "name" id = "cameraOffset" > < span class = "type-signature" > < / span > cameraOffset< span class = "type-signature" > < / span > < / h4 >
< / dt >
< dd >
< dl class = "details" >
< h5 class = "subsection-title" > Properties:< / h5 >
< dl >
< table class = "props table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
< td class = "name" > < code > cameraOffset< / code > < / td >
< td class = "type" >
< span class = "param-type" > < a href = "Phaser.Point.html" > Phaser.Point< / a > < / span >
< / td >
< td class = "description last" > < p > If this object is fixedToCamera then this stores the x/y offset that its drawn at, from the top-left of the camera view.< / p > < / td >
< / tr >
< / tbody >
< / table >
< / dl >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-116" > line 116< / a >
2014-04-29 14:39:02 +00:00
< / li > < / ul > < / dd >
< / dl >
< / dd >
< dt >
< h4 class = "name" id = "classType" > < span class = "type-signature" > < / span > classType< span class = "type-signature" > < / span > < / h4 >
< / dt >
< dd >
< div class = "description" >
< p > The type of objects that will be created when you use Group.create or Group.createMultiple. Defaults to Phaser.Sprite.
When a new object is created it is passed the following parameters to its constructor: game, x, y, key, frame.< / p >
< / div >
< dl class = "details" >
< h5 class = "subsection-title" > Properties:< / h5 >
< dl >
< table class = "props table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
< td class = "name" > < code > classType< / code > < / td >
< td class = "type" >
< span class = "param-type" > object< / span >
< / td >
< td class = "description last" > < / td >
< / tr >
< / tbody >
< / table >
< / dl >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-91" > line 91< / a >
2013-10-02 00:16:40 +00:00
< / li > < / ul > < / dd >
< / dl >
< / dd >
< dt >
2014-02-05 06:29:17 +00:00
< h4 class = "name" id = "cursor" > < span class = "type-signature" > < / span > cursor< span class = "type-signature" > < / span > < / h4 >
2013-11-07 06:10:15 +00:00
< / dt >
< dd >
2014-02-05 06:29:17 +00:00
< div class = "description" >
< p > The cursor is a simple way to iterate through the objects in a Group using the Group.next and Group.previous functions.
The cursor is set to the first child added to the Group and doesn't change unless you call next, previous or set it directly with Group.cursor.< / p >
< / div >
2013-11-07 06:10:15 +00:00
< dl class = "details" >
< h5 class = "subsection-title" > Properties:< / h5 >
< dl >
< table class = "props table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
2014-02-05 06:29:17 +00:00
< td class = "name" > < code > cursor< / code > < / td >
2013-11-07 06:10:15 +00:00
< td class = "type" >
2014-02-05 06:29:17 +00:00
< span class = "param-type" > any< / span >
2013-11-07 06:10:15 +00:00
< / td >
2014-02-05 06:29:17 +00:00
< td class = "description last" > < p > The current display object that the Group cursor is pointing to.< / p > < / td >
2013-11-07 06:10:15 +00:00
< / tr >
< / tbody >
< / table >
< / dl >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-111" > line 111< / a >
2013-11-07 06:10:15 +00:00
< / li > < / ul > < / dd >
< / dl >
< / dd >
< dt >
2014-03-14 06:36:05 +00:00
< h4 class = "name" id = "enableBody" > < span class = "type-signature" > < / span > enableBody< span class = "type-signature" > < / span > < / h4 >
2013-11-07 06:10:15 +00:00
< / dt >
< dd >
< dl class = "details" >
< h5 class = "subsection-title" > Properties:< / h5 >
< dl >
< table class = "props table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
2014-03-14 06:36:05 +00:00
< td class = "name" > < code > enableBody< / code > < / td >
2013-11-07 06:10:15 +00:00
< td class = "type" >
2014-02-05 06:29:17 +00:00
< span class = "param-type" > boolean< / span >
2013-11-07 06:10:15 +00:00
< / td >
2014-03-14 06:36:05 +00:00
< td class = "description last" > < p > If true all Sprites created by, or added to this Group, will have a physics body enabled on them. Change the body type with < code > Group.physicsBodyType< / code > .< / p > < / td >
2013-11-07 06:10:15 +00:00
< / tr >
< / tbody >
< / table >
< / dl >
2014-04-11 12:09:28 +00:00
< dt class = "tag-default" > Default Value:< / dt >
< dd class = "tag-default" > < ul class = "dummy" > < li > enableBody< / li > < / ul > < / dd >
2013-11-07 06:10:15 +00:00
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-122" > line 122< / a >
2013-11-07 06:10:15 +00:00
< / li > < / ul > < / dd >
2014-02-18 03:01:51 +00:00
< / dl >
< / dd >
< dt >
2014-03-14 06:36:05 +00:00
< h4 class = "name" id = "enableBodyDebug" > < span class = "type-signature" > < / span > enableBodyDebug< span class = "type-signature" > < / span > < / h4 >
2014-02-18 03:01:51 +00:00
< / dt >
< dd >
< dl class = "details" >
< h5 class = "subsection-title" > Properties:< / h5 >
< dl >
< table class = "props table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
2014-03-14 06:36:05 +00:00
< td class = "name" > < code > enableBodyDebug< / code > < / td >
2014-02-18 03:01:51 +00:00
< td class = "type" >
< span class = "param-type" > boolean< / span >
< / td >
2014-03-14 06:36:05 +00:00
< td class = "description last" > < p > If true when a physics body is created (via Group.enableBody) it will create a physics debug object as well. Only works for P2 bodies.< / p > < / td >
2014-02-18 03:01:51 +00:00
< / tr >
< / tbody >
< / table >
< / dl >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-127" > line 127< / a >
2014-02-18 03:01:51 +00:00
< / li > < / ul > < / dd >
2013-11-07 06:10:15 +00:00
< / dl >
< / dd >
< dt >
2014-03-14 06:36:05 +00:00
< h4 class = "name" id = "exists" > < span class = "type-signature" > < / span > exists< span class = "type-signature" > < / span > < / h4 >
2013-10-02 00:16:40 +00:00
< / dt >
< dd >
< dl class = "details" >
< h5 class = "subsection-title" > Properties:< / h5 >
< dl >
< table class = "props table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
2014-03-14 06:36:05 +00:00
< td class = "name" > < code > exists< / code > < / td >
2013-10-02 00:16:40 +00:00
< td class = "type" >
2014-03-14 06:36:05 +00:00
< span class = "param-type" > boolean< / span >
2013-10-02 00:16:40 +00:00
< / td >
2014-03-14 06:36:05 +00:00
< td class = "description last" > < p > If exists is true the Group is updated, otherwise it is skipped.< / p > < / td >
2013-10-02 00:16:40 +00:00
< / tr >
< / tbody >
< / table >
< / dl >
2014-03-14 06:36:05 +00:00
< dt class = "tag-default" > Default Value:< / dt >
< dd class = "tag-default" > < ul class = "dummy" > < li > true< / li > < / ul > < / dd >
2013-10-02 00:16:40 +00:00
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-77" > line 77< / a >
2013-10-02 00:16:40 +00:00
< / li > < / ul > < / dd >
< / dl >
< / dd >
< dt >
2014-03-14 06:36:05 +00:00
< h4 class = "name" id = "fixedToCamera" > < span class = "type-signature" > < / span > fixedToCamera< span class = "type-signature" > < / span > < / h4 >
2013-10-02 00:16:40 +00:00
< / dt >
< dd >
2014-03-14 06:36:05 +00:00
< div class = "description" >
< p > A Group that is fixed to the camera uses its x/y coordinates as offsets from the top left of the camera. These are stored in Group.cameraOffset.
Note that the cameraOffset values are in addition to any parent in the display list.
So if this Group was in a Group that has x: 200, then this will be added to the cameraOffset.x< / p >
< / div >
2013-10-02 00:16:40 +00:00
< dl class = "details" >
< h5 class = "subsection-title" > Properties:< / h5 >
< dl >
< table class = "props table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
2014-03-14 06:36:05 +00:00
< td class = "name" > < code > fixedToCamera< / code > < / td >
2013-10-02 00:16:40 +00:00
< td class = "type" >
2014-03-14 06:36:05 +00:00
< span class = "param-type" > boolean< / span >
2013-10-02 00:16:40 +00:00
< / td >
2014-03-14 06:36:05 +00:00
< td class = "description last" > < p > Set to true to fix this Group to the Camera at its current world coordinates.< / p > < / td >
2013-10-02 00:16:40 +00:00
< / tr >
< / tbody >
< / table >
< / dl >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-1826" > line 1826< / a >
2013-10-02 00:16:40 +00:00
< / li > < / ul > < / dd >
< / dl >
< / dd >
< dt >
2014-03-14 06:36:05 +00:00
< h4 class = "name" id = "game" > < span class = "type-signature" > < / span > game< span class = "type-signature" > < / span > < / h4 >
2013-10-02 00:16:40 +00:00
< / dt >
< dd >
< dl class = "details" >
< h5 class = "subsection-title" > Properties:< / h5 >
< dl >
< table class = "props table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
2014-03-14 06:36:05 +00:00
< td class = "name" > < code > game< / code > < / td >
2013-10-02 00:16:40 +00:00
< td class = "type" >
2014-03-14 06:36:05 +00:00
< span class = "param-type" > < a href = "Phaser.Game.html" > Phaser.Game< / a > < / span >
2013-10-02 00:16:40 +00:00
< / td >
2014-03-14 06:36:05 +00:00
< td class = "description last" > < p > A reference to the currently running Game.< / p > < / td >
2013-10-02 00:16:40 +00:00
< / tr >
< / tbody >
< / table >
< / dl >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-30" > line 30< / a >
2014-10-09 15:12:53 +00:00
< / li > < / ul > < / dd >
< / dl >
< / dd >
< dt >
< h4 class = "name" id = "ignoreDestroy" > < span class = "type-signature" > < / span > ignoreDestroy< span class = "type-signature" > < / span > < / h4 >
< / dt >
< dd >
< dl class = "details" >
< h5 class = "subsection-title" > Properties:< / h5 >
< dl >
< table class = "props table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
< td class = "name" > < code > ignoreDestroy< / code > < / td >
< td class = "type" >
< span class = "param-type" > boolean< / span >
< / td >
< td class = "description last" > < p > A Group with < code > ignoreDestroy< / code > set to < code > true< / code > ignores all calls to its < code > destroy< / code > method.< / p > < / td >
< / tr >
< / tbody >
< / table >
< / dl >
< dt class = "tag-default" > Default Value:< / dt >
< dd class = "tag-default" > < ul class = "dummy" > < li > false< / li > < / ul > < / dd >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-83" > line 83< / a >
2013-10-02 00:16:40 +00:00
< / li > < / ul > < / dd >
< / dl >
< / dd >
< dt >
2014-03-14 06:36:05 +00:00
< h4 class = "name" id = "length" > < span class = "type-signature" > < readonly> < / span > length< span class = "type-signature" > < / span > < / h4 >
2013-10-02 00:16:40 +00:00
< / dt >
< dd >
< dl class = "details" >
< h5 class = "subsection-title" > Properties:< / h5 >
< dl >
< table class = "props table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
2014-03-14 06:36:05 +00:00
< td class = "name" > < code > length< / code > < / td >
2013-10-02 00:16:40 +00:00
< td class = "type" >
< span class = "param-type" > number< / span >
< / td >
2014-03-14 06:36:05 +00:00
< td class = "description last" > < p > The total number of children in this Group, regardless of their exists/alive status.< / p > < / td >
2013-10-02 00:16:40 +00:00
< / tr >
< / tbody >
< / table >
< / dl >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-1793" > line 1793< / a >
2013-10-02 00:16:40 +00:00
< / li > < / ul > < / dd >
< / dl >
< / dd >
< dt >
2014-03-14 06:36:05 +00:00
< h4 class = "name" id = "name" > < span class = "type-signature" > < / span > name< span class = "type-signature" > < / span > < / h4 >
2013-10-02 00:16:40 +00:00
< / dt >
< dd >
< dl class = "details" >
< h5 class = "subsection-title" > Properties:< / h5 >
< dl >
< table class = "props table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
2014-03-14 06:36:05 +00:00
< td class = "name" > < code > name< / code > < / td >
2013-10-02 00:16:40 +00:00
< td class = "type" >
2014-03-14 06:36:05 +00:00
< span class = "param-type" > string< / span >
2013-10-02 00:16:40 +00:00
< / td >
2014-03-14 06:36:05 +00:00
< td class = "description last" > < p > A name for this Group. Not used internally but useful for debugging.< / p > < / td >
2013-10-02 00:16:40 +00:00
< / tr >
< / tbody >
< / table >
< / dl >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-40" > line 40< / a >
2013-10-02 00:16:40 +00:00
< / li > < / ul > < / dd >
2014-09-09 14:36:56 +00:00
< / dl >
< / dd >
< dt >
< h4 class = "name" id = "onDestroy" > < span class = "type-signature" > < / span > onDestroy< span class = "type-signature" > < / span > < / h4 >
< / dt >
< dd >
< dl class = "details" >
< h5 class = "subsection-title" > Properties:< / h5 >
< dl >
< table class = "props table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
< td class = "name" > < code > onDestroy< / code > < / td >
< td class = "type" >
< span class = "param-type" > < a href = "Phaser.Signal.html" > Phaser.Signal< / a > < / span >
< / td >
< td class = "description last" > < p > This signal is dispatched when the parent is destoyed.< / p > < / td >
< / tr >
< / tbody >
< / table >
< / dl >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-137" > line 137< / a >
2014-09-09 14:36:56 +00:00
< / li > < / ul > < / dd >
2013-10-02 00:16:40 +00:00
< / dl >
< / dd >
2013-10-23 13:00:28 +00:00
2013-10-02 00:16:40 +00:00
< dt >
2014-03-14 06:36:05 +00:00
< h4 class = "name" id = "physicsBodyType" > < span class = "type-signature" > < / span > physicsBodyType< span class = "type-signature" > < / span > < / h4 >
2013-10-02 00:16:40 +00:00
< / dt >
< dd >
2013-10-23 13:00:28 +00:00
2013-10-02 00:16:40 +00:00
2013-10-23 13:00:28 +00:00
< dl class = "details" >
2013-10-02 00:16:40 +00:00
2013-10-23 13:00:28 +00:00
< h5 class = "subsection-title" > Properties:< / h5 >
< dl >
< table class = "props table table-striped" >
2013-10-02 00:16:40 +00:00
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
2014-03-14 06:36:05 +00:00
< td class = "name" > < code > physicsBodyType< / code > < / td >
2013-10-02 00:16:40 +00:00
< td class = "type" >
2013-10-23 13:00:28 +00:00
< span class = "param-type" > number< / span >
2013-10-02 00:16:40 +00:00
< / td >
2014-03-14 06:36:05 +00:00
< td class = "description last" > < p > If Group.enableBody is true this is the type of physics body that is created on new Sprites. Phaser.Physics.ARCADE, Phaser.Physics.P2, Phaser.Physics.NINJA, etc.< / p > < / td >
2013-10-02 00:16:40 +00:00
< / tr >
< / tbody >
< / table >
2013-10-23 13:00:28 +00:00
< / dl >
2013-10-02 00:16:40 +00:00
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-132" > line 132< / a >
2013-10-02 00:16:40 +00:00
< / li > < / ul > < / dd >
< / dl >
< / dd >
< dt >
2014-03-14 06:36:05 +00:00
< h4 class = "name" id = "rotation" > < span class = "type-signature" > < / span > rotation< span class = "type-signature" > < / span > < / h4 >
2013-10-02 00:16:40 +00:00
< / dt >
< dd >
2014-03-14 06:36:05 +00:00
< div class = "description" >
< p > The angle of rotation of the Group container. This will adjust the Group container itself by modifying its rotation.
This will have no impact on the rotation value of its children, but it will update their worldTransform and on-screen position.< / p >
< / div >
2013-10-02 00:16:40 +00:00
2013-10-23 13:00:28 +00:00
2013-10-02 00:16:40 +00:00
2013-10-23 13:00:28 +00:00
< dl class = "details" >
2013-10-02 00:16:40 +00:00
2013-10-23 13:00:28 +00:00
< h5 class = "subsection-title" > Properties:< / h5 >
< dl >
< table class = "props table table-striped" >
2013-10-02 00:16:40 +00:00
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
2014-03-14 06:36:05 +00:00
< td class = "name" > < code > rotation< / code > < / td >
2013-10-02 00:16:40 +00:00
< td class = "type" >
2013-10-23 13:00:28 +00:00
< span class = "param-type" > number< / span >
2013-10-02 00:16:40 +00:00
< / td >
2014-03-14 06:36:05 +00:00
< td class = "description last" > < p > The angle of rotation given in radians.< / p > < / td >
2013-10-02 00:16:40 +00:00
< / tr >
2013-10-23 13:00:28 +00:00
< / tbody >
< / table >
< / dl >
2013-10-02 00:16:40 +00:00
2013-10-23 13:00:28 +00:00
2013-10-02 00:16:40 +00:00
2013-10-23 13:00:28 +00:00
2013-10-02 00:16:40 +00:00
2013-10-23 13:00:28 +00:00
2013-10-02 00:16:40 +00:00
2013-10-23 13:00:28 +00:00
2013-10-02 00:16:40 +00:00
2013-10-23 13:00:28 +00:00
2013-10-02 00:16:40 +00:00
2013-10-23 13:00:28 +00:00
2013-10-02 00:16:40 +00:00
2013-10-23 13:00:28 +00:00
2013-10-02 00:16:40 +00:00
2013-10-23 13:00:28 +00:00
2013-10-02 00:16:40 +00:00
2013-10-23 13:00:28 +00:00
2013-10-02 00:16:40 +00:00
2013-10-23 13:00:28 +00:00
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-1863" > line 1863< / a >
2013-10-23 13:00:28 +00:00
< / li > < / ul > < / dd >
2013-10-02 00:16:40 +00:00
2013-10-23 13:00:28 +00:00
2013-10-02 00:16:40 +00:00
2013-10-23 13:00:28 +00:00
2013-10-02 00:16:40 +00:00
2013-10-23 13:00:28 +00:00
< / dl >
< / dd >
2013-10-02 00:16:40 +00:00
2014-02-05 06:29:17 +00:00
2013-10-02 00:16:40 +00:00
2013-10-23 13:00:28 +00:00
< dt >
2014-03-14 06:36:05 +00:00
< h4 class = "name" id = "scale" > < span class = "type-signature" > < / span > scale< span class = "type-signature" > < / span > < / h4 >
2013-10-23 13:00:28 +00:00
< / dt >
< dd >
2013-10-02 00:16:40 +00:00
2013-10-23 13:00:28 +00:00
2014-02-05 06:29:17 +00:00
< dl class = "details" >
2013-10-23 13:00:28 +00:00
2014-02-05 06:29:17 +00:00
< h5 class = "subsection-title" > Properties:< / h5 >
< dl >
< table class = "props table table-striped" >
2013-10-23 13:00:28 +00:00
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
2013-10-02 00:16:40 +00:00
2013-10-23 13:00:28 +00:00
< tbody >
2013-10-02 00:16:40 +00:00
< tr >
2014-03-14 06:36:05 +00:00
< td class = "name" > < code > scale< / code > < / td >
2013-10-02 00:16:40 +00:00
< td class = "type" >
2014-03-14 06:36:05 +00:00
< span class = "param-type" > < a href = "Phaser.Point.html" > Phaser.Point< / a > < / span >
2013-10-02 00:16:40 +00:00
< / td >
2014-03-14 06:36:05 +00:00
< td class = "description last" > < p > The scale of the Group container.< / p > < / td >
2013-10-02 00:16:40 +00:00
< / tr >
< / tbody >
< / table >
2014-02-05 06:29:17 +00:00
< / dl >
2013-10-02 00:16:40 +00:00
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-100" > line 100< / a >
2013-10-02 00:16:40 +00:00
< / li > < / ul > < / dd >
< / dl >
2014-02-05 06:29:17 +00:00
< / dd >
2013-10-02 00:16:40 +00:00
2014-02-05 06:29:17 +00:00
< dt >
2014-03-14 06:36:05 +00:00
< h4 class = "name" id = "total" > < span class = "type-signature" > < readonly> < / span > total< span class = "type-signature" > < / span > < / h4 >
2013-10-02 00:16:40 +00:00
2014-02-05 06:29:17 +00:00
< / dt >
< dd >
2013-10-02 00:16:40 +00:00
2014-02-05 06:29:17 +00:00
< dl class = "details" >
2013-10-23 13:00:28 +00:00
2014-02-05 06:29:17 +00:00
< h5 class = "subsection-title" > Properties:< / h5 >
2013-10-23 13:00:28 +00:00
2014-02-05 06:29:17 +00:00
< dl >
2013-10-23 13:00:28 +00:00
2014-02-05 06:29:17 +00:00
< table class = "props table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
2014-03-14 06:36:05 +00:00
< td class = "name" > < code > total< / code > < / td >
2014-02-05 06:29:17 +00:00
< td class = "type" >
< span class = "param-type" > number< / span >
< / td >
2014-03-14 06:36:05 +00:00
< td class = "description last" > < p > The total number of children in this Group who have a state of exists = true.< / p > < / td >
2014-02-05 06:29:17 +00:00
< / tr >
< / tbody >
< / table >
< / dl >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-1778" > line 1778< / a >
2014-02-05 06:29:17 +00:00
< / li > < / ul > < / dd >
< / dl >
< / dd >
< dt >
2014-03-14 06:36:05 +00:00
< h4 class = "name" id = "type" > < span class = "type-signature" > < protected> < / span > type< span class = "type-signature" > < / span > < / h4 >
2014-02-05 06:29:17 +00:00
< / dt >
< dd >
< dl class = "details" >
< h5 class = "subsection-title" > Properties:< / h5 >
< dl >
< table class = "props table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
2014-03-14 06:36:05 +00:00
< td class = "name" > < code > type< / code > < / td >
2014-02-05 06:29:17 +00:00
< td class = "type" >
< span class = "param-type" > number< / span >
< / td >
2014-03-14 06:36:05 +00:00
< td class = "description last" > < p > Internal Phaser Type value.< / p > < / td >
2014-02-05 06:29:17 +00:00
< / tr >
< / tbody >
< / table >
< / dl >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-65" > line 65< / a >
2014-02-05 06:29:17 +00:00
< / li > < / ul > < / dd >
< / dl >
< / dd >
2014-03-14 06:36:05 +00:00
2014-02-05 06:29:17 +00:00
< dt >
2014-03-14 06:36:05 +00:00
< h4 class = "name" id = "visible" > < span class = "type-signature" > < / span > visible< span class = "type-signature" > < / span > < / h4 >
2014-02-05 06:29:17 +00:00
< / dt >
< dd >
2014-03-14 06:36:05 +00:00
< dl class = "details" >
2014-02-05 06:29:17 +00:00
2014-03-14 06:36:05 +00:00
< h5 class = "subsection-title" > Properties:< / h5 >
< dl >
< table class = "props table table-striped" >
2014-02-05 06:29:17 +00:00
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
2014-03-14 06:36:05 +00:00
< td class = "name" > < code > visible< / code > < / td >
2014-02-05 06:29:17 +00:00
< td class = "type" >
2014-03-14 06:36:05 +00:00
< span class = "param-type" > boolean< / span >
2014-02-05 06:29:17 +00:00
< / td >
2014-03-14 06:36:05 +00:00
< td class = "description last" > < p > The visible state of the Group. Non-visible Groups and all of their children are not rendered.< / p > < / td >
2014-02-05 06:29:17 +00:00
< / tr >
< / tbody >
< / table >
2014-03-14 06:36:05 +00:00
< / dl >
2014-02-05 06:29:17 +00:00
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-1865" > line 1865< / a >
2014-02-05 06:29:17 +00:00
< / li > < / ul > < / dd >
2013-10-23 13:00:28 +00:00
< / dl >
2013-10-02 00:16:40 +00:00
< / dd >
< dt >
2014-03-14 06:36:05 +00:00
< h4 class = "name" id = "x" > < span class = "type-signature" > < / span > x< span class = "type-signature" > < / span > < / h4 >
2013-10-02 00:16:40 +00:00
< / dt >
< dd >
< div class = "description" >
2014-03-14 06:36:05 +00:00
< p > The x coordinate of the Group container. You can adjust the Group container itself by modifying its coordinates.
This will have no impact on the x/y coordinates of its children, but it will update their worldTransform and on-screen position.< / p >
2013-10-02 00:16:40 +00:00
< / div >
2014-03-14 06:36:05 +00:00
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< dl class = "details" >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< h5 class = "subsection-title" > Properties:< / h5 >
< dl >
< table class = "props table table-striped" >
2013-10-02 00:16:40 +00:00
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
2014-03-14 06:36:05 +00:00
< td class = "name" > < code > x< / code > < / td >
2013-10-02 00:16:40 +00:00
< td class = "type" >
2013-10-02 10:22:20 +00:00
< span class = "param-type" > number< / span >
2013-10-02 00:16:40 +00:00
< / td >
2014-03-14 06:36:05 +00:00
< td class = "description last" > < p > The x coordinate of the Group container.< / p > < / td >
2013-10-02 00:16:40 +00:00
< / tr >
< / tbody >
< / table >
2014-03-14 06:36:05 +00:00
< / dl >
2013-10-02 00:16:40 +00:00
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-1859" > line 1859< / a >
2013-10-02 00:16:40 +00:00
< / li > < / ul > < / dd >
< / dl >
< / dd >
< dt >
2014-03-14 06:36:05 +00:00
< h4 class = "name" id = "y" > < span class = "type-signature" > < / span > y< span class = "type-signature" > < / span > < / h4 >
2013-10-02 00:16:40 +00:00
< / dt >
< dd >
< div class = "description" >
2014-03-14 06:36:05 +00:00
< p > The y coordinate of the Group container. You can adjust the Group container itself by modifying its coordinates.
This will have no impact on the x/y coordinates of its children, but it will update their worldTransform and on-screen position.< / p >
2013-10-02 00:16:40 +00:00
< / div >
2014-03-14 06:36:05 +00:00
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< dl class = "details" >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< h5 class = "subsection-title" > Properties:< / h5 >
< dl >
< table class = "props table table-striped" >
2013-10-02 00:16:40 +00:00
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
2014-03-14 06:36:05 +00:00
< td class = "name" > < code > y< / code > < / td >
2013-10-23 13:00:28 +00:00
< td class = "type" >
< span class = "param-type" > number< / span >
< / td >
2014-03-14 06:36:05 +00:00
< td class = "description last" > < p > The y coordinate of the Group container.< / p > < / td >
2013-10-02 00:16:40 +00:00
< / tr >
< / tbody >
< / table >
2014-03-14 06:36:05 +00:00
< / dl >
2013-10-02 00:16:40 +00:00
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-1861" > line 1861< / a >
2013-10-02 00:16:40 +00:00
< / li > < / ul > < / dd >
< / dl >
2014-03-14 06:36:05 +00:00
< / dd >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< dt >
< h4 class = "name" id = "z" > < span class = "type-signature" > < / span > z< span class = "type-signature" > < / span > < / h4 >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< / dt >
< dd >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< dl class = "details" >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< h5 class = "subsection-title" > Properties:< / h5 >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< dl >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< table class = "props table table-striped" >
< thead >
< tr >
< th > Name< / th >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< th > Type< / th >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
< td class = "name" > < code > z< / code > < / td >
< td class = "type" >
< span class = "param-type" > number< / span >
< / td >
< td class = "description last" > < p > The z-depth value of this object within its Group (remember the World is a Group as well). No two objects in a Group can have the same z value.< / p > < / td >
< / tr >
< / tbody >
< / table >
2013-10-02 00:16:40 +00:00
< / dl >
2014-03-14 06:36:05 +00:00
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-59" > line 59< / a >
2014-03-14 06:36:05 +00:00
< / li > < / ul > < / dd >
< / dl >
2013-10-02 00:16:40 +00:00
< / dd >
2014-03-14 06:36:05 +00:00
< / dl >
< h3 class = "subsection-title" > Methods< / h3 >
< dl >
2013-10-02 00:16:40 +00:00
< dt >
2014-07-10 19:31:11 +00:00
< h4 class = "name" id = "add" > < span class = "type-signature" > < / span > add< span class = "signature" > (child, < span class = "optional" > silent< / span > )< / span > < span class = "type-signature" > → {*}< / span > < / h4 >
2013-10-02 00:16:40 +00:00
< / dt >
< dd >
< div class = "description" >
2014-03-14 06:36:05 +00:00
< p > Adds an existing object to this Group. The object can be an instance of Phaser.Sprite, Phaser.Button or any other display object.
The child is automatically added to the top of the Group, so renders on-top of everything else within the Group. If you need to control
that then see the addAt method.< / p >
2013-10-02 00:16:40 +00:00
< / div >
< h5 > Parameters:< / h5 >
< table class = "params table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
2014-07-10 19:31:11 +00:00
< th > Argument< / th >
2013-10-02 00:16:40 +00:00
2014-07-10 19:31:11 +00:00
< th > Default< / th >
2013-10-02 00:16:40 +00:00
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
2013-10-23 13:00:28 +00:00
< td class = "name" > < code > child< / code > < / td >
2013-10-02 00:16:40 +00:00
< td class = "type" >
2013-10-23 13:00:28 +00:00
< span class = "param-type" > *< / span >
2013-10-02 00:16:40 +00:00
< / td >
2014-07-10 19:31:11 +00:00
< td class = "attributes" >
2013-10-02 00:16:40 +00:00
2014-07-10 19:31:11 +00:00
< / td >
< td class = "default" >
< / td >
2013-10-02 00:16:40 +00:00
2014-09-09 14:36:56 +00:00
< td class = "description last" > < p > An instance of Phaser.Sprite, Phaser.Button or any other display object.< / p > < / td >
2013-10-23 13:00:28 +00:00
< / tr >
2014-07-10 19:31:11 +00:00
< tr >
< td class = "name" > < code > silent< / code > < / td >
< td class = "type" >
< span class = "param-type" > boolean< / span >
< / td >
< td class = "attributes" >
< optional>< br >
< / td >
< td class = "default" >
false
< / td >
< td class = "description last" > < p > If the silent parameter is < code > true< / code > the child will not dispatch the onAddedToGroup event.< / p > < / td >
< / tr >
2013-10-23 13:00:28 +00:00
< / tbody >
< / table >
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-197" > line 197< / a >
2013-10-23 13:00:28 +00:00
< / li > < / ul > < / dd >
2014-03-14 06:36:05 +00:00
< dt class = "tag-see" > See:< / dt >
< dd class = "tag-see" >
< ul >
< li > < a href = "Phaser.Group.html#create" > Phaser.Group#create< / a > < / li >
< li > < a href = "Phaser.Group.html#addAt" > Phaser.Group#addAt< / a > < / li >
< / ul >
< / dd >
2013-10-23 13:00:28 +00:00
< / dl >
< h5 > Returns:< / h5 >
< div class = "param-desc" >
2014-03-14 06:36:05 +00:00
< p > The child that was added to the Group.< / p >
2013-10-23 13:00:28 +00:00
< / div >
< dl >
< dt >
Type
< / dt >
< dd >
< span class = "param-type" > *< / span >
< / dd >
< / dl >
< / dd >
< dt >
2014-03-14 06:36:05 +00:00
< h4 class = "name" id = "addAll" > < span class = "type-signature" > < / span > addAll< span class = "signature" > (property, amount, checkAlive, checkVisible)< / span > < span class = "type-signature" > < / span > < / h4 >
2013-10-23 13:00:28 +00:00
< / dt >
< dd >
< div class = "description" >
2014-03-14 06:36:05 +00:00
< p > Adds the amount to the given property on all children in this Group.
Group.addAll('x', 10) will add 10 to the child.x value.< / p >
2013-10-23 13:00:28 +00:00
< / div >
< h5 > Parameters:< / h5 >
< table class = "params table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
2014-03-14 06:36:05 +00:00
< td class = "name" > < code > property< / code > < / td >
2013-10-23 13:00:28 +00:00
< td class = "type" >
2013-11-01 18:16:52 +00:00
< span class = "param-type" > string< / span >
< / td >
2014-03-14 06:36:05 +00:00
< td class = "description last" > < p > The property to increment, for example 'body.velocity.x' or 'angle'.< / p > < / td >
2013-11-01 18:16:52 +00:00
< / tr >
< tr >
2014-03-14 06:36:05 +00:00
< td class = "name" > < code > amount< / code > < / td >
2013-11-01 18:16:52 +00:00
< td class = "type" >
2014-03-14 06:36:05 +00:00
< span class = "param-type" > number< / span >
2013-10-23 13:00:28 +00:00
< / td >
2014-03-14 06:36:05 +00:00
< td class = "description last" > < p > The amount to increment the property by. If child.x = 10 then addAll('x', 40) would make child.x = 50.< / p > < / td >
2013-10-02 00:16:40 +00:00
< / tr >
< tr >
2014-03-14 06:36:05 +00:00
< td class = "name" > < code > checkAlive< / code > < / td >
2013-10-02 00:16:40 +00:00
< td class = "type" >
2014-03-14 06:36:05 +00:00
< span class = "param-type" > boolean< / span >
2013-10-02 00:16:40 +00:00
< / td >
2014-03-14 06:36:05 +00:00
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< td class = "description last" > < p > If true the property will only be changed if the child is alive.< / p > < / td >
< / tr >
< tr >
< td class = "name" > < code > checkVisible< / code > < / td >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< td class = "type" >
2013-10-02 00:16:40 +00:00
2013-11-01 18:16:52 +00:00
2014-03-14 06:36:05 +00:00
< span class = "param-type" > boolean< / span >
< / td >
2013-11-01 18:16:52 +00:00
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< td class = "description last" > < p > If true the property will only be changed if the child is visible.< / p > < / td >
2013-10-02 00:16:40 +00:00
< / tr >
< / tbody >
< / table >
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-946" > line 946< / a >
2013-10-02 00:16:40 +00:00
< / li > < / ul > < / dd >
< / dl >
< / dd >
< dt >
2014-07-10 19:31:11 +00:00
< h4 class = "name" id = "addAt" > < span class = "type-signature" > < / span > addAt< span class = "signature" > (child, index, < span class = "optional" > silent< / span > )< / span > < span class = "type-signature" > → {*}< / span > < / h4 >
2013-10-02 00:16:40 +00:00
< / dt >
< dd >
< div class = "description" >
2014-03-14 06:36:05 +00:00
< p > Adds an existing object to this Group. The object can be an instance of Phaser.Sprite, Phaser.Button or any other display object.
The child is added to the Group at the location specified by the index value, this allows you to control child ordering.< / p >
2013-10-02 00:16:40 +00:00
< / div >
< h5 > Parameters:< / h5 >
< table class = "params table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
2014-07-10 19:31:11 +00:00
< th > Argument< / th >
2013-10-02 00:16:40 +00:00
2014-07-10 19:31:11 +00:00
< th > Default< / th >
2013-10-02 00:16:40 +00:00
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
2014-03-14 06:36:05 +00:00
< td class = "name" > < code > child< / code > < / td >
2013-10-02 00:16:40 +00:00
< td class = "type" >
2014-03-14 06:36:05 +00:00
< span class = "param-type" > *< / span >
2013-10-02 00:16:40 +00:00
< / td >
2014-07-10 19:31:11 +00:00
< td class = "attributes" >
2013-10-02 00:16:40 +00:00
2014-07-10 19:31:11 +00:00
< / td >
< td class = "default" >
< / td >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< td class = "description last" > < p > An instance of Phaser.Sprite, Phaser.Button or any other display object..< / p > < / td >
2013-10-02 00:16:40 +00:00
< / tr >
< tr >
2014-03-14 06:36:05 +00:00
< td class = "name" > < code > index< / code > < / td >
2013-10-02 00:16:40 +00:00
< td class = "type" >
2014-03-14 06:36:05 +00:00
< span class = "param-type" > number< / span >
2013-10-02 00:16:40 +00:00
< / td >
2014-07-10 19:31:11 +00:00
< td class = "attributes" >
2013-10-02 00:16:40 +00:00
2014-07-10 19:31:11 +00:00
< / td >
< td class = "default" >
< / td >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< td class = "description last" > < p > The index within the Group to insert the child to.< / p > < / td >
2013-10-23 13:00:28 +00:00
< / tr >
2014-07-10 19:31:11 +00:00
< tr >
< td class = "name" > < code > silent< / code > < / td >
< td class = "type" >
< span class = "param-type" > boolean< / span >
< / td >
< td class = "attributes" >
< optional>< br >
< / td >
< td class = "default" >
false
< / td >
< td class = "description last" > < p > If the silent parameter is < code > true< / code > the child will not dispatch the onAddedToGroup event.< / p > < / td >
< / tr >
2014-03-14 06:36:05 +00:00
< / tbody >
< / table >
2013-10-23 13:00:28 +00:00
2014-03-14 06:36:05 +00:00
< dl class = "details" >
2013-10-23 13:00:28 +00:00
2014-03-14 06:36:05 +00:00
2013-10-23 13:00:28 +00:00
2014-03-14 06:36:05 +00:00
2013-10-23 13:00:28 +00:00
2014-03-14 06:36:05 +00:00
2013-10-23 13:00:28 +00:00
2014-03-14 06:36:05 +00:00
2013-10-23 13:00:28 +00:00
2014-03-14 06:36:05 +00:00
2013-10-23 13:00:28 +00:00
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-263" > line 263< / a >
2013-11-01 18:16:52 +00:00
< / li > < / ul > < / dd >
< / dl >
2014-03-14 06:36:05 +00:00
< h5 > Returns:< / h5 >
< div class = "param-desc" >
< p > The child that was added to the Group.< / p >
< / div >
< dl >
< dt >
Type
< / dt >
< dd >
< span class = "param-type" > *< / span >
< / dd >
< / dl >
2013-11-01 18:16:52 +00:00
2014-09-09 14:36:56 +00:00
< / dd >
< dt >
< h4 class = "name" id = "addMultiple" > < span class = "type-signature" > < / span > addMultiple< span class = "signature" > (children, < span class = "optional" > silent< / span > )< / span > < span class = "type-signature" > → {*}< / span > < / h4 >
< / dt >
< dd >
< div class = "description" >
< p > Adds an array existing objects to this Group. The objects can be instances of Phaser.Sprite, Phaser.Button or any other display object.
The children are automatically added to the top of the Group, so render on-top of everything else within the Group.
TODO: Add ability to pass the children as parameters rather than having to be an array.< / p >
< / div >
< h5 > Parameters:< / h5 >
< table class = "params table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th > Argument< / th >
< th > Default< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
< td class = "name" > < code > children< / code > < / td >
< td class = "type" >
< span class = "param-type" > array< / span >
< / td >
< td class = "attributes" >
< / td >
< td class = "default" >
< / td >
< td class = "description last" > < p > An array containing instances of Phaser.Sprite, Phaser.Button or any other display object.< / p > < / td >
< / tr >
< tr >
< td class = "name" > < code > silent< / code > < / td >
< td class = "type" >
< span class = "param-type" > boolean< / span >
< / td >
< td class = "attributes" >
< optional>< br >
< / td >
< td class = "default" >
false
< / td >
< td class = "description last" > < p > If the silent parameter is < code > true< / code > the children will not dispatch the onAddedToGroup event.< / p > < / td >
< / tr >
< / tbody >
< / table >
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-239" > line 239< / a >
2014-09-09 14:36:56 +00:00
< / li > < / ul > < / dd >
< / dl >
< h5 > Returns:< / h5 >
< div class = "param-desc" >
< p > The array of children that were added to the Group.< / p >
< / div >
< dl >
< dt >
Type
< / dt >
< dd >
< span class = "param-type" > *< / span >
< / dd >
< / dl >
2013-11-01 18:16:52 +00:00
< / dd >
< dt >
2014-03-14 06:36:05 +00:00
< h4 class = "name" id = "ascendingSortHandler" > < span class = "type-signature" > < / span > ascendingSortHandler< span class = "signature" > (a, b)< / span > < span class = "type-signature" > < / span > < / h4 >
2013-11-01 18:16:52 +00:00
< / dt >
< dd >
< div class = "description" >
2014-03-14 06:36:05 +00:00
< p > An internal helper function for the sort process.< / p >
2013-11-01 18:16:52 +00:00
< / div >
< h5 > Parameters:< / h5 >
< table class = "params table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
2014-03-14 06:36:05 +00:00
< td class = "name" > < code > a< / code > < / td >
2013-11-01 18:16:52 +00:00
< td class = "type" >
< span class = "param-type" > object< / span >
< / td >
2014-03-14 06:36:05 +00:00
< td class = "description last" > < p > The first object being sorted.< / p > < / td >
2013-11-01 18:16:52 +00:00
< / tr >
< tr >
2014-03-14 06:36:05 +00:00
< td class = "name" > < code > b< / code > < / td >
2013-11-01 18:16:52 +00:00
< td class = "type" >
2014-03-14 06:36:05 +00:00
< span class = "param-type" > object< / span >
2013-11-01 18:16:52 +00:00
< / td >
2014-03-14 06:36:05 +00:00
< td class = "description last" > < p > The second object being sorted.< / p > < / td >
2013-11-01 18:16:52 +00:00
< / tr >
< / tbody >
< / table >
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-1378" > line 1378< / a >
2013-10-23 13:00:28 +00:00
< / li > < / ul > < / dd >
< / dl >
< / dd >
< dt >
2014-03-14 06:36:05 +00:00
< h4 class = "name" id = "bringToTop" > < span class = "type-signature" > < / span > bringToTop< span class = "signature" > (child)< / span > < span class = "type-signature" > → {*}< / span > < / h4 >
2013-10-23 13:00:28 +00:00
< / dt >
< dd >
< div class = "description" >
2014-03-14 06:36:05 +00:00
< p > Brings the given child to the top of this Group so it renders above all other children.< / p >
2013-10-23 13:00:28 +00:00
< / div >
2014-03-14 06:36:05 +00:00
< h5 > Parameters:< / h5 >
2013-10-23 13:00:28 +00:00
2014-03-14 06:36:05 +00:00
< table class = "params table table-striped" >
< thead >
< tr >
< th > Name< / th >
2013-10-23 13:00:28 +00:00
2014-03-14 06:36:05 +00:00
< th > Type< / th >
2013-10-23 13:00:28 +00:00
2014-03-14 06:36:05 +00:00
2013-10-23 13:00:28 +00:00
2014-03-14 06:36:05 +00:00
2013-10-23 13:00:28 +00:00
2014-03-14 06:36:05 +00:00
< th class = "last" > Description< / th >
< / tr >
< / thead >
2013-10-23 13:00:28 +00:00
2014-03-14 06:36:05 +00:00
< tbody >
2013-10-23 13:00:28 +00:00
2014-03-14 06:36:05 +00:00
< tr >
< td class = "name" > < code > child< / code > < / td >
2013-10-23 13:00:28 +00:00
2014-03-14 06:36:05 +00:00
< td class = "type" >
< span class = "param-type" > *< / span >
2013-10-23 13:00:28 +00:00
2014-03-14 06:36:05 +00:00
< / td >
2013-10-23 13:00:28 +00:00
2014-03-14 06:36:05 +00:00
2013-10-23 13:00:28 +00:00
2014-03-14 06:36:05 +00:00
2013-10-23 13:00:28 +00:00
2014-03-14 06:36:05 +00:00
< td class = "description last" > < p > The child to bring to the top of this Group.< / p > < / td >
< / tr >
2013-10-23 13:00:28 +00:00
2014-03-14 06:36:05 +00:00
< / tbody >
< / table >
2013-10-23 13:00:28 +00:00
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-502" > line 502< / a >
2013-10-23 13:00:28 +00:00
< / li > < / ul > < / dd >
< / dl >
< h5 > Returns:< / h5 >
< div class = "param-desc" >
2014-03-14 06:36:05 +00:00
< p > The child that was moved.< / p >
2013-10-23 13:00:28 +00:00
< / div >
< dl >
< dt >
Type
< / dt >
< dd >
2014-03-14 06:36:05 +00:00
< span class = "param-type" > *< / span >
2013-10-23 13:00:28 +00:00
< / dd >
< / dl >
< / dd >
< dt >
2014-03-14 06:36:05 +00:00
< h4 class = "name" id = "callAll" > < span class = "type-signature" > < / span > callAll< span class = "signature" > (method, < span class = "optional" > context< / span > , parameter)< / span > < span class = "type-signature" > < / span > < / h4 >
2013-10-23 13:00:28 +00:00
< / dt >
< dd >
< div class = "description" >
2014-03-14 06:36:05 +00:00
< p > Calls a function on all of the children regardless if they are dead or alive (see callAllExists if you need control over that)
After the method parameter and context you can add as many extra parameters as you like, which will all be passed to the child.< / p >
2013-10-23 13:00:28 +00:00
< / div >
< h5 > Parameters:< / h5 >
< table class = "params table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th > Argument< / th >
< th > Default< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
2014-03-14 06:36:05 +00:00
< td class = "name" > < code > method< / code > < / td >
2013-10-23 13:00:28 +00:00
< td class = "type" >
2014-03-14 06:36:05 +00:00
< span class = "param-type" > string< / span >
2013-10-23 13:00:28 +00:00
< / td >
< td class = "attributes" >
< / td >
< td class = "default" >
< / td >
2014-03-14 06:36:05 +00:00
< td class = "description last" > < p > A string containing the name of the function that will be called. The function must exist on the child.< / p > < / td >
2013-10-23 13:00:28 +00:00
< / tr >
< tr >
2014-03-14 06:36:05 +00:00
< td class = "name" > < code > context< / code > < / td >
2013-10-23 13:00:28 +00:00
< td class = "type" >
2014-03-14 06:36:05 +00:00
< span class = "param-type" > string< / span >
2013-10-23 13:00:28 +00:00
< / td >
< td class = "attributes" >
2014-03-14 06:36:05 +00:00
< optional>< br >
2013-10-23 13:00:28 +00:00
< / td >
< td class = "default" >
2014-03-14 06:36:05 +00:00
null
2013-10-23 13:00:28 +00:00
< / td >
2014-07-18 11:45:51 +00:00
< td class = "description last" > < p > A string containing the context under which the method will be executed. Set to null to default to the child.< / p > < / td >
< / tr >
< tr >
< td class = "name" > < code > parameter< / code > < / td >
< td class = "type" >
< span class = "param-type" > *< / span >
< / td >
< td class = "attributes" >
< repeatable>< br >
< / td >
< td class = "default" >
< / td >
< td class = "description last" > < p > Additional parameters that will be passed to the method.< / p > < / td >
< / tr >
< / tbody >
< / table >
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-1086" > line 1086< / a >
2014-07-18 11:45:51 +00:00
< / li > < / ul > < / dd >
< / dl >
< / dd >
< dt >
< h4 class = "name" id = "callAllExists" > < span class = "type-signature" > < / span > callAllExists< span class = "signature" > (callback, existsValue, parameter)< / span > < span class = "type-signature" > < / span > < / h4 >
< / dt >
< dd >
< div class = "description" >
< p > Calls a function on all of the children that have exists=true in this Group.
After the existsValue parameter you can add as many parameters as you like, which will all be passed to the child callback.< / p >
< / div >
< h5 > Parameters:< / h5 >
< table class = "params table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th > Argument< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
< td class = "name" > < code > callback< / code > < / td >
< td class = "type" >
< span class = "param-type" > function< / span >
< / td >
< td class = "attributes" >
< / td >
< td class = "description last" > < p > The function that exists on the children that will be called.< / p > < / td >
< / tr >
< tr >
< td class = "name" > < code > existsValue< / code > < / td >
< td class = "type" >
< span class = "param-type" > boolean< / span >
< / td >
< td class = "attributes" >
< / td >
< td class = "description last" > < p > Only children with exists=existsValue will be called.< / p > < / td >
< / tr >
< tr >
< td class = "name" > < code > parameter< / code > < / td >
< td class = "type" >
< span class = "param-type" > *< / span >
< / td >
< td class = "attributes" >
< repeatable>< br >
< / td >
< td class = "description last" > < p > Additional parameters that will be passed to the callback.< / p > < / td >
< / tr >
< / tbody >
< / table >
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-1010" > line 1010< / a >
2014-07-18 11:45:51 +00:00
< / li > < / ul > < / dd >
< / dl >
< / dd >
< dt >
< h4 class = "name" id = "callbackFromArray" > < span class = "type-signature" > < protected> < / span > callbackFromArray< span class = "signature" > (child, callback, length)< / span > < span class = "type-signature" > < / span > < / h4 >
< / dt >
< dd >
< div class = "description" >
< p > Returns a reference to a function that exists on a child of the Group based on the given callback array.< / p >
< / div >
< h5 > Parameters:< / h5 >
< table class = "params table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
< td class = "name" > < code > child< / code > < / td >
< td class = "type" >
< span class = "param-type" > object< / span >
< / td >
< td class = "description last" > < p > The object to inspect.< / p > < / td >
< / tr >
< tr >
< td class = "name" > < code > callback< / code > < / td >
< td class = "type" >
< span class = "param-type" > array< / span >
< / td >
< td class = "description last" > < p > The array of function names.< / p > < / td >
2013-10-23 13:00:28 +00:00
< / tr >
< tr >
2014-07-18 11:45:51 +00:00
< td class = "name" > < code > length< / code > < / td >
2013-10-23 13:00:28 +00:00
< td class = "type" >
2014-07-18 11:45:51 +00:00
< span class = "param-type" > number< / span >
2013-10-23 13:00:28 +00:00
< / td >
2014-07-18 11:45:51 +00:00
< td class = "description last" > < p > The size of the array (pre-calculated in callAll).< / p > < / td >
2013-10-23 13:00:28 +00:00
< / tr >
2014-03-14 06:36:05 +00:00
< / tbody >
< / table >
2013-10-23 13:00:28 +00:00
2014-03-14 06:36:05 +00:00
< dl class = "details" >
2013-10-23 13:00:28 +00:00
2014-03-14 06:36:05 +00:00
2013-10-23 13:00:28 +00:00
2014-03-14 06:36:05 +00:00
2013-10-23 13:00:28 +00:00
2014-03-14 06:36:05 +00:00
2013-10-23 13:00:28 +00:00
2014-03-14 06:36:05 +00:00
2013-10-23 13:00:28 +00:00
2014-03-14 06:36:05 +00:00
2013-10-23 13:00:28 +00:00
2014-03-14 06:36:05 +00:00
2013-10-02 00:16:40 +00:00
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-1033" > line 1033< / a >
2013-10-02 00:16:40 +00:00
< / li > < / ul > < / dd >
< / dl >
< / dd >
< dt >
2014-07-18 11:45:51 +00:00
< h4 class = "name" id = "checkAll" > < span class = "type-signature" > < / span > checkAll< span class = "signature" > (key, value, < span class = "optional" > checkAlive< / span > , < span class = "optional" > checkVisible< / span > , < span class = "optional" > force< / span > )< / span > < span class = "type-signature" > < / span > < / h4 >
2013-10-02 00:16:40 +00:00
< / dt >
< dd >
< div class = "description" >
2014-07-18 11:45:51 +00:00
< p > This function allows you to quickly check that the same property across all children of this Group is equal to the given value.
This call doesn't descend down children, so if you have a Group inside of this Group, the property will be checked on the Group but not its children.< / p >
2013-10-02 00:16:40 +00:00
< / div >
< h5 > Parameters:< / h5 >
< table class = "params table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th > Argument< / th >
2014-07-18 11:45:51 +00:00
< th > Default< / th >
2013-10-02 00:16:40 +00:00
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
2014-07-18 11:45:51 +00:00
< td class = "name" > < code > key< / code > < / td >
2013-10-02 00:16:40 +00:00
< td class = "type" >
2014-07-18 11:45:51 +00:00
< span class = "param-type" > string< / span >
2013-10-02 00:16:40 +00:00
< / td >
< td class = "attributes" >
< / td >
2014-07-18 11:45:51 +00:00
< td class = "default" >
< / td >
2013-10-02 00:16:40 +00:00
2014-07-18 11:45:51 +00:00
< td class = "description last" > < p > The property, as a string, to be set. For example: 'body.velocity.x'< / p > < / td >
2013-10-02 00:16:40 +00:00
< / tr >
< tr >
2014-07-18 11:45:51 +00:00
< td class = "name" > < code > value< / code > < / td >
< td class = "type" >
< span class = "param-type" > *< / span >
< / td >
< td class = "attributes" >
< / td >
< td class = "default" >
< / td >
< td class = "description last" > < p > The value that will be checked.< / p > < / td >
< / tr >
< tr >
< td class = "name" > < code > checkAlive< / code > < / td >
2013-10-02 00:16:40 +00:00
< td class = "type" >
2014-03-14 06:36:05 +00:00
< span class = "param-type" > boolean< / span >
2013-10-02 00:16:40 +00:00
< / td >
< td class = "attributes" >
2014-07-18 11:45:51 +00:00
< optional>< br >
2013-10-02 00:16:40 +00:00
< / td >
2014-07-18 11:45:51 +00:00
< td class = "default" >
false
< / td >
2013-10-02 00:16:40 +00:00
2014-07-18 11:45:51 +00:00
< td class = "description last" > < p > If set then only children with alive=true will be checked. This includes any Groups that are children.< / p > < / td >
2013-10-02 00:16:40 +00:00
< / tr >
< tr >
2014-07-18 11:45:51 +00:00
< td class = "name" > < code > checkVisible< / code > < / td >
2013-10-02 00:16:40 +00:00
< td class = "type" >
2014-07-18 11:45:51 +00:00
< span class = "param-type" > boolean< / span >
2013-10-02 00:16:40 +00:00
< / td >
< td class = "attributes" >
2014-07-18 11:45:51 +00:00
< optional>< br >
2013-10-02 00:16:40 +00:00
2014-07-18 11:45:51 +00:00
< / td >
< td class = "default" >
false
2013-10-02 00:16:40 +00:00
< / td >
2014-07-18 11:45:51 +00:00
< td class = "description last" > < p > If set then only children with visible=true will be checked. This includes any Groups that are children.< / p > < / td >
< / tr >
< tr >
< td class = "name" > < code > force< / code > < / td >
2013-10-02 00:16:40 +00:00
2014-07-18 11:45:51 +00:00
< td class = "type" >
< span class = "param-type" > boolean< / span >
< / td >
< td class = "attributes" >
< optional>< br >
< / td >
< td class = "default" >
false
< / td >
< td class = "description last" > < p > If < code > force< / code > is true then the property will be checked on the child regardless if it already exists or not. If true and the property doesn't exist, false will be returned.< / p > < / td >
2013-10-02 00:16:40 +00:00
< / tr >
< / tbody >
< / table >
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-914" > line 914< / a >
2013-10-02 00:16:40 +00:00
< / li > < / ul > < / dd >
< / dl >
< / dd >
< dt >
2014-07-18 11:45:51 +00:00
< h4 class = "name" id = "checkProperty" > < span class = "type-signature" > < / span > checkProperty< span class = "signature" > (child, key, value, < span class = "optional" > force< / span > )< / span > < span class = "type-signature" > → {boolean}< / span > < / h4 >
2013-10-02 00:16:40 +00:00
< / dt >
< dd >
< div class = "description" >
2014-07-18 11:45:51 +00:00
< p > Checks a property for the given value on the child.< / p >
2013-10-02 00:16:40 +00:00
< / div >
< h5 > Parameters:< / h5 >
< table class = "params table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
2014-07-18 11:45:51 +00:00
< th > Argument< / th >
2013-10-02 00:16:40 +00:00
2014-07-18 11:45:51 +00:00
< th > Default< / th >
2013-10-02 00:16:40 +00:00
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
2014-03-14 06:36:05 +00:00
< td class = "name" > < code > child< / code > < / td >
2013-10-02 00:16:40 +00:00
< td class = "type" >
2014-07-18 11:45:51 +00:00
< span class = "param-type" > *< / span >
2013-10-02 00:16:40 +00:00
< / td >
2014-07-18 11:45:51 +00:00
< td class = "attributes" >
< / td >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
2014-07-18 11:45:51 +00:00
< td class = "default" >
< / td >
2013-10-02 00:16:40 +00:00
2014-07-18 11:45:51 +00:00
< td class = "description last" > < p > The child to check the property value on.< / p > < / td >
2014-03-14 06:36:05 +00:00
< / tr >
< tr >
2014-07-18 11:45:51 +00:00
< td class = "name" > < code > key< / code > < / td >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< td class = "type" >
2013-10-02 00:16:40 +00:00
2014-02-05 06:29:17 +00:00
2014-03-14 06:36:05 +00:00
< span class = "param-type" > array< / span >
< / td >
2014-07-18 11:45:51 +00:00
< td class = "attributes" >
2014-03-14 06:36:05 +00:00
2014-07-18 11:45:51 +00:00
< / td >
2014-03-14 06:36:05 +00:00
2014-07-18 11:45:51 +00:00
< td class = "default" >
< / td >
< td class = "description last" > < p > An array of strings that make up the property that will be set.< / p > < / td >
2014-03-14 06:36:05 +00:00
< / tr >
< tr >
2014-07-18 11:45:51 +00:00
< td class = "name" > < code > value< / code > < / td >
2014-03-14 06:36:05 +00:00
< td class = "type" >
2014-02-05 06:29:17 +00:00
2014-07-18 11:45:51 +00:00
< span class = "param-type" > *< / span >
2014-03-14 06:36:05 +00:00
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< / td >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
2014-07-18 11:45:51 +00:00
< td class = "attributes" >
< / td >
2014-03-14 06:36:05 +00:00
2014-07-18 11:45:51 +00:00
< td class = "default" >
< / td >
2014-03-14 06:36:05 +00:00
2014-07-18 11:45:51 +00:00
< td class = "description last" > < p > The value that will be checked.< / p > < / td >
< / tr >
< tr >
< td class = "name" > < code > force< / code > < / td >
< td class = "type" >
< span class = "param-type" > boolean< / span >
< / td >
< td class = "attributes" >
< optional>< br >
< / td >
< td class = "default" >
false
< / td >
< td class = "description last" > < p > If < code > force< / code > is true then the property will be checked on the child regardless if it already exists or not. If true and the property doesn't exist, false will be returned.< / p > < / td >
2013-10-02 00:16:40 +00:00
< / tr >
< / tbody >
< / table >
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-780" > line 780< / a >
2013-10-02 00:16:40 +00:00
< / li > < / ul > < / dd >
< / dl >
2014-07-18 11:45:51 +00:00
< h5 > Returns:< / h5 >
< div class = "param-desc" >
< p > True if the property was was equal to value, false if not.< / p >
< / div >
< dl >
< dt >
Type
< / dt >
< dd >
< span class = "param-type" > boolean< / span >
< / dd >
< / dl >
2013-10-02 00:16:40 +00:00
< / dd >
< dt >
2014-03-14 06:36:05 +00:00
< h4 class = "name" id = "countDead" > < span class = "type-signature" > < / span > countDead< span class = "signature" > ()< / span > < span class = "type-signature" > → {number}< / span > < / h4 >
2013-10-02 00:16:40 +00:00
< / dt >
< dd >
< div class = "description" >
2014-03-14 06:36:05 +00:00
< p > Call this function to find out how many members of the group are dead.< / p >
2013-10-02 00:16:40 +00:00
< / div >
2014-03-14 06:36:05 +00:00
< dl class = "details" >
2013-10-02 10:22:20 +00:00
2014-03-14 06:36:05 +00:00
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-1576" > line 1576< / a >
2014-03-14 06:36:05 +00:00
< / li > < / ul > < / dd >
< / dl >
< h5 > Returns:< / h5 >
< div class = "param-desc" >
< p > The number of children flagged as dead.< / p >
< / div >
< dl >
< dt >
Type
< / dt >
< dd >
< span class = "param-type" > number< / span >
< / dd >
< / dl >
< / dd >
< dt >
< h4 class = "name" id = "countLiving" > < span class = "type-signature" > < / span > countLiving< span class = "signature" > ()< / span > < span class = "type-signature" > → {number}< / span > < / h4 >
< / dt >
< dd >
< div class = "description" >
< p > Call this function to find out how many members of the group are alive.< / p >
< / div >
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-1564" > line 1564< / a >
2014-03-14 06:36:05 +00:00
< / li > < / ul > < / dd >
< / dl >
< h5 > Returns:< / h5 >
< div class = "param-desc" >
< p > The number of children flagged as alive.< / p >
< / div >
< dl >
< dt >
Type
< / dt >
< dd >
< span class = "param-type" > number< / span >
< / dd >
< / dl >
< / dd >
< dt >
2014-04-29 14:39:02 +00:00
< h4 class = "name" id = "create" > < span class = "type-signature" > < / span > create< span class = "signature" > (x, y, key, < span class = "optional" > frame< / span > , < span class = "optional" > exists< / span > )< / span > < span class = "type-signature" > → {< a href = "Phaser.Sprite.html" > Phaser.Sprite< / a > |object}< / span > < / h4 >
2014-03-14 06:36:05 +00:00
< / dt >
< dd >
< div class = "description" >
< p > Automatically creates a new Phaser.Sprite object and adds it to the top of this Group.
2014-04-29 14:39:02 +00:00
You can change Group.classType to any object and this call will create an object of that type instead, but it should extend either Sprite or Image.< / p >
2014-03-14 06:36:05 +00:00
< / div >
< h5 > Parameters:< / h5 >
< table class = "params table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th > Argument< / th >
< th > Default< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
< td class = "name" > < code > x< / code > < / td >
< td class = "type" >
< span class = "param-type" > number< / span >
< / td >
< td class = "attributes" >
< / td >
< td class = "default" >
< / td >
< td class = "description last" > < p > The x coordinate to display the newly created Sprite at. The value is in relation to the Group.x point.< / p > < / td >
< / tr >
< tr >
< td class = "name" > < code > y< / code > < / td >
< td class = "type" >
< span class = "param-type" > number< / span >
< / td >
< td class = "attributes" >
< / td >
< td class = "default" >
< / td >
< td class = "description last" > < p > The y coordinate to display the newly created Sprite at. The value is in relation to the Group.y point.< / p > < / td >
< / tr >
< tr >
< td class = "name" > < code > key< / code > < / td >
< td class = "type" >
< span class = "param-type" > string< / span >
< / td >
< td class = "attributes" >
< / td >
< td class = "default" >
< / td >
< td class = "description last" > < p > The Game.cache key of the image that this Sprite will use.< / p > < / td >
< / tr >
< tr >
< td class = "name" > < code > frame< / code > < / td >
< td class = "type" >
< span class = "param-type" > number< / span >
|
< span class = "param-type" > string< / span >
< / td >
< td class = "attributes" >
< optional>< br >
< / td >
< td class = "default" >
< / td >
< td class = "description last" > < p > If the Sprite image contains multiple frames you can specify which one to use here.< / p > < / td >
< / tr >
< tr >
< td class = "name" > < code > exists< / code > < / td >
< td class = "type" >
< span class = "param-type" > boolean< / span >
< / td >
< td class = "attributes" >
< optional>< br >
< / td >
< td class = "default" >
true
< / td >
< td class = "description last" > < p > The default exists state of the Sprite.< / p > < / td >
< / tr >
< / tbody >
< / table >
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-323" > line 323< / a >
2014-03-14 06:36:05 +00:00
< / li > < / ul > < / dd >
< / dl >
< h5 > Returns:< / h5 >
< div class = "param-desc" >
2014-04-29 14:39:02 +00:00
< p > The child that was created. Will be a Phaser.Sprite unless Group.classType has been changed.< / p >
2014-03-14 06:36:05 +00:00
< / div >
< dl >
< dt >
Type
< / dt >
< dd >
< span class = "param-type" > < a href = "Phaser.Sprite.html" > Phaser.Sprite< / a > < / span >
2014-04-29 14:39:02 +00:00
|
< span class = "param-type" > object< / span >
2014-03-14 06:36:05 +00:00
< / dd >
< / dl >
< / dd >
< dt >
< h4 class = "name" id = "createMultiple" > < span class = "type-signature" > < / span > createMultiple< span class = "signature" > (quantity, key, < span class = "optional" > frame< / span > , < span class = "optional" > exists< / span > )< / span > < span class = "type-signature" > < / span > < / h4 >
< / dt >
< dd >
< div class = "description" >
< p > Automatically creates multiple Phaser.Sprite objects and adds them to the top of this Group.
Useful if you need to quickly generate a pool of identical sprites, such as bullets. By default the sprites will be set to not exist
2014-04-29 14:39:02 +00:00
and will be positioned at 0, 0 (relative to the Group.x/y)
You can change Group.classType to any object and this call will create an object of that type instead, but it should extend either Sprite or Image.< / p >
2014-03-14 06:36:05 +00:00
< / div >
< h5 > Parameters:< / h5 >
< table class = "params table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th > Argument< / th >
< th > Default< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
< td class = "name" > < code > quantity< / code > < / td >
< td class = "type" >
< span class = "param-type" > number< / span >
< / td >
< td class = "attributes" >
< / td >
< td class = "default" >
< / td >
< td class = "description last" > < p > The number of Sprites to create.< / p > < / td >
< / tr >
< tr >
< td class = "name" > < code > key< / code > < / td >
< td class = "type" >
< span class = "param-type" > string< / span >
< / td >
< td class = "attributes" >
< / td >
< td class = "default" >
< / td >
< td class = "description last" > < p > The Game.cache key of the image that this Sprite will use.< / p > < / td >
< / tr >
< tr >
< td class = "name" > < code > frame< / code > < / td >
< td class = "type" >
< span class = "param-type" > number< / span >
|
< span class = "param-type" > string< / span >
< / td >
< td class = "attributes" >
< optional>< br >
< / td >
< td class = "default" >
< / td >
< td class = "description last" > < p > If the Sprite image contains multiple frames you can specify which one to use here.< / p > < / td >
< / tr >
< tr >
< td class = "name" > < code > exists< / code > < / td >
< td class = "type" >
< span class = "param-type" > boolean< / span >
< / td >
< td class = "attributes" >
< optional>< br >
< / td >
< td class = "default" >
false
< / td >
< td class = "description last" > < p > The default exists state of the Sprite.< / p > < / td >
< / tr >
< / tbody >
< / table >
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-368" > line 368< / a >
2014-03-14 06:36:05 +00:00
< / li > < / ul > < / dd >
< / dl >
2014-04-10 22:13:43 +00:00
< / dd >
< dt >
< h4 class = "name" id = "customSort" > < span class = "type-signature" > < / span > customSort< span class = "signature" > (sortHandler, context)< / span > < span class = "type-signature" > < / span > < / h4 >
< / dt >
< dd >
< div class = "description" >
< p > This allows you to use your own sort handler function.
It will be sent two parameters: the two children involved in the comparison (a and b). It should return -1 if a > b, 1 if a < b or 0 if a === b.< / p >
< / div >
< h5 > Parameters:< / h5 >
< table class = "params table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
< td class = "name" > < code > sortHandler< / code > < / td >
< td class = "type" >
< span class = "param-type" > function< / span >
< / td >
< td class = "description last" > < p > Your sort handler function. It will be sent two parameters: the two children involved in the comparison. It must return -1, 1 or 0.< / p > < / td >
< / tr >
< tr >
< td class = "name" > < code > context< / code > < / td >
< td class = "type" >
< span class = "param-type" > object< / span >
< / td >
< td class = "description last" > < p > The scope in which the sortHandler is called.< / p > < / td >
< / tr >
< / tbody >
< / table >
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-1356" > line 1356< / a >
2014-04-10 22:13:43 +00:00
< / li > < / ul > < / dd >
< / dl >
2014-03-14 06:36:05 +00:00
< / dd >
< dt >
< h4 class = "name" id = "descendingSortHandler" > < span class = "type-signature" > < / span > descendingSortHandler< span class = "signature" > (a, b)< / span > < span class = "type-signature" > < / span > < / h4 >
< / dt >
< dd >
< div class = "description" >
< p > An internal helper function for the sort process.< / p >
< / div >
< h5 > Parameters:< / h5 >
< table class = "params table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
< td class = "name" > < code > a< / code > < / td >
< td class = "type" >
< span class = "param-type" > object< / span >
< / td >
< td class = "description last" > < p > The first object being sorted.< / p > < / td >
< / tr >
< tr >
< td class = "name" > < code > b< / code > < / td >
< td class = "type" >
< span class = "param-type" > object< / span >
< / td >
< td class = "description last" > < p > The second object being sorted.< / p > < / td >
< / tr >
< / tbody >
< / table >
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-1409" > line 1409< / a >
2014-03-14 06:36:05 +00:00
< / li > < / ul > < / dd >
< / dl >
< / dd >
< dt >
2014-03-24 12:41:45 +00:00
< h4 class = "name" id = "destroy" > < span class = "type-signature" > < / span > destroy< span class = "signature" > (< span class = "optional" > destroyChildren< / span > , < span class = "optional" > soft< / span > )< / span > < span class = "type-signature" > < / span > < / h4 >
2014-03-14 06:36:05 +00:00
< / dt >
< dd >
< div class = "description" >
< p > Destroys this Group. Removes all children, then removes the container from the display list and nulls references.< / p >
< / div >
< h5 > Parameters:< / h5 >
< table class = "params table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th > Argument< / th >
< th > Default< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
< td class = "name" > < code > destroyChildren< / code > < / td >
< td class = "type" >
< span class = "param-type" > boolean< / span >
< / td >
< td class = "attributes" >
< optional>< br >
< / td >
< td class = "default" >
true
< / td >
< td class = "description last" > < p > Should every child of this Group have its destroy method called?< / p > < / td >
< / tr >
2014-03-24 12:41:45 +00:00
< tr >
< td class = "name" > < code > soft< / code > < / td >
< td class = "type" >
< span class = "param-type" > boolean< / span >
< / td >
< td class = "attributes" >
< optional>< br >
< / td >
< td class = "default" >
false
< / td >
< td class = "description last" > < p > A 'soft destroy' (set to true) doesn't remove this Group from its parent or null the game reference. Set to false and it does.< / p > < / td >
< / tr >
2014-03-14 06:36:05 +00:00
< / tbody >
< / table >
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-1744" > line 1744< / a >
2014-03-14 06:36:05 +00:00
< / li > < / ul > < / dd >
< / dl >
< / dd >
< dt >
< h4 class = "name" id = "divideAll" > < span class = "type-signature" > < / span > divideAll< span class = "signature" > (property, amount, checkAlive, checkVisible)< / span > < span class = "type-signature" > < / span > < / h4 >
< / dt >
< dd >
< div class = "description" >
< p > Divides the given property by the amount on all children in this Group.
Group.divideAll('x', 2) will half the child.x value.< / p >
< / div >
< h5 > Parameters:< / h5 >
< table class = "params table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
< td class = "name" > < code > property< / code > < / td >
< td class = "type" >
< span class = "param-type" > string< / span >
< / td >
< td class = "description last" > < p > The property to divide, for example 'body.velocity.x' or 'angle'.< / p > < / td >
< / tr >
< tr >
< td class = "name" > < code > amount< / code > < / td >
< td class = "type" >
< span class = "param-type" > number< / span >
< / td >
< td class = "description last" > < p > The amount to divide the property by. If child.x = 100 then divideAll('x', 2) would make child.x = 50.< / p > < / td >
< / tr >
< tr >
< td class = "name" > < code > checkAlive< / code > < / td >
< td class = "type" >
< span class = "param-type" > boolean< / span >
< / td >
< td class = "description last" > < p > If true the property will only be changed if the child is alive.< / p > < / td >
< / tr >
< tr >
< td class = "name" > < code > checkVisible< / code > < / td >
< td class = "type" >
< span class = "param-type" > boolean< / span >
< / td >
< td class = "description last" > < p > If true the property will only be changed if the child is visible.< / p > < / td >
< / tr >
< / tbody >
< / table >
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-994" > line 994< / a >
2014-10-09 15:12:53 +00:00
< / li > < / ul > < / dd >
< / dl >
< / dd >
< dt >
< h4 class = "name" id = "filter" > < span class = "type-signature" > < / span > filter< span class = "signature" > (predicate, < span class = "optional" > checkExists< / span > )< / span > < span class = "type-signature" > → {< a href = "Phaser.ArrayList.html" > Phaser.ArrayList< / a > }< / span > < / h4 >
< / dt >
< dd >
< div class = "description" >
< p > Allows you to obtain a Phaser.ArrayList of children that return true for the given predicate
For example:
var healthyList = Group.filter(function(child, index, children) {
return child.health > 10 ? true : false;
}, true);
healthyList.callAll('attack');
Note: Currently this will skip any children which are Groups themselves.< / p >
< / div >
< h5 > Parameters:< / h5 >
< table class = "params table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th > Argument< / th >
< th > Default< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
< td class = "name" > < code > predicate< / code > < / td >
< td class = "type" >
< span class = "param-type" > function< / span >
< / td >
< td class = "attributes" >
< / td >
< td class = "default" >
< / td >
< td class = "description last" > < p > The function that each child will be evaluated against. Each child of the Group will be passed to it as its first parameter, the index as the second, and the entire child array as the third< / p > < / td >
< / tr >
< tr >
< td class = "name" > < code > checkExists< / code > < / td >
< td class = "type" >
< span class = "param-type" > boolean< / span >
< / td >
< td class = "attributes" >
< optional>< br >
< / td >
< td class = "default" >
false
< / td >
< td class = "description last" > < p > If set only children with exists=true will be passed to the callback, otherwise all children will be passed.< / p > < / td >
< / tr >
< / tbody >
< / table >
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-1210" > line 1210< / a >
2014-03-14 06:36:05 +00:00
< / li > < / ul > < / dd >
< / dl >
2014-10-09 15:12:53 +00:00
< h5 > Returns:< / h5 >
< div class = "param-desc" >
< p > Returns an array list containing all the children that the predicate returned true for< / p >
< / div >
< dl >
< dt >
Type
< / dt >
< dd >
< span class = "param-type" > < a href = "Phaser.ArrayList.html" > Phaser.ArrayList< / a > < / span >
< / dd >
< / dl >
2014-03-14 06:36:05 +00:00
< / dd >
< dt >
2014-03-28 01:42:49 +00:00
< h4 class = "name" id = "forEach" > < span class = "type-signature" > < / span > forEach< span class = "signature" > (callback, callbackContext, < span class = "optional" > checkExists< / span > )< / span > < span class = "type-signature" > < / span > < / h4 >
2014-03-14 06:36:05 +00:00
< / dt >
< dd >
< div class = "description" >
< p > Allows you to call your own function on each member of this Group. You must pass the callback and context in which it will run.
After the checkExists parameter you can add as many parameters as you like, which will all be passed to the callback along with the child.
For example: Group.forEach(awardBonusGold, this, true, 100, 500)
Note: Currently this will skip any children which are Groups themselves.< / p >
< / div >
< h5 > Parameters:< / h5 >
< table class = "params table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
2014-03-28 01:42:49 +00:00
< th > Argument< / th >
2014-03-14 06:36:05 +00:00
2014-03-28 01:42:49 +00:00
< th > Default< / th >
2014-03-14 06:36:05 +00:00
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
< td class = "name" > < code > callback< / code > < / td >
< td class = "type" >
< span class = "param-type" > function< / span >
< / td >
2014-03-28 01:42:49 +00:00
< td class = "attributes" >
< / td >
2014-03-14 06:36:05 +00:00
2014-03-28 01:42:49 +00:00
< td class = "default" >
< / td >
2014-03-14 06:36:05 +00:00
< td class = "description last" > < p > The function that will be called. Each child of the Group will be passed to it as its first parameter.< / p > < / td >
< / tr >
< tr >
< td class = "name" > < code > callbackContext< / code > < / td >
< td class = "type" >
2014-04-11 12:09:28 +00:00
< span class = "param-type" > Object< / span >
2014-03-14 06:36:05 +00:00
< / td >
2014-03-28 01:42:49 +00:00
< td class = "attributes" >
< / td >
2014-03-14 06:36:05 +00:00
2014-03-28 01:42:49 +00:00
< td class = "default" >
< / td >
2014-03-14 06:36:05 +00:00
< td class = "description last" > < p > The context in which the function should be called (usually 'this').< / p > < / td >
< / tr >
< tr >
< td class = "name" > < code > checkExists< / code > < / td >
< td class = "type" >
< span class = "param-type" > boolean< / span >
< / td >
2014-03-28 01:42:49 +00:00
< td class = "attributes" >
< optional>< br >
< / td >
2014-03-14 06:36:05 +00:00
2014-03-28 01:42:49 +00:00
< td class = "default" >
false
< / td >
2014-03-14 06:36:05 +00:00
< td class = "description last" > < p > If set only children with exists=true will be passed to the callback, otherwise all children will be passed.< / p > < / td >
< / tr >
< / tbody >
< / table >
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-1239" > line 1239< / a >
2014-03-14 06:36:05 +00:00
< / li > < / ul > < / dd >
< / dl >
< / dd >
< dt >
< h4 class = "name" id = "forEachAlive" > < span class = "type-signature" > < / span > forEachAlive< span class = "signature" > (callback, callbackContext)< / span > < span class = "type-signature" > < / span > < / h4 >
< / dt >
< dd >
< div class = "description" >
< p > Allows you to call your own function on each alive member of this Group (where child.alive=true). You must pass the callback and context in which it will run.
You can add as many parameters as you like, which will all be passed to the callback along with the child.
For example: Group.forEachAlive(causeDamage, this, 500)< / p >
< / div >
< h5 > Parameters:< / h5 >
< table class = "params table table-striped" >
2013-10-02 10:22:20 +00:00
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
2014-03-14 06:36:05 +00:00
< td class = "name" > < code > callback< / code > < / td >
2013-10-02 10:22:20 +00:00
< td class = "type" >
2014-03-14 06:36:05 +00:00
< span class = "param-type" > function< / span >
2013-10-02 10:22:20 +00:00
< / td >
2014-02-05 06:29:17 +00:00
2014-03-14 06:36:05 +00:00
< td class = "description last" > < p > The function that will be called. Each child of the Group will be passed to it as its first parameter.< / p > < / td >
2014-02-05 06:29:17 +00:00
< / tr >
2013-10-02 10:22:20 +00:00
2014-02-05 06:29:17 +00:00
< tr >
2014-03-14 06:36:05 +00:00
< td class = "name" > < code > callbackContext< / code > < / td >
2014-02-05 06:29:17 +00:00
< td class = "type" >
2013-10-02 10:22:20 +00:00
2014-04-11 12:09:28 +00:00
< span class = "param-type" > Object< / span >
2014-02-05 06:29:17 +00:00
< / td >
2013-10-02 10:22:20 +00:00
2014-02-05 06:29:17 +00:00
2014-03-14 06:36:05 +00:00
< td class = "description last" > < p > The context in which the function should be called (usually 'this').< / p > < / td >
2014-02-05 06:29:17 +00:00
< / tr >
2014-03-14 06:36:05 +00:00
< / tbody >
< / table >
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-1286" > line 1286< / a >
2014-03-14 06:36:05 +00:00
< / li > < / ul > < / dd >
< / dl >
< / dd >
< dt >
< h4 class = "name" id = "forEachDead" > < span class = "type-signature" > < / span > forEachDead< span class = "signature" > (callback, callbackContext)< / span > < span class = "type-signature" > < / span > < / h4 >
< / dt >
< dd >
< div class = "description" >
< p > Allows you to call your own function on each dead member of this Group (where alive=false). You must pass the callback and context in which it will run.
You can add as many parameters as you like, which will all be passed to the callback along with the child.
For example: Group.forEachDead(bringToLife, this)< / p >
< / div >
< h5 > Parameters:< / h5 >
< table class = "params table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
2014-02-05 06:29:17 +00:00
< tr >
2014-03-14 06:36:05 +00:00
< td class = "name" > < code > callback< / code > < / td >
2014-02-05 06:29:17 +00:00
< td class = "type" >
2013-10-02 10:22:20 +00:00
2014-03-14 06:36:05 +00:00
< span class = "param-type" > function< / span >
2014-02-05 06:29:17 +00:00
< / td >
2014-03-14 06:36:05 +00:00
< td class = "description last" > < p > The function that will be called. Each child of the Group will be passed to it as its first parameter.< / p > < / td >
2014-02-05 06:29:17 +00:00
< / tr >
< tr >
2014-03-14 06:36:05 +00:00
< td class = "name" > < code > callbackContext< / code > < / td >
2014-02-05 06:29:17 +00:00
< td class = "type" >
2013-10-02 10:22:20 +00:00
2014-04-11 12:09:28 +00:00
< span class = "param-type" > Object< / span >
2014-02-05 06:29:17 +00:00
< / td >
2013-10-02 10:22:20 +00:00
2014-03-14 06:36:05 +00:00
< td class = "description last" > < p > The context in which the function should be called (usually 'this').< / p > < / td >
2013-10-02 10:22:20 +00:00
< / tr >
< / tbody >
< / table >
2013-10-02 00:16:40 +00:00
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-1304" > line 1304< / a >
2013-10-02 00:16:40 +00:00
< / li > < / ul > < / dd >
< / dl >
< / dd >
< dt >
2014-03-14 06:36:05 +00:00
< h4 class = "name" id = "forEachExists" > < span class = "type-signature" > < / span > forEachExists< span class = "signature" > (callback, callbackContext)< / span > < span class = "type-signature" > < / span > < / h4 >
2013-10-02 00:16:40 +00:00
< / dt >
< dd >
< div class = "description" >
2014-03-14 06:36:05 +00:00
< p > Allows you to call your own function on each member of this Group where child.exists=true. You must pass the callback and context in which it will run.
You can add as many parameters as you like, which will all be passed to the callback along with the child.
For example: Group.forEachExists(causeDamage, this, 500)< / p >
2013-10-02 00:16:40 +00:00
< / div >
< h5 > Parameters:< / h5 >
< table class = "params table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
< td class = "name" > < code > callback< / code > < / td >
< td class = "type" >
2013-10-02 10:22:20 +00:00
< span class = "param-type" > function< / span >
2013-10-02 00:16:40 +00:00
< / td >
2013-10-02 10:22:20 +00:00
< td class = "description last" > < p > The function that will be called. Each child of the Group will be passed to it as its first parameter.< / p > < / td >
2013-10-02 00:16:40 +00:00
< / tr >
< tr >
< td class = "name" > < code > callbackContext< / code > < / td >
< td class = "type" >
2014-04-11 12:09:28 +00:00
< span class = "param-type" > Object< / span >
2013-10-02 00:16:40 +00:00
< / td >
2013-10-02 10:22:20 +00:00
< td class = "description last" > < p > The context in which the function should be called (usually 'this').< / p > < / td >
2013-10-02 00:16:40 +00:00
< / tr >
< / tbody >
< / table >
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-1268" > line 1268< / a >
2013-10-02 00:16:40 +00:00
< / li > < / ul > < / dd >
< / dl >
< / dd >
< dt >
2014-03-14 06:36:05 +00:00
< h4 class = "name" id = "getAt" > < span class = "type-signature" > < / span > getAt< span class = "signature" > (index)< / span > < span class = "type-signature" > → {*}< / span > < / h4 >
2013-10-02 00:16:40 +00:00
< / dt >
< dd >
< div class = "description" >
2014-03-14 06:36:05 +00:00
< p > Returns the child found at the given index within this Group.< / p >
2013-10-02 00:16:40 +00:00
< / div >
< h5 > Parameters:< / h5 >
< table class = "params table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
2014-03-14 06:36:05 +00:00
< td class = "name" > < code > index< / code > < / td >
2013-10-02 00:16:40 +00:00
< td class = "type" >
2014-03-14 06:36:05 +00:00
< span class = "param-type" > number< / span >
2013-10-02 00:16:40 +00:00
< / td >
2014-03-14 06:36:05 +00:00
< td class = "description last" > < p > The index to return the child from.< / p > < / td >
2013-10-02 00:16:40 +00:00
< / tr >
2014-03-14 06:36:05 +00:00
< / tbody >
< / table >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< dl class = "details" >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-303" > line 303< / a >
2014-03-14 06:36:05 +00:00
< / li > < / ul > < / dd >
< / dl >
< h5 > Returns:< / h5 >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< div class = "param-desc" >
< p > The child that was found at the given index. If the index was out of bounds then this will return -1.< / p >
< / div >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< dl >
< dt >
Type
< / dt >
< dd >
< span class = "param-type" > *< / span >
< / dd >
< / dl >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< / dd >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< dt >
< h4 class = "name" id = "getBottom" > < span class = "type-signature" > < / span > getBottom< span class = "signature" > ()< / span > < span class = "type-signature" > → {Any}< / span > < / h4 >
< / dt >
< dd >
< div class = "description" >
< p > Returns the child at the bottom of this Group. The bottom is the one being displayed (rendered) below every other child.< / p >
< / div >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
2013-10-02 00:16:40 +00:00
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-1549" > line 1549< / a >
2013-10-02 00:16:40 +00:00
< / li > < / ul > < / dd >
< / dl >
2014-03-14 06:36:05 +00:00
< h5 > Returns:< / h5 >
< div class = "param-desc" >
< p > The child at the bottom of the Group.< / p >
< / div >
< dl >
< dt >
Type
< / dt >
< dd >
< span class = "param-type" > Any< / span >
< / dd >
< / dl >
2013-10-02 00:16:40 +00:00
< / dd >
< dt >
2014-03-14 06:36:05 +00:00
< h4 class = "name" id = "getFirstAlive" > < span class = "type-signature" > < / span > getFirstAlive< span class = "signature" > ()< / span > < span class = "type-signature" > → {Any}< / span > < / h4 >
2013-10-02 00:16:40 +00:00
< / dt >
< dd >
< div class = "description" >
2014-03-14 06:36:05 +00:00
< p > Call this function to retrieve the first object with alive === true in the group.
This is handy for checking if everything has been wiped out, or choosing a squad leader, etc.< / p >
2013-10-02 00:16:40 +00:00
< / div >
2014-03-14 06:36:05 +00:00
< dl class = "details" >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-1508" > line 1508< / a >
2014-03-14 06:36:05 +00:00
< / li > < / ul > < / dd >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< / dl >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< h5 > Returns:< / h5 >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< div class = "param-desc" >
< p > The first alive child, or null if none found.< / p >
< / div >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< dl >
< dt >
Type
< / dt >
< dd >
< span class = "param-type" > Any< / span >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< / dd >
< / dl >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< / dd >
< dt >
< h4 class = "name" id = "getFirstDead" > < span class = "type-signature" > < / span > getFirstDead< span class = "signature" > ()< / span > < span class = "type-signature" > → {Any}< / span > < / h4 >
< / dt >
< dd >
< div class = "description" >
< p > Call this function to retrieve the first object with alive === false in the group.
This is handy for checking if everything has been wiped out, or choosing a squad leader, etc.< / p >
< / div >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
2013-10-02 00:16:40 +00:00
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-1521" > line 1521< / a >
2013-10-02 00:16:40 +00:00
< / li > < / ul > < / dd >
< / dl >
2014-03-14 06:36:05 +00:00
< h5 > Returns:< / h5 >
< div class = "param-desc" >
< p > The first dead child, or null if none found.< / p >
< / div >
< dl >
< dt >
Type
< / dt >
< dd >
< span class = "param-type" > Any< / span >
< / dd >
< / dl >
2013-10-02 00:16:40 +00:00
< / dd >
< dt >
2014-03-14 06:36:05 +00:00
< h4 class = "name" id = "getFirstExists" > < span class = "type-signature" > < / span > getFirstExists< span class = "signature" > (state)< / span > < span class = "type-signature" > → {Any}< / span > < / h4 >
2013-10-02 00:16:40 +00:00
< / dt >
< dd >
< div class = "description" >
2014-03-14 06:36:05 +00:00
< p > Call this function to retrieve the first object with exists == (the given state) in the Group.< / p >
2013-10-02 00:16:40 +00:00
< / div >
< h5 > Parameters:< / h5 >
< table class = "params table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
2014-03-14 06:36:05 +00:00
< td class = "name" > < code > state< / code > < / td >
2013-11-07 06:10:15 +00:00
< td class = "type" >
2014-03-14 06:36:05 +00:00
< span class = "param-type" > boolean< / span >
2013-11-07 06:10:15 +00:00
< / td >
2014-03-14 06:36:05 +00:00
< td class = "description last" > < p > True or false.< / p > < / td >
2013-10-02 00:16:40 +00:00
< / tr >
< / tbody >
< / table >
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-1490" > line 1490< / a >
2013-10-02 00:16:40 +00:00
< / li > < / ul > < / dd >
< / dl >
2014-03-14 06:36:05 +00:00
< h5 > Returns:< / h5 >
< div class = "param-desc" >
< p > The first child, or null if none found.< / p >
< / div >
< dl >
< dt >
Type
< / dt >
< dd >
< span class = "param-type" > Any< / span >
< / dd >
< / dl >
2013-10-02 00:16:40 +00:00
2013-11-07 06:10:15 +00:00
< / dd >
2013-10-02 00:16:40 +00:00
2013-11-07 06:10:15 +00:00
< dt >
2014-03-14 06:36:05 +00:00
< h4 class = "name" id = "getIndex" > < span class = "type-signature" > < / span > getIndex< span class = "signature" > (child)< / span > < span class = "type-signature" > → {number}< / span > < / h4 >
2013-11-07 06:10:15 +00:00
< / dt >
< dd >
< div class = "description" >
2014-03-14 06:36:05 +00:00
< p > Get the index position of the given child in this Group. This should always match the childs z property.< / p >
2013-11-07 06:10:15 +00:00
< / div >
< h5 > Parameters:< / h5 >
< table class = "params table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
2014-03-14 06:36:05 +00:00
< td class = "name" > < code > child< / code > < / td >
2013-11-07 06:10:15 +00:00
< td class = "type" >
2014-03-14 06:36:05 +00:00
< span class = "param-type" > *< / span >
2013-11-07 06:10:15 +00:00
< / td >
2014-03-14 06:36:05 +00:00
< td class = "description last" > < p > The child to get the index for.< / p > < / td >
2013-11-07 06:10:15 +00:00
< / tr >
< / tbody >
< / table >
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-622" > line 622< / a >
2013-11-07 06:10:15 +00:00
< / li > < / ul > < / dd >
< / dl >
< h5 > Returns:< / h5 >
< div class = "param-desc" >
2014-03-14 06:36:05 +00:00
< p > The index of the child or -1 if it's not a member of this Group.< / p >
2013-10-02 00:16:40 +00:00
< / div >
< dl >
< dt >
Type
< / dt >
< dd >
2014-03-14 06:36:05 +00:00
< span class = "param-type" > number< / span >
2013-10-02 00:16:40 +00:00
< / dd >
< / dl >
< / dd >
< dt >
2014-03-14 06:36:05 +00:00
< h4 class = "name" id = "getRandom" > < span class = "type-signature" > < / span > getRandom< span class = "signature" > (startIndex, length)< / span > < span class = "type-signature" > → {Any}< / span > < / h4 >
2013-10-02 00:16:40 +00:00
< / dt >
< dd >
< div class = "description" >
2014-03-14 06:36:05 +00:00
< p > Returns a member at random from the group.< / p >
2013-10-02 00:16:40 +00:00
< / div >
2014-03-14 06:36:05 +00:00
< h5 > Parameters:< / h5 >
< table class = "params table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
< td class = "name" > < code > startIndex< / code > < / td >
< td class = "type" >
< span class = "param-type" > number< / span >
< / td >
< td class = "description last" > < p > Optional offset off the front of the array. Default value is 0, or the beginning of the array.< / p > < / td >
< / tr >
< tr >
< td class = "name" > < code > length< / code > < / td >
< td class = "type" >
< span class = "param-type" > number< / span >
< / td >
< td class = "description last" > < p > Optional restriction on the number of values you want to randomly select from.< / p > < / td >
< / tr >
< / tbody >
< / table >
2013-10-02 00:16:40 +00:00
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-1588" > line 1588< / a >
2013-10-02 00:16:40 +00:00
< / li > < / ul > < / dd >
< / dl >
< h5 > Returns:< / h5 >
< div class = "param-desc" >
2014-03-14 06:36:05 +00:00
< p > A random child of this Group.< / p >
2013-10-02 00:16:40 +00:00
< / div >
< dl >
< dt >
Type
< / dt >
< dd >
< span class = "param-type" > Any< / span >
< / dd >
< / dl >
< / dd >
< dt >
2014-03-14 06:36:05 +00:00
< h4 class = "name" id = "getTop" > < span class = "type-signature" > < / span > getTop< span class = "signature" > ()< / span > < span class = "type-signature" > → {Any}< / span > < / h4 >
2013-10-02 00:16:40 +00:00
< / dt >
< dd >
< div class = "description" >
2014-03-14 06:36:05 +00:00
< p > Returns the child at the top of this Group. The top is the one being displayed (rendered) above every other child.< / p >
2013-10-02 00:16:40 +00:00
< / div >
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-1534" > line 1534< / a >
2013-10-02 00:16:40 +00:00
< / li > < / ul > < / dd >
< / dl >
< h5 > Returns:< / h5 >
< div class = "param-desc" >
2014-03-14 06:36:05 +00:00
< p > The child at the top of the Group.< / p >
2013-10-02 00:16:40 +00:00
< / div >
< dl >
< dt >
Type
< / dt >
< dd >
< span class = "param-type" > Any< / span >
< / dd >
< / dl >
2014-05-20 09:12:48 +00:00
< / dd >
< dt >
< h4 class = "name" id = "hasProperty" > < span class = "type-signature" > < / span > hasProperty< span class = "signature" > (child, key)< / span > < span class = "type-signature" > → {boolean}< / span > < / h4 >
< / dt >
< dd >
< div class = "description" >
< p > Checks if the child has the given property. Will scan up to 4 levels deep only.< / p >
< / div >
< h5 > Parameters:< / h5 >
< table class = "params table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
< td class = "name" > < code > child< / code > < / td >
< td class = "type" >
< span class = "param-type" > *< / span >
< / td >
< td class = "description last" > < p > The child to check for the existance of the property on.< / p > < / td >
< / tr >
< tr >
< td class = "name" > < code > key< / code > < / td >
< td class = "type" >
< span class = "param-type" > array< / span >
< / td >
< td class = "description last" > < p > An array of strings that make up the property.< / p > < / td >
< / tr >
< / tbody >
< / table >
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-671" > line 671< / a >
2014-05-20 09:12:48 +00:00
< / li > < / ul > < / dd >
< / dl >
< h5 > Returns:< / h5 >
< div class = "param-desc" >
< p > True if the child has the property, otherwise false.< / p >
< / div >
< dl >
< dt >
Type
< / dt >
< dd >
< span class = "param-type" > boolean< / span >
< / dd >
< / dl >
2013-10-02 00:16:40 +00:00
< / dd >
< dt >
2014-03-14 06:36:05 +00:00
< h4 class = "name" id = "iterate" > < span class = "type-signature" > < / span > iterate< span class = "signature" > (key, value, returnType, < span class = "optional" > callback< / span > , < span class = "optional" > callbackContext< / span > )< / span > < span class = "type-signature" > → {any}< / span > < / h4 >
2013-10-02 00:16:40 +00:00
< / dt >
< dd >
< div class = "description" >
2014-03-14 06:36:05 +00:00
< p > Iterates over the children of the Group. When a child has a property matching key that equals the given value, it is considered as a match.
Matched children can be sent to the optional callback, or simply returned or counted.
You can add as many callback parameters as you like, which will all be passed to the callback along with the child, after the callbackContext parameter.< / p >
2013-10-02 00:16:40 +00:00
< / div >
< h5 > Parameters:< / h5 >
< table class = "params table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
2014-03-14 06:36:05 +00:00
< th > Argument< / th >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< th > Default< / th >
2013-10-02 00:16:40 +00:00
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
2014-03-14 06:36:05 +00:00
< td class = "name" > < code > key< / code > < / td >
2013-10-02 00:16:40 +00:00
< td class = "type" >
2014-03-14 06:36:05 +00:00
< span class = "param-type" > string< / span >
2013-10-02 00:16:40 +00:00
< / td >
2014-03-14 06:36:05 +00:00
< td class = "attributes" >
< / td >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< td class = "default" >
< / td >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< td class = "description last" > < p > The child property to check, i.e. 'exists', 'alive', 'health'< / p > < / td >
2013-10-02 00:16:40 +00:00
< / tr >
2014-03-14 06:36:05 +00:00
< tr >
< td class = "name" > < code > value< / code > < / td >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< td class = "type" >
< span class = "param-type" > any< / span >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< / td >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< td class = "attributes" >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< / td >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< td class = "default" >
< / td >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< td class = "description last" > < p > If child.key === this value it will be considered a match. Note that a strict comparison is used.< / p > < / td >
< / tr >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< tr >
< td class = "name" > < code > returnType< / code > < / td >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< td class = "type" >
< span class = "param-type" > number< / span >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< / td >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< td class = "attributes" >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< / td >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< td class = "default" >
< / td >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< td class = "description last" > < p > How to return the data from this method. Either Phaser.Group.RETURN_NONE, Phaser.Group.RETURN_TOTAL or Phaser.Group.RETURN_CHILD.< / p > < / td >
< / tr >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< tr >
< td class = "name" > < code > callback< / code > < / td >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< td class = "type" >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< span class = "param-type" > function< / span >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< / td >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< td class = "attributes" >
< optional>< br >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< / td >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< td class = "default" >
null
< / td >
< td class = "description last" > < p > Optional function that will be called on each matching child. Each child of the Group will be passed to it as its first parameter.< / p > < / td >
< / tr >
2013-10-02 00:16:40 +00:00
< tr >
2014-03-14 06:36:05 +00:00
< td class = "name" > < code > callbackContext< / code > < / td >
2013-10-02 00:16:40 +00:00
< td class = "type" >
2014-04-11 12:09:28 +00:00
< span class = "param-type" > Object< / span >
2013-10-02 00:16:40 +00:00
< / td >
2014-03-14 06:36:05 +00:00
< td class = "attributes" >
< optional>< br >
< / td >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< td class = "default" >
< / td >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< td class = "description last" > < p > The context in which the function should be called (usually 'this').< / p > < / td >
2013-10-02 00:16:40 +00:00
< / tr >
< / tbody >
< / table >
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-1433" > line 1433< / a >
2013-10-02 00:16:40 +00:00
< / li > < / ul > < / dd >
< / dl >
< h5 > Returns:< / h5 >
< div class = "param-desc" >
2014-03-14 06:36:05 +00:00
< p > Returns either a numeric total (if RETURN_TOTAL was specified) or the child object.< / p >
2013-10-02 00:16:40 +00:00
< / div >
< dl >
< dt >
Type
< / dt >
< dd >
2014-03-14 06:36:05 +00:00
< span class = "param-type" > any< / span >
2013-10-02 00:16:40 +00:00
< / dd >
< / dl >
< / dd >
< dt >
2014-03-14 06:36:05 +00:00
< h4 class = "name" id = "moveDown" > < span class = "type-signature" > < / span > moveDown< span class = "signature" > (child)< / span > < span class = "type-signature" > → {*}< / span > < / h4 >
2013-10-02 00:16:40 +00:00
< / dt >
< dd >
< div class = "description" >
2014-03-14 06:36:05 +00:00
< p > Moves the given child down one place in this Group unless it's already at the top.< / p >
2013-10-02 00:16:40 +00:00
< / div >
< h5 > Parameters:< / h5 >
< table class = "params table table-striped" >
< thead >
< tr >
< th > Name< / th >
2013-11-07 06:10:15 +00:00
< th > Type< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
2014-03-14 06:36:05 +00:00
< td class = "name" > < code > child< / code > < / td >
2013-11-07 06:10:15 +00:00
< td class = "type" >
2014-03-14 06:36:05 +00:00
< span class = "param-type" > *< / span >
2013-11-07 06:10:15 +00:00
< / td >
2014-03-14 06:36:05 +00:00
< td class = "description last" > < p > The child to move down in the Group.< / p > < / td >
2013-11-07 06:10:15 +00:00
< / tr >
< / tbody >
< / table >
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-564" > line 564< / a >
2013-11-07 06:10:15 +00:00
< / li > < / ul > < / dd >
< / dl >
< h5 > Returns:< / h5 >
< div class = "param-desc" >
2014-03-14 06:36:05 +00:00
< p > The child that was moved.< / p >
2013-11-07 06:10:15 +00:00
< / div >
< dl >
< dt >
Type
< / dt >
< dd >
2014-03-14 06:36:05 +00:00
< span class = "param-type" > *< / span >
2013-11-07 06:10:15 +00:00
< / dd >
< / dl >
2014-03-14 06:36:05 +00:00
< / dd >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< dt >
< h4 class = "name" id = "moveUp" > < span class = "type-signature" > < / span > moveUp< span class = "signature" > (child)< / span > < span class = "type-signature" > → {*}< / span > < / h4 >
< / dt >
< dd >
< div class = "description" >
< p > Moves the given child up one place in this Group unless it's already at the top.< / p >
< / div >
2013-11-07 06:10:15 +00:00
2014-03-14 06:36:05 +00:00
< h5 > Parameters:< / h5 >
2013-11-07 06:10:15 +00:00
2014-03-14 06:36:05 +00:00
< table class = "params table table-striped" >
< thead >
< tr >
< th > Name< / th >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< th > Type< / th >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< th class = "last" > Description< / th >
< / tr >
< / thead >
2013-10-02 00:16:40 +00:00
2014-03-14 06:36:05 +00:00
< tbody >
2013-10-02 00:16:40 +00:00
< tr >
2014-03-14 06:36:05 +00:00
< td class = "name" > < code > child< / code > < / td >
2013-10-02 00:16:40 +00:00
< td class = "type" >
2014-03-14 06:36:05 +00:00
< span class = "param-type" > *< / span >
2013-10-02 00:16:40 +00:00
< / td >
2014-03-14 06:36:05 +00:00
< td class = "description last" > < p > The child to move up in the Group.< / p > < / td >
2013-10-02 00:16:40 +00:00
< / tr >
< / tbody >
< / table >
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-540" > line 540< / a >
2013-10-02 00:16:40 +00:00
< / li > < / ul > < / dd >
< / dl >
2014-02-05 06:29:17 +00:00
< h5 > Returns:< / h5 >
< div class = "param-desc" >
2014-03-14 06:36:05 +00:00
< p > The child that was moved.< / p >
2014-02-05 06:29:17 +00:00
< / div >
< dl >
< dt >
Type
< / dt >
< dd >
2014-03-14 06:36:05 +00:00
< span class = "param-type" > *< / span >
2014-02-05 06:29:17 +00:00
< / dd >
< / dl >
2013-10-02 00:16:40 +00:00
< / dd >
< dt >
< h4 class = "name" id = "multiplyAll" > < span class = "type-signature" > < / span > multiplyAll< span class = "signature" > (property, amount, checkAlive, checkVisible)< / span > < span class = "type-signature" > < / span > < / h4 >
< / dt >
< dd >
< div class = "description" >
< p > Multiplies the given property by the amount on all children in this Group.
Group.multiplyAll('x', 2) will x2 the child.x value.< / p >
< / div >
< h5 > Parameters:< / h5 >
< table class = "params table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
< td class = "name" > < code > property< / code > < / td >
< td class = "type" >
< span class = "param-type" > string< / span >
< / td >
< td class = "description last" > < p > The property to multiply, for example 'body.velocity.x' or 'angle'.< / p > < / td >
< / tr >
< tr >
< td class = "name" > < code > amount< / code > < / td >
< td class = "type" >
< span class = "param-type" > number< / span >
< / td >
< td class = "description last" > < p > The amount to multiply the property by. If child.x = 10 then multiplyAll('x', 2) would make child.x = 20.< / p > < / td >
< / tr >
< tr >
< td class = "name" > < code > checkAlive< / code > < / td >
< td class = "type" >
< span class = "param-type" > boolean< / span >
< / td >
< td class = "description last" > < p > If true the property will only be changed if the child is alive.< / p > < / td >
< / tr >
< tr >
< td class = "name" > < code > checkVisible< / code > < / td >
< td class = "type" >
< span class = "param-type" > boolean< / span >
< / td >
< td class = "description last" > < p > If true the property will only be changed if the child is visible.< / p > < / td >
< / tr >
< / tbody >
< / table >
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-978" > line 978< / a >
2013-11-01 18:16:52 +00:00
< / li > < / ul > < / dd >
< / dl >
< / dd >
< dt >
2014-04-10 22:13:43 +00:00
< h4 class = "name" id = "next" > < span class = "type-signature" > < / span > next< span class = "signature" > ()< / span > < span class = "type-signature" > → {*}< / span > < / h4 >
2013-11-01 18:16:52 +00:00
< / dt >
< dd >
< div class = "description" >
< p > Advances the Group cursor to the next object in the Group. If it's at the end of the Group it wraps around to the first object.< / p >
< / div >
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-433" > line 433< / a >
2014-02-18 03:01:51 +00:00
< / li > < / ul > < / dd >
< / dl >
2014-04-10 22:13:43 +00:00
< h5 > Returns:< / h5 >
< div class = "param-desc" >
< p > The child the cursor now points to.< / p >
< / div >
< dl >
< dt >
Type
< / dt >
< dd >
< span class = "param-type" > *< / span >
< / dd >
< / dl >
2014-02-18 03:01:51 +00:00
< / dd >
< dt >
< h4 class = "name" id = "postUpdate" > < span class = "type-signature" > < protected> < / span > postUpdate< span class = "signature" > ()< / span > < span class = "type-signature" > < / span > < / h4 >
< / dt >
< dd >
< div class = "description" >
< p > The core postUpdate - as called by World.< / p >
< / div >
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-1186" > line 1186< / a >
2014-02-18 03:01:51 +00:00
< / li > < / ul > < / dd >
< / dl >
< / dd >
< dt >
< h4 class = "name" id = "preUpdate" > < span class = "type-signature" > < protected> < / span > preUpdate< span class = "signature" > ()< / span > < span class = "type-signature" > < / span > < / h4 >
< / dt >
< dd >
< div class = "description" >
< p > The core preUpdate - as called by World.< / p >
< / div >
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-1146" > line 1146< / a >
2013-11-01 18:16:52 +00:00
< / li > < / ul > < / dd >
< / dl >
< / dd >
< dt >
2014-04-10 22:13:43 +00:00
< h4 class = "name" id = "previous" > < span class = "type-signature" > < / span > previous< span class = "signature" > ()< / span > < span class = "type-signature" > → {*}< / span > < / h4 >
2013-11-01 18:16:52 +00:00
< / dt >
< dd >
< div class = "description" >
< p > Moves the Group cursor to the previous object in the Group. If it's at the start of the Group it wraps around to the last object.< / p >
< / div >
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-460" > line 460< / a >
2013-10-02 00:16:40 +00:00
< / li > < / ul > < / dd >
< / dl >
2014-04-10 22:13:43 +00:00
< h5 > Returns:< / h5 >
< div class = "param-desc" >
< p > The child the cursor now points to.< / p >
< / div >
< dl >
< dt >
Type
< / dt >
< dd >
< span class = "param-type" > *< / span >
< / dd >
< / dl >
2013-10-02 00:16:40 +00:00
< / dd >
< dt >
2014-07-10 19:31:11 +00:00
< h4 class = "name" id = "remove" > < span class = "type-signature" > < / span > remove< span class = "signature" > (child, < span class = "optional" > destroy< / span > , < span class = "optional" > silent< / span > )< / span > < span class = "type-signature" > → {boolean}< / span > < / h4 >
2013-10-02 00:16:40 +00:00
< / dt >
< dd >
< div class = "description" >
2014-04-29 14:39:02 +00:00
< p > Removes the given child from this Group. This will dispatch an onRemovedFromGroup event from the child (if it has one),
reset the Group cursor and optionally destroy the child.< / p >
2013-10-02 00:16:40 +00:00
< / div >
< h5 > Parameters:< / h5 >
< table class = "params table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
2014-04-11 12:09:28 +00:00
< th > Argument< / th >
2013-10-02 00:16:40 +00:00
2014-04-11 12:09:28 +00:00
< th > Default< / th >
2013-10-02 00:16:40 +00:00
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
< td class = "name" > < code > child< / code > < / td >
< td class = "type" >
2013-10-02 10:22:20 +00:00
< span class = "param-type" > Any< / span >
2013-10-02 00:16:40 +00:00
< / td >
2014-04-11 12:09:28 +00:00
< td class = "attributes" >
2013-10-02 00:16:40 +00:00
2014-04-11 12:09:28 +00:00
< / td >
< td class = "default" >
< / td >
2013-10-02 00:16:40 +00:00
2013-10-02 10:22:20 +00:00
< td class = "description last" > < p > The child to remove.< / p > < / td >
2013-10-02 00:16:40 +00:00
< / tr >
2014-04-11 12:09:28 +00:00
< tr >
< td class = "name" > < code > destroy< / code > < / td >
< td class = "type" >
< span class = "param-type" > boolean< / span >
< / td >
< td class = "attributes" >
< optional>< br >
< / td >
< td class = "default" >
false
< / td >
< td class = "description last" > < p > You can optionally call destroy on the child that was removed.< / p > < / td >
< / tr >
2014-07-10 19:31:11 +00:00
< tr >
< td class = "name" > < code > silent< / code > < / td >
< td class = "type" >
< span class = "param-type" > boolean< / span >
< / td >
< td class = "attributes" >
< optional>< br >
< / td >
< td class = "default" >
false
< / td >
< td class = "description last" > < p > If the silent parameter is < code > true< / code > the child will not dispatch the onRemovedFromGroup event.< / p > < / td >
< / tr >
2013-10-02 00:16:40 +00:00
< / tbody >
< / table >
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-1610" > line 1610< / a >
2013-10-02 00:16:40 +00:00
< / li > < / ul > < / dd >
< / dl >
2013-11-28 15:57:09 +00:00
< h5 > Returns:< / h5 >
< div class = "param-desc" >
< p > true if the child was removed from this Group, otherwise false.< / p >
< / div >
< dl >
< dt >
Type
< / dt >
< dd >
< span class = "param-type" > boolean< / span >
< / dd >
< / dl >
2013-10-02 00:16:40 +00:00
< / dd >
< dt >
2014-07-10 19:31:11 +00:00
< h4 class = "name" id = "removeAll" > < span class = "type-signature" > < / span > removeAll< span class = "signature" > (< span class = "optional" > destroy< / span > , < span class = "optional" > silent< / span > )< / span > < span class = "type-signature" > < / span > < / h4 >
2013-10-02 00:16:40 +00:00
< / dt >
< dd >
< div class = "description" >
2014-07-10 19:31:11 +00:00
< p > Removes all children from this Group, setting the group properties of the children to < code > null< / code > .
2013-10-02 10:22:20 +00:00
The Group container remains on the display list.< / p >
2013-10-02 00:16:40 +00:00
< / div >
2014-04-11 12:09:28 +00:00
< h5 > Parameters:< / h5 >
< table class = "params table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th > Argument< / th >
< th > Default< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
< td class = "name" > < code > destroy< / code > < / td >
< td class = "type" >
< span class = "param-type" > boolean< / span >
< / td >
< td class = "attributes" >
< optional>< br >
< / td >
< td class = "default" >
false
< / td >
2014-07-10 19:31:11 +00:00
< td class = "description last" > < p > You can optionally call destroy on each child that is removed.< / p > < / td >
< / tr >
< tr >
< td class = "name" > < code > silent< / code > < / td >
< td class = "type" >
< span class = "param-type" > boolean< / span >
< / td >
< td class = "attributes" >
< optional>< br >
< / td >
< td class = "default" >
false
< / td >
< td class = "description last" > < p > If the silent parameter is < code > true< / code > the children will not dispatch their onRemovedFromGroup events.< / p > < / td >
2014-04-11 12:09:28 +00:00
< / tr >
< / tbody >
< / table >
2013-10-02 00:16:40 +00:00
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-1653" > line 1653< / a >
2013-10-02 00:16:40 +00:00
< / li > < / ul > < / dd >
< / dl >
< / dd >
< dt >
2014-07-10 19:31:11 +00:00
< h4 class = "name" id = "removeBetween" > < span class = "type-signature" > < / span > removeBetween< span class = "signature" > (startIndex, < span class = "optional" > endIndex< / span > , < span class = "optional" > destroy< / span > , < span class = "optional" > silent< / span > )< / span > < span class = "type-signature" > < / span > < / h4 >
2013-10-02 00:16:40 +00:00
< / dt >
< dd >
< div class = "description" >
2013-10-02 10:22:20 +00:00
< p > Removes all children from this Group whos index falls beteen the given startIndex and endIndex values.< / p >
2013-10-02 00:16:40 +00:00
< / div >
< h5 > Parameters:< / h5 >
< table class = "params table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
2014-04-10 22:13:43 +00:00
< th > Argument< / th >
2013-10-02 00:16:40 +00:00
2014-04-11 12:09:28 +00:00
< th > Default< / th >
2013-10-02 00:16:40 +00:00
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
< td class = "name" > < code > startIndex< / code > < / td >
< td class = "type" >
2013-10-02 10:22:20 +00:00
< span class = "param-type" > number< / span >
2013-10-02 00:16:40 +00:00
< / td >
2014-04-10 22:13:43 +00:00
< td class = "attributes" >
< / td >
2013-10-02 00:16:40 +00:00
2014-04-11 12:09:28 +00:00
< td class = "default" >
< / td >
2013-10-02 00:16:40 +00:00
2013-10-02 10:22:20 +00:00
< td class = "description last" > < p > The index to start removing children from.< / p > < / td >
2013-10-02 00:16:40 +00:00
< / tr >
< tr >
< td class = "name" > < code > endIndex< / code > < / td >
< td class = "type" >
2013-10-02 10:22:20 +00:00
< span class = "param-type" > number< / span >
2013-10-02 00:16:40 +00:00
< / td >
2014-04-10 22:13:43 +00:00
< td class = "attributes" >
< optional>< br >
< / td >
2013-10-02 00:16:40 +00:00
2014-04-11 12:09:28 +00:00
< td class = "default" >
< / td >
2013-10-02 00:16:40 +00:00
2014-04-10 22:13:43 +00:00
< td class = "description last" > < p > The index to stop removing children at. Must be higher than startIndex. If undefined this method will remove all children between startIndex and the end of the Group.< / p > < / td >
2013-10-02 00:16:40 +00:00
< / tr >
2014-04-11 12:09:28 +00:00
< tr >
< td class = "name" > < code > destroy< / code > < / td >
< td class = "type" >
< span class = "param-type" > boolean< / span >
< / td >
< td class = "attributes" >
< optional>< br >
< / td >
< td class = "default" >
false
< / td >
< td class = "description last" > < p > You can optionally call destroy on the child that was removed.< / p > < / td >
< / tr >
2014-07-10 19:31:11 +00:00
< tr >
< td class = "name" > < code > silent< / code > < / td >
< td class = "type" >
< span class = "param-type" > boolean< / span >
< / td >
< td class = "attributes" >
< optional>< br >
< / td >
< td class = "default" >
false
< / td >
< td class = "description last" > < p > If the silent parameter is < code > true< / code > the children will not dispatch their onRemovedFromGroup events.< / p > < / td >
< / tr >
2013-10-02 00:16:40 +00:00
< / tbody >
< / table >
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-1691" > line 1691< / a >
2014-02-05 06:29:17 +00:00
< / li > < / ul > < / dd >
< / dl >
< / dd >
< dt >
2014-03-24 12:41:45 +00:00
< h4 class = "name" id = "replace" > < span class = "type-signature" > < / span > replace< span class = "signature" > (oldChild, newChild)< / span > < span class = "type-signature" > → {*}< / span > < / h4 >
2014-02-05 06:29:17 +00:00
< / dt >
< dd >
< div class = "description" >
< p > Replaces a child of this Group with the given newChild. The newChild cannot be a member of this Group.< / p >
< / div >
< h5 > Parameters:< / h5 >
< table class = "params table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
< td class = "name" > < code > oldChild< / code > < / td >
< td class = "type" >
< span class = "param-type" > *< / span >
< / td >
2014-03-14 06:36:05 +00:00
< td class = "description last" > < p > The child in this Group that will be replaced.< / p > < / td >
< / tr >
< tr >
< td class = "name" > < code > newChild< / code > < / td >
< td class = "type" >
< span class = "param-type" > *< / span >
< / td >
< td class = "description last" > < p > The child to be inserted into this Group.< / p > < / td >
< / tr >
< / tbody >
< / table >
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-635" > line 635< / a >
2014-03-14 06:36:05 +00:00
< / li > < / ul > < / dd >
< / dl >
2014-03-24 12:41:45 +00:00
< h5 > Returns:< / h5 >
< div class = "param-desc" >
< p > Returns the oldChild that was replaced within this Group.< / p >
< / div >
< dl >
< dt >
Type
< / dt >
< dd >
< span class = "param-type" > *< / span >
< / dd >
< / dl >
2014-03-14 06:36:05 +00:00
2014-04-29 14:39:02 +00:00
< / dd >
< dt >
< h4 class = "name" id = "resetCursor" > < span class = "type-signature" > < / span > resetCursor< span class = "signature" > (< span class = "optional" > index< / span > )< / span > < span class = "type-signature" > → {*}< / span > < / h4 >
< / dt >
< dd >
< div class = "description" >
< p > Sets the Group cursor to the first object in the Group. If the optional index parameter is given it sets the cursor to the object at that index instead.< / p >
< / div >
< h5 > Parameters:< / h5 >
< table class = "params table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th > Argument< / th >
< th > Default< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
< td class = "name" > < code > index< / code > < / td >
< td class = "type" >
< span class = "param-type" > number< / span >
< / td >
< td class = "attributes" >
< optional>< br >
< / td >
< td class = "default" >
0
< / td >
< td class = "description last" > < p > Set the cursor to point to a specific index.< / p > < / td >
< / tr >
< / tbody >
< / table >
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-408" > line 408< / a >
2014-04-29 14:39:02 +00:00
< / li > < / ul > < / dd >
< / dl >
< h5 > Returns:< / h5 >
< div class = "param-desc" >
< p > The child the cursor now points to.< / p >
< / div >
< dl >
< dt >
Type
< / dt >
< dd >
< span class = "param-type" > *< / span >
< / dd >
< / dl >
2014-03-14 06:36:05 +00:00
< / dd >
< dt >
< h4 class = "name" id = "reverse" > < span class = "type-signature" > < / span > reverse< span class = "signature" > ()< / span > < span class = "type-signature" > < / span > < / h4 >
< / dt >
< dd >
< div class = "description" >
< p > Reverses all children in this Group. Note that this does not propagate, only direct children are re-ordered.< / p >
< / div >
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-610" > line 610< / a >
2014-03-14 06:36:05 +00:00
< / li > < / ul > < / dd >
< / dl >
< / dd >
< dt >
< h4 class = "name" id = "sendToBack" > < span class = "type-signature" > < / span > sendToBack< span class = "signature" > (child)< / span > < span class = "type-signature" > → {*}< / span > < / h4 >
< / dt >
< dd >
< div class = "description" >
< p > Sends the given child to the bottom of this Group so it renders below all other children.< / p >
< / div >
< h5 > Parameters:< / h5 >
< table class = "params table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
2014-02-05 06:29:17 +00:00
2014-03-14 06:36:05 +00:00
< tbody >
2014-02-05 06:29:17 +00:00
< tr >
2014-03-14 06:36:05 +00:00
< td class = "name" > < code > child< / code > < / td >
2014-02-05 06:29:17 +00:00
< td class = "type" >
< span class = "param-type" > *< / span >
< / td >
2014-03-14 06:36:05 +00:00
< td class = "description last" > < p > The child to send to the bottom of this Group.< / p > < / td >
2014-02-05 06:29:17 +00:00
< / tr >
< / tbody >
< / table >
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-521" > line 521< / a >
2013-10-02 00:16:40 +00:00
< / li > < / ul > < / dd >
< / dl >
2014-03-14 06:36:05 +00:00
< h5 > Returns:< / h5 >
< div class = "param-desc" >
< p > The child that was moved.< / p >
< / div >
< dl >
< dt >
Type
< / dt >
< dd >
< span class = "param-type" > *< / span >
< / dd >
< / dl >
2013-10-02 00:16:40 +00:00
< / dd >
< dt >
2014-05-20 09:12:48 +00:00
< h4 class = "name" id = "set" > < span class = "type-signature" > < / span > set< span class = "signature" > (child, key, value, < span class = "optional" > checkAlive< / span > , < span class = "optional" > checkVisible< / span > , < span class = "optional" > operation< / span > , < span class = "optional" > force< / span > )< / span > < span class = "type-signature" > → {boolean}< / span > < / h4 >
2013-10-02 00:16:40 +00:00
< / dt >
< dd >
< div class = "description" >
2014-02-05 06:29:17 +00:00
< p > This function allows you to quickly set a property on a single child of this Group to a new value.
The operation parameter controls how the new value is assigned to the property, from simple replacement to addition and multiplication.< / p >
2013-10-02 00:16:40 +00:00
< / div >
< h5 > Parameters:< / h5 >
< table class = "params table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
2014-02-05 06:29:17 +00:00
< th > Argument< / th >
2013-10-02 00:16:40 +00:00
2014-02-05 06:29:17 +00:00
< th > Default< / th >
2013-10-02 00:16:40 +00:00
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
2014-02-05 06:29:17 +00:00
< td class = "name" > < code > child< / code > < / td >
2013-10-02 00:16:40 +00:00
< td class = "type" >
2014-02-05 06:29:17 +00:00
< span class = "param-type" > < a href = "Phaser.Sprite.html" > Phaser.Sprite< / a > < / span >
2013-10-02 00:16:40 +00:00
< / td >
2014-02-05 06:29:17 +00:00
< td class = "attributes" >
< / td >
2013-10-02 00:16:40 +00:00
2014-02-05 06:29:17 +00:00
< td class = "default" >
< / td >
2013-10-02 00:16:40 +00:00
2014-02-05 06:29:17 +00:00
< td class = "description last" > < p > The child to set the property on.< / p > < / td >
2013-10-02 00:16:40 +00:00
< / tr >
< tr >
2014-02-05 06:29:17 +00:00
< td class = "name" > < code > key< / code > < / td >
< td class = "type" >
< span class = "param-type" > string< / span >
< / td >
< td class = "attributes" >
< / td >
< td class = "default" >
< / td >
< td class = "description last" > < p > The property, as a string, to be set. For example: 'body.velocity.x'< / p > < / td >
< / tr >
< tr >
< td class = "name" > < code > value< / code > < / td >
2013-10-02 00:16:40 +00:00
< td class = "type" >
2013-10-02 10:22:20 +00:00
< span class = "param-type" > *< / span >
2013-10-02 00:16:40 +00:00
< / td >
2014-02-05 06:29:17 +00:00
< td class = "attributes" >
< / td >
< td class = "default" >
< / td >
< td class = "description last" > < p > The value that will be set.< / p > < / td >
< / tr >
< tr >
< td class = "name" > < code > checkAlive< / code > < / td >
< td class = "type" >
< span class = "param-type" > boolean< / span >
< / td >
< td class = "attributes" >
< optional>< br >
2013-10-02 00:16:40 +00:00
2014-02-05 06:29:17 +00:00
< / td >
2013-10-02 00:16:40 +00:00
2014-02-05 06:29:17 +00:00
< td class = "default" >
false
< / td >
< td class = "description last" > < p > If set then the child will only be updated if alive=true.< / p > < / td >
< / tr >
< tr >
< td class = "name" > < code > checkVisible< / code > < / td >
< td class = "type" >
< span class = "param-type" > boolean< / span >
< / td >
< td class = "attributes" >
< optional>< br >
< / td >
< td class = "default" >
false
< / td >
< td class = "description last" > < p > If set then the child will only be updated if visible=true.< / p > < / td >
< / tr >
< tr >
< td class = "name" > < code > operation< / code > < / td >
< td class = "type" >
< span class = "param-type" > number< / span >
< / td >
< td class = "attributes" >
< optional>< br >
< / td >
< td class = "default" >
0
< / td >
< td class = "description last" > < p > Controls how the value is assigned. A value of 0 replaces the value with the new one. A value of 1 adds it, 2 subtracts it, 3 multiplies it and 4 divides it.< / p > < / td >
2013-10-02 00:16:40 +00:00
< / tr >
2014-05-20 09:12:48 +00:00
< tr >
< td class = "name" > < code > force< / code > < / td >
< td class = "type" >
< span class = "param-type" > boolean< / span >
< / td >
< td class = "attributes" >
< optional>< br >
< / td >
< td class = "default" >
false
< / td >
< td class = "description last" > < p > If < code > force< / code > is true then the property will be set on the child regardless if it already exists or not. If false and the property doesn't exist, nothing will be set.< / p > < / td >
< / tr >
2013-10-02 00:16:40 +00:00
< / tbody >
< / table >
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-809" > line 809< / a >
2013-10-02 00:16:40 +00:00
< / li > < / ul > < / dd >
< / dl >
2014-05-20 09:12:48 +00:00
< h5 > Returns:< / h5 >
< div class = "param-desc" >
< p > True if the property was set, false if not.< / p >
< / div >
< dl >
< dt >
Type
< / dt >
< dd >
< span class = "param-type" > boolean< / span >
< / dd >
< / dl >
2013-10-02 00:16:40 +00:00
< / dd >
< dt >
2014-05-20 09:12:48 +00:00
< h4 class = "name" id = "setAll" > < span class = "type-signature" > < / span > setAll< span class = "signature" > (key, value, < span class = "optional" > checkAlive< / span > , < span class = "optional" > checkVisible< / span > , < span class = "optional" > operation< / span > , < span class = "optional" > force< / span > )< / span > < span class = "type-signature" > < / span > < / h4 >
2013-10-02 00:16:40 +00:00
< / dt >
< dd >
< div class = "description" >
2013-10-02 10:22:20 +00:00
< p > This function allows you to quickly set the same property across all children of this Group to a new value.
2014-03-24 12:41:45 +00:00
This call doesn't descend down children, so if you have a Group inside of this Group, the property will be set on the Group but not its children.
If you need that ability please see < code > Group.setAllChildren< / code > .< / p >
< p > The operation parameter controls how the new value is assigned to the property, from simple replacement to addition and multiplication.< / p >
< / div >
< h5 > Parameters:< / h5 >
< table class = "params table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th > Argument< / th >
< th > Default< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
< td class = "name" > < code > key< / code > < / td >
< td class = "type" >
< span class = "param-type" > string< / span >
< / td >
< td class = "attributes" >
< / td >
< td class = "default" >
< / td >
< td class = "description last" > < p > The property, as a string, to be set. For example: 'body.velocity.x'< / p > < / td >
< / tr >
< tr >
< td class = "name" > < code > value< / code > < / td >
< td class = "type" >
< span class = "param-type" > *< / span >
< / td >
< td class = "attributes" >
< / td >
< td class = "default" >
< / td >
< td class = "description last" > < p > The value that will be set.< / p > < / td >
< / tr >
< tr >
< td class = "name" > < code > checkAlive< / code > < / td >
< td class = "type" >
< span class = "param-type" > boolean< / span >
< / td >
< td class = "attributes" >
< optional>< br >
< / td >
< td class = "default" >
false
< / td >
< td class = "description last" > < p > If set then only children with alive=true will be updated. This includes any Groups that are children.< / p > < / td >
< / tr >
< tr >
< td class = "name" > < code > checkVisible< / code > < / td >
< td class = "type" >
< span class = "param-type" > boolean< / span >
< / td >
< td class = "attributes" >
< optional>< br >
< / td >
< td class = "default" >
false
< / td >
< td class = "description last" > < p > If set then only children with visible=true will be updated. This includes any Groups that are children.< / p > < / td >
< / tr >
< tr >
< td class = "name" > < code > operation< / code > < / td >
< td class = "type" >
< span class = "param-type" > number< / span >
< / td >
< td class = "attributes" >
< optional>< br >
< / td >
< td class = "default" >
0
< / td >
< td class = "description last" > < p > Controls how the value is assigned. A value of 0 replaces the value with the new one. A value of 1 adds it, 2 subtracts it, 3 multiplies it and 4 divides it.< / p > < / td >
< / tr >
2014-05-20 09:12:48 +00:00
< tr >
< td class = "name" > < code > force< / code > < / td >
< td class = "type" >
< span class = "param-type" > boolean< / span >
< / td >
< td class = "attributes" >
< optional>< br >
< / td >
< td class = "default" >
false
< / td >
< td class = "description last" > < p > If < code > force< / code > is true then the property will be set on the child regardless if it already exists or not. If false and the property doesn't exist, nothing will be set.< / p > < / td >
< / tr >
2014-03-24 12:41:45 +00:00
< / tbody >
< / table >
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-839" > line 839< / a >
2014-03-24 12:41:45 +00:00
< / li > < / ul > < / dd >
< / dl >
< / dd >
< dt >
2014-05-20 09:12:48 +00:00
< h4 class = "name" id = "setAllChildren" > < span class = "type-signature" > < / span > setAllChildren< span class = "signature" > (key, value, < span class = "optional" > checkAlive< / span > , < span class = "optional" > checkVisible< / span > , < span class = "optional" > operation< / span > , < span class = "optional" > force< / span > )< / span > < span class = "type-signature" > < / span > < / h4 >
2014-03-24 12:41:45 +00:00
< / dt >
< dd >
< div class = "description" >
< p > This function allows you to quickly set the same property across all children of this Group, and any child Groups, to a new value.< / p >
< p > If this Group contains other Groups then the same property is set across their children as well, iterating down until it reaches the bottom.
Unlike with Group.setAll the property is NOT set on child Groups itself.< / p >
< p > The operation parameter controls how the new value is assigned to the property, from simple replacement to addition and multiplication.< / p >
2013-10-02 00:16:40 +00:00
< / div >
< h5 > Parameters:< / h5 >
< table class = "params table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
2013-10-02 10:22:20 +00:00
< th > Argument< / th >
2013-10-02 00:16:40 +00:00
2013-10-02 10:22:20 +00:00
< th > Default< / th >
2013-10-02 00:16:40 +00:00
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
< td class = "name" > < code > key< / code > < / td >
< td class = "type" >
2013-10-02 10:22:20 +00:00
< span class = "param-type" > string< / span >
2013-10-02 00:16:40 +00:00
< / td >
2013-10-02 10:22:20 +00:00
< td class = "attributes" >
2013-10-02 00:16:40 +00:00
2013-10-02 10:22:20 +00:00
< / td >
2013-10-02 00:16:40 +00:00
2013-10-02 10:22:20 +00:00
< td class = "default" >
< / td >
< td class = "description last" > < p > The property, as a string, to be set. For example: 'body.velocity.x'< / p > < / td >
2013-10-02 00:16:40 +00:00
< / tr >
< tr >
< td class = "name" > < code > value< / code > < / td >
< td class = "type" >
2013-10-02 10:22:20 +00:00
< span class = "param-type" > *< / span >
2013-10-02 00:16:40 +00:00
< / td >
2013-10-02 10:22:20 +00:00
< td class = "attributes" >
2013-10-02 00:16:40 +00:00
2013-10-02 10:22:20 +00:00
< / td >
2013-10-02 00:16:40 +00:00
2013-10-02 10:22:20 +00:00
< td class = "default" >
< / td >
< td class = "description last" > < p > The value that will be set.< / p > < / td >
2013-10-02 00:16:40 +00:00
< / tr >
< tr >
< td class = "name" > < code > checkAlive< / code > < / td >
< td class = "type" >
2013-10-02 10:22:20 +00:00
< span class = "param-type" > boolean< / span >
2013-10-02 00:16:40 +00:00
< / td >
2013-10-02 10:22:20 +00:00
< td class = "attributes" >
< optional>< br >
< / td >
2013-10-02 00:16:40 +00:00
2013-10-02 10:22:20 +00:00
< td class = "default" >
false
< / td >
2013-10-02 00:16:40 +00:00
2014-03-24 12:41:45 +00:00
< td class = "description last" > < p > If set then only children with alive=true will be updated. This includes any Groups that are children.< / p > < / td >
2013-10-02 00:16:40 +00:00
< / tr >
< tr >
< td class = "name" > < code > checkVisible< / code > < / td >
< td class = "type" >
2013-10-02 10:22:20 +00:00
< span class = "param-type" > boolean< / span >
2013-10-02 00:16:40 +00:00
< / td >
2013-10-02 10:22:20 +00:00
< td class = "attributes" >
< optional>< br >
2013-10-02 00:16:40 +00:00
2013-10-02 10:22:20 +00:00
< / td >
2013-10-02 00:16:40 +00:00
2013-10-02 10:22:20 +00:00
< td class = "default" >
false
< / td >
2014-03-24 12:41:45 +00:00
< td class = "description last" > < p > If set then only children with visible=true will be updated. This includes any Groups that are children.< / p > < / td >
2013-10-02 00:16:40 +00:00
< / tr >
< tr >
< td class = "name" > < code > operation< / code > < / td >
< td class = "type" >
2013-10-02 10:22:20 +00:00
< span class = "param-type" > number< / span >
2013-10-02 00:16:40 +00:00
< / td >
2013-10-02 10:22:20 +00:00
< td class = "attributes" >
< optional>< br >
< / td >
2013-10-02 00:16:40 +00:00
2013-10-02 10:22:20 +00:00
< td class = "default" >
0
< / td >
2013-10-02 00:16:40 +00:00
2013-10-02 10:22:20 +00:00
< td class = "description last" > < p > Controls how the value is assigned. A value of 0 replaces the value with the new one. A value of 1 adds it, 2 subtracts it, 3 multiplies it and 4 divides it.< / p > < / td >
2013-10-02 00:16:40 +00:00
< / tr >
2014-05-20 09:12:48 +00:00
< tr >
< td class = "name" > < code > force< / code > < / td >
< td class = "type" >
< span class = "param-type" > boolean< / span >
< / td >
< td class = "attributes" >
< optional>< br >
< / td >
< td class = "default" >
false
< / td >
< td class = "description last" > < p > If < code > force< / code > is true then the property will be set on the child regardless if it already exists or not. If false and the property doesn't exist, nothing will be set.< / p > < / td >
< / tr >
2013-10-02 00:16:40 +00:00
< / tbody >
< / table >
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-873" > line 873< / a >
2013-10-02 00:16:40 +00:00
< / li > < / ul > < / dd >
< / dl >
< / dd >
< dt >
2014-05-20 09:12:48 +00:00
< h4 class = "name" id = "setProperty" > < span class = "type-signature" > < / span > setProperty< span class = "signature" > (child, key, value, < span class = "optional" > operation< / span > , < span class = "optional" > force< / span > )< / span > < span class = "type-signature" > → {boolean}< / span > < / h4 >
2013-10-02 00:16:40 +00:00
< / dt >
< dd >
< div class = "description" >
2014-05-20 09:12:48 +00:00
< p > Sets a property to the given value on the child. The operation parameter controls how the value is set.
Operation 0 means set the existing value to the given value, or if force is < code > false< / code > create a new property with the given value.
1 will add the given value to the value already present.
2 will subtract the given value from the value already present.
3 will multiply the value already present by the given value.
4 will divide the value already present by the given value.< / p >
2013-10-02 00:16:40 +00:00
< / div >
< h5 > Parameters:< / h5 >
< table class = "params table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
2013-10-02 10:22:20 +00:00
< th > Argument< / th >
2013-10-02 00:16:40 +00:00
2013-10-02 10:22:20 +00:00
< th > Default< / th >
2013-10-02 00:16:40 +00:00
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
< td class = "name" > < code > child< / code > < / td >
< td class = "type" >
2013-10-02 10:22:20 +00:00
< span class = "param-type" > *< / span >
2013-10-02 00:16:40 +00:00
< / td >
2013-10-02 10:22:20 +00:00
< td class = "attributes" >
2013-10-02 00:16:40 +00:00
2013-10-02 10:22:20 +00:00
< / td >
2013-10-02 00:16:40 +00:00
2013-10-02 10:22:20 +00:00
< td class = "default" >
< / td >
< td class = "description last" > < p > The child to set the property value on.< / p > < / td >
2013-10-02 00:16:40 +00:00
< / tr >
< tr >
< td class = "name" > < code > key< / code > < / td >
< td class = "type" >
< span class = "param-type" > array< / span >
< / td >
2013-10-02 10:22:20 +00:00
< td class = "attributes" >
2013-10-02 00:16:40 +00:00
2013-10-02 10:22:20 +00:00
< / td >
2013-10-02 00:16:40 +00:00
2013-10-02 10:22:20 +00:00
< td class = "default" >
< / td >
< td class = "description last" > < p > An array of strings that make up the property that will be set.< / p > < / td >
2013-10-02 00:16:40 +00:00
< / tr >
< tr >
< td class = "name" > < code > value< / code > < / td >
< td class = "type" >
2013-10-02 10:22:20 +00:00
< span class = "param-type" > *< / span >
2013-10-02 00:16:40 +00:00
< / td >
2013-10-02 10:22:20 +00:00
< td class = "attributes" >
< / td >
2013-10-02 00:16:40 +00:00
2013-10-02 10:22:20 +00:00
< td class = "default" >
< / td >
2013-10-02 00:16:40 +00:00
2013-10-02 10:22:20 +00:00
< td class = "description last" > < p > The value that will be set.< / p > < / td >
2013-10-02 00:16:40 +00:00
< / tr >
< tr >
< td class = "name" > < code > operation< / code > < / td >
< td class = "type" >
2013-10-02 10:22:20 +00:00
< span class = "param-type" > number< / span >
2013-10-02 00:16:40 +00:00
< / td >
2013-10-02 10:22:20 +00:00
< td class = "attributes" >
< optional>< br >
2013-10-02 00:16:40 +00:00
2013-10-02 10:22:20 +00:00
< / td >
< td class = "default" >
0
< / td >
2013-10-02 00:16:40 +00:00
2013-10-02 10:22:20 +00:00
< td class = "description last" > < p > Controls how the value is assigned. A value of 0 replaces the value with the new one. A value of 1 adds it, 2 subtracts it, 3 multiplies it and 4 divides it.< / p > < / td >
2013-10-02 00:16:40 +00:00
< / tr >
2014-05-20 09:12:48 +00:00
< tr >
< td class = "name" > < code > force< / code > < / td >
< td class = "type" >
< span class = "param-type" > boolean< / span >
< / td >
< td class = "attributes" >
< optional>< br >
< / td >
< td class = "default" >
false
< / td >
< td class = "description last" > < p > If < code > force< / code > is true then the property will be set on the child regardless if it already exists or not. If false and the property doesn't exist, nothing will be set.< / p > < / td >
< / tr >
2013-10-02 00:16:40 +00:00
< / tbody >
< / table >
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-704" > line 704< / a >
2013-11-07 06:10:15 +00:00
< / li > < / ul > < / dd >
< / dl >
2014-05-20 09:12:48 +00:00
< h5 > Returns:< / h5 >
< div class = "param-desc" >
< p > True if the property was set, false if not.< / p >
< / div >
< dl >
< dt >
Type
< / dt >
< dd >
< span class = "param-type" > boolean< / span >
< / dd >
< / dl >
2013-11-07 06:10:15 +00:00
< / dd >
< dt >
< h4 class = "name" id = "sort" > < span class = "type-signature" > < / span > sort< span class = "signature" > (< span class = "optional" > index< / span > , < span class = "optional" > order< / span > )< / span > < span class = "type-signature" > < / span > < / h4 >
< / dt >
< dd >
< div class = "description" >
< p > Call this function to sort the group according to a particular value and order.
For example to depth sort Sprites for Zelda-style game you might call < code > group.sort('y', Phaser.Group.SORT_ASCENDING)< / code > at the bottom of your < code > State.update()< / code > .< / p >
< / div >
< h5 > Parameters:< / h5 >
< table class = "params table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th > Argument< / th >
< th > Default< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
< td class = "name" > < code > index< / code > < / td >
< td class = "type" >
< span class = "param-type" > string< / span >
< / td >
< td class = "attributes" >
< optional>< br >
< / td >
< td class = "default" >
2014-03-14 06:36:05 +00:00
'z'
2013-11-07 06:10:15 +00:00
< / td >
2014-03-14 06:36:05 +00:00
< td class = "description last" > < p > The < code > string< / code > name of the property you want to sort on. Defaults to the objects z-depth value.< / p > < / td >
2013-11-07 06:10:15 +00:00
< / tr >
< tr >
< td class = "name" > < code > order< / code > < / td >
< td class = "type" >
< span class = "param-type" > number< / span >
< / td >
< td class = "attributes" >
< optional>< br >
< / td >
< td class = "default" >
Phaser.Group.SORT_ASCENDING
< / td >
< td class = "description last" > < p > The < code > Group< / code > constant that defines the sort order. Possible values are Phaser.Group.SORT_ASCENDING and Phaser.Group.SORT_DESCENDING.< / p > < / td >
< / tr >
< / tbody >
< / table >
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-1322" > line 1322< / a >
2013-10-02 00:16:40 +00:00
< / li > < / ul > < / dd >
< / dl >
< / dd >
< dt >
< h4 class = "name" id = "subAll" > < span class = "type-signature" > < / span > subAll< span class = "signature" > (property, amount, checkAlive, checkVisible)< / span > < span class = "type-signature" > < / span > < / h4 >
< / dt >
< dd >
< div class = "description" >
< p > Subtracts the amount from the given property on all children in this Group.
Group.subAll('x', 10) will minus 10 from the child.x value.< / p >
< / div >
< h5 > Parameters:< / h5 >
< table class = "params table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
< td class = "name" > < code > property< / code > < / td >
< td class = "type" >
< span class = "param-type" > string< / span >
< / td >
< td class = "description last" > < p > The property to decrement, for example 'body.velocity.x' or 'angle'.< / p > < / td >
< / tr >
< tr >
< td class = "name" > < code > amount< / code > < / td >
< td class = "type" >
< span class = "param-type" > number< / span >
< / td >
< td class = "description last" > < p > The amount to subtract from the property. If child.x = 50 then subAll('x', 40) would make child.x = 10.< / p > < / td >
< / tr >
< tr >
< td class = "name" > < code > checkAlive< / code > < / td >
< td class = "type" >
< span class = "param-type" > boolean< / span >
< / td >
< td class = "description last" > < p > If true the property will only be changed if the child is alive.< / p > < / td >
< / tr >
< tr >
< td class = "name" > < code > checkVisible< / code > < / td >
< td class = "type" >
< span class = "param-type" > boolean< / span >
< / td >
< td class = "description last" > < p > If true the property will only be changed if the child is visible.< / p > < / td >
< / tr >
< / tbody >
< / table >
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-962" > line 962< / a >
2013-10-02 00:16:40 +00:00
< / li > < / ul > < / dd >
< / dl >
< / dd >
< dt >
2014-02-08 07:24:22 +00:00
< h4 class = "name" id = "swap" > < span class = "type-signature" > < / span > swap< span class = "signature" > (child1, child2)< / span > < span class = "type-signature" > < / span > < / h4 >
2013-10-02 00:16:40 +00:00
< / dt >
< dd >
< div class = "description" >
2013-11-07 06:10:15 +00:00
< p > Swaps the position of two children in this Group. Both children must be in this Group.
2014-09-09 14:36:56 +00:00
You cannot swap a child with itself, or swap un-parented children.< / p >
2013-10-02 00:16:40 +00:00
< / div >
< h5 > Parameters:< / h5 >
< table class = "params table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
< td class = "name" > < code > child1< / code > < / td >
< td class = "type" >
2013-10-02 10:22:20 +00:00
< span class = "param-type" > *< / span >
2013-10-02 00:16:40 +00:00
< / td >
2013-10-02 10:22:20 +00:00
< td class = "description last" > < p > The first child to swap.< / p > < / td >
2013-10-02 00:16:40 +00:00
< / tr >
< tr >
< td class = "name" > < code > child2< / code > < / td >
< td class = "type" >
2013-10-02 10:22:20 +00:00
< span class = "param-type" > *< / span >
2013-10-02 00:16:40 +00:00
< / td >
2013-10-02 10:22:20 +00:00
< td class = "description last" > < p > The second child to swap.< / p > < / td >
2013-10-02 00:16:40 +00:00
< / tr >
< / tbody >
< / table >
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-487" > line 487< / a >
2014-02-18 03:01:51 +00:00
< / li > < / ul > < / dd >
< / dl >
< / dd >
< dt >
< h4 class = "name" id = "update" > < span class = "type-signature" > < protected> < / span > update< span class = "signature" > ()< / span > < span class = "type-signature" > < / span > < / h4 >
< / dt >
< dd >
< div class = "description" >
< p > The core update - as called by World.< / p >
< / div >
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-1170" > line 1170< / a >
2014-03-14 06:36:05 +00:00
< / li > < / ul > < / dd >
< / dl >
< / dd >
< dt >
< h4 class = "name" id = "updateZ" > < span class = "type-signature" > < protected> < / span > updateZ< span class = "signature" > ()< / span > < span class = "type-signature" > < / span > < / h4 >
< / dt >
< dd >
< div class = "description" >
< p > Internal method that re-applies all of the childrens Z values.< / p >
< / div >
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-391" > line 391< / a >
2014-03-14 06:36:05 +00:00
< / li > < / ul > < / dd >
< / dl >
< / dd >
< dt >
< h4 class = "name" id = "xy" > < span class = "type-signature" > < / span > xy< span class = "signature" > (index, x, y)< / span > < span class = "type-signature" > < / span > < / h4 >
< / dt >
< dd >
< div class = "description" >
< p > Positions the child found at the given index within this Group to the given x and y coordinates.< / p >
< / div >
< h5 > Parameters:< / h5 >
< table class = "params table table-striped" >
< thead >
< tr >
< th > Name< / th >
< th > Type< / th >
< th class = "last" > Description< / th >
< / tr >
< / thead >
< tbody >
< tr >
< td class = "name" > < code > index< / code > < / td >
< td class = "type" >
< span class = "param-type" > number< / span >
< / td >
< td class = "description last" > < p > The index of the child in the Group to set the position of.< / p > < / td >
< / tr >
< tr >
< td class = "name" > < code > x< / code > < / td >
< td class = "type" >
< span class = "param-type" > number< / span >
< / td >
< td class = "description last" > < p > The new x position of the child.< / p > < / td >
< / tr >
< tr >
< td class = "name" > < code > y< / code > < / td >
< td class = "type" >
< span class = "param-type" > number< / span >
< / td >
< td class = "description last" > < p > The new y position of the child.< / p > < / td >
< / tr >
< / tbody >
< / table >
< dl class = "details" >
< dt class = "tag-source" > Source:< / dt >
< dd class = "tag-source" > < ul class = "dummy" > < li >
2014-10-22 20:49:44 +00:00
< a href = "Group.js.html" > core/Group.js< / a > , < a href = "Group.js.html#sunlight-1-line-588" > line 588< / a >
2014-02-05 06:29:17 +00:00
< / li > < / ul > < / dd >
< / dl >
2013-10-02 00:16:40 +00:00
< / dd >
< / dl >
< / article >
< / section >
< / div >
< div class = "clearfix" > < / div >
< footer >
< span class = "copyright" >
2014-02-05 06:29:17 +00:00
Phaser Copyright © 2012-2014 Photon Storm Ltd.
2013-10-02 00:16:40 +00:00
< / span >
< br / >
< span class = "jsdoc-message" >
2014-04-11 12:09:28 +00:00
Documentation generated by < a href = "https://github.com/jsdoc3/jsdoc" > JSDoc 3.3.0-dev< / a >
2014-10-22 20:49:44 +00:00
on Wed Oct 22 2014 21:45:54 GMT+0100 (BST) using the < a href = "https://github.com/terryweiss/docstrap" > DocStrap template< / a > .
2013-10-02 00:16:40 +00:00
< / span >
< / footer >
< / div >
< div class = "span3" >
< div id = "toc" > < / div >
< / div >
< br clear = "both" >
< / div >
< / div >
< script src = "scripts/sunlight.js" > < / script >
< script src = "scripts/sunlight.javascript.js" > < / script >
< script src = "scripts/sunlight-plugin.doclinks.js" > < / script >
< script src = "scripts/sunlight-plugin.linenumbers.js" > < / script >
< script src = "scripts/sunlight-plugin.menu.js" > < / script >
< script src = "scripts/jquery.min.js" > < / script >
< script src = "scripts/jquery.scrollTo.js" > < / script >
< script src = "scripts/jquery.localScroll.js" > < / script >
< script src = "scripts/bootstrap-dropdown.js" > < / script >
< script src = "scripts/toc.js" > < / script >
< script > Sunlight . highlightAll ( { lineNumbers : true , showMenu : true , enableDoclinks : true } ) ; < / script >
< script >
$( function () {
$( "#toc" ).toc( {
2014-04-10 22:13:43 +00:00
anchorName : function(i, heading, prefix) {
2014-03-14 06:36:05 +00:00
return $(heading).attr("id") || ( prefix + i );
},
2013-10-02 00:16:40 +00:00
selectors : "h1,h2,h3,h4",
showAndHide : false,
scrollTo : 60
} );
$( "#toc>ul" ).addClass( "nav nav-pills nav-stacked" );
$( "#main span[id^='toc']" ).addClass( "toc-shim" );
} );
< / script >
< / body >
2013-10-01 15:56:47 +00:00
< / html >