• Content Count

  • Joined

  • Last visited

About puzzler

  • Rank

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. Is there a complete list somewhere of what things pause automatically and what things require manual management? For example, what about Timers?
  2. When my game in the browser loses focus, everything pauses: animations pause, music stops playing. HOWEVER, when I go back to the browser, the animations continue from where they left off, but the music behaves differently -- the music resumes at a point as if it had been playing in the background and time had elapsed. So then, my animations and music are out of sync. What is the simplest way of making animations and music behave similarly?
  3. By printing a debug statement inside the particle constructor, I can see that the particle system is NOT creating any more than the given 200 particles. So what is causing Phaser to allocate memory each time a particle is recycled? Is there some inner arcade/physics object that is dynamically allocated with each recycle? Is this an issue that is addressed in the later community editions?
  4. I'm noticing from the profiler that when I run the particle emitter in my game, the heap builds up over the course of a couple seconds and then drops back down after the garbage collection. To be sure the test is accurate, I've turned off everything else in my game so it is *only* the particle emitter that is running. My understanding is that once the initial pool of particles are created (in my case, 200), no more objects should be dynamically allocated, so why is this happening? My emitter uses a custom particle class that calls the kill() method on the particle when the particle gets more than a certain distance away from the source. My impression is that by calling kill rather than destroy, Phaser should be able to use the same particles over and over again. Why is Phaser, apparently, not reusing the particles? I'm using Phaser 2.6.2.
  5. I added to my game a button to activate fullscreen mode (by calling game.scale.startFullScreen(true);). Works great on the desktop. On android's built-in browser, the game just freezes up when I press the fullscreen mode button. Is there a safe way to call startFullScreen so it won't freeze up? Is there a way to reliably detect ahead of time that fullscreen isn't supported so I can simply not show the button.
  6. That definitely works. I'm not sure how I failed to notice that property was available directly on group. Thanks. The behavior of getBounds() is still rather bizarre to me, but if it's mainly meant as some sort of internal call to facilitate the other properties, maybe I'm just not supposed to be accessing it directly.
  7. I'm starting to use Phaser, and am mystified by the subtle complexities of how the API differs for sprites vs groups. Let's look at the process of creating a display element, and then adding it as a child of another display element at a given x,y. 1. Creating a sprite and adding it as a child of another sprite at a given x,y parent.addChild(game.make.sprite(x,y,"artkey")) 2. Creating a sprite and adding it as a child of a group at a given x,y parent.add(game.make.sprite(x,y,"artkey")) Why do we need to use add here, instead of addChild? 3. Creating a group and adding it as a child of a sprite at a given x,y g = parent.addChild(game.make.group()); g.x = x; g.y =y; Why is there no way to make a group with a given x, y in one step like sprites? Why the need to manually set position in two extra steps? 4. Creating a group and adding it as a child of a group at a given x,y g = parent.add(game.make.group()); g.x = x; g.y= y; For this, we use add and then we also need the two extra steps. Did I get the taxonomy correct here? Why is every combination different? Thanks.
  8. In 2.6.2, I've found that calling myGroup.getBounds().bottom gives me back an incorrect value unless I retrieve myGroup.height first. I find it bizarre that the behavior of getBounds seems to be influenced by whether or not I've inspected the height of the group first. Is this a known problem? Is there a way to make sense out of this behavior?
  9. Are people here happy with stability / performance / lack of bugs in the community edition releases of Phaser, or do you recommend sticking with the last "official" release (2.6.2)?
  10. What's the easiest way to make it so that a sprite's children get cut off when they are out of the bounds of the parent sprite?
  11. puzzler

    SVG support?

    Perfect. Is it easy to call an arbitrary function in Pixi's API from Phaser?
  12. puzzler

    SVG support?

    Thanks. Assuming I had such a tool, does Phaser have a corresponding API to do canvas drawing instructions that draw into something that participates in the scene graph, and perhaps cache it as a bitmap? (My frame of reference is that I'm coming from easelJS which allows you to do vector graphics drawings on top of any sprite, or create a "shape" object which has no sprite associated with it, but is simply a surface for drawing instructions).
  13. puzzler

    SVG support?

    Is there any support for Phaser for vector graphics artwork? I am unable to find any examples or documentation about this.