Jump to content


  • Content Count

  • Joined

  • Last visited

  1. I'm working on a game and I've noticed it drops 4-5 frames on very regular intervals. I read an article that suggests it could be a "Memory Leak", in that the garbage collector is coming by and cleaning up dereferenced objects and that's what's slowing the game down. I ran the chrome profiler and this pattern of my Heap usage does suggest that's what's happening: So I'm trying to pool all my objects but the problem I have is with Tweens. I use a ton of them for juicing my UI text and whatnot so I create them on the fly very often. I tried reusing tweens instead of creati
  2. Apparently another mistake I was making was not waiting for audio to completely decode before leaving the preload state.
  3. I can confirm, replacing tilesprites made a massive difference in performance on mobile firefox. mobile firefox is still slow to start, and there's a huge delay before the music in the game will start playing mobile safari crashes during the first loading screen Does anyone know if audio could be the source of my problems? I'm using audiosprites that reference both an mp3 and an ogg file.
  4. Thanks! I had already done all of those things you listed. I read on someone's blog that tilesprites are really inefficient on mobile browsers, and my game uses tons of them. I'm trying to replace them all with an extended version of phaser.image, I'll report back if it helps.
  5. I'm having huge difficulties getting my game to run smoothly on the big three browsers for desktop and mobile. How my game currently runs on each platform: Desktop Chrome: Great, 60 fps, no problems Desktop Firefox: also great Desktop Safari: great Mobile Chrome: little chuggy, but altogether decent Mobile Firefox: Unplayable, 5-20 fps, music doesn't start playing until several minutes into play Mobile Safari: Unplayable, constantly crashing. Is it unrealistic to assume I can get it to play at 60 fps on all of these platforms? What are some (broad
  6. Can you show examples of how to use the particle systems in a game? I've created a "particleEffect" in my game but I can't figure out how I'm supposed to use it.
  7. Answer here: https://github.com/PhaserEditor2D/PhaserEditor/issues/71#issuecomment-366694277
  8. I'm using the Phaser Editor and I created a prefab for my player sprite, but no matter what I do I can't get it to appear in the assets window or in the options to add prefabs to my scene files. I created the Prefab by using File -> New -> Sprite Prefab. I've tried adding the associated script file to the pack.json file, I've tried loading the script in index.html, I've tried shutting down and restarting the editor but I just cant use the prefab. The prefab shows up where it's supposed to in my folder structure, and I can edit the canvas file normally. I just can't add the prefab to any
  9. /** * Takes the collision data defined in the collision editor of Tiled and applies it to * and exisiting tilemap for use with P2 physics bodies. * * Tilemap json data MUST be loaded in the Preload state/function using game.load.json() before this function is called * map must only have ONE tileset * each tile can only have ONE polyline set for it's collision * the polyline MUST be a complete shape (the last point is indentical to the first) * * @param {Phaser.Tilemap} map - this is the map which you want polylines added to * @param {string} ke
  10. Support for Tiled's Collision Editor with p2 physics bodies.
  11. Is there a solution to this problem? 3 years later Phaser's tilemap system still ignores the object properties defined in the collision editor.
  12. I figured out the problem: I wasn't creating layers for the buffered tilemaps (the ones not being rendered) once I did that everything showed up correctly. I'm still very confused why this is, as I didnt need to create the collision layers, and they still worked. Nevermind the problem still persists. I thought I had found a fix but I was wrong.
  13. I've tried manually debugging what's in the tilemap and it's pretty difficult to parse. From what I can see, all layers of my "worldMap" are correctly populated with tiles and seemingly all the tiles I'm expecting to not be blank have indices != -1 and alphas of 1. So it definitely looks like all the information is there.
  • Create New...