phamedev

Members
  • Content count

    23
  • Joined

  • Last visited

  1. CONTEXT_LOST_WEBGL

    When I change tab in chrome browser on PC and visit again after like 30 minutes the game screen is blank with this warning message: WebGL: CONTEXT_LOST_WEBGL: loseContext: context lost On one of my android tabs that happens when I press home button and open android browser again. I tried the search function of this forum but could not find anything relevant. What is happening and how to prevent it? If anyone knows how to handle the context_lost situation or redirect me to the helpful resource. Thanks
  2. Hello, 1. I created a group groupA in the game. 2. I created a sprite spriteA and added it to groupA. 3. After that I kill() spriteA and keep its reference in a pool array for later use. 4. I destroy() groupA. 5. I get the spriteA from the pool array to be used in another group and try to change its texture with loadTexture(), I get error: phaser2.8.8.js:46794 Uncaught TypeError: Cannot read property 'cache' of null at Phaser.Sprite.loadTexture (phaser2.8.8.js:46794) That doesn't happen if I don't destroy the group in step 4. Could anyone please explain what is going on and what is the right way to reuse Sprites even when their container parents are destroyed?
  3. I have to add lengthy instructions (3 pages, with examples and images, possibly with one animated GIF) to a game I'm building using Phaser framework. The instructions will be shown by clicking "Instructions" button on the game title page (title state). How do you usually do that? Should I use bitmapText for paragraphs of instructions? I'm thinking about showing them in html format in a DIV the same size of the canvas with canvas hidden behind it. What is more practical? Any suggestions?
  4. Text and BitmapText performance on iOS

    I was not tinting the BitmapText but tinting it didn't make much difference. I just changed renderer from Phaser.AUTO to Phaser.CANVAS and fps improved to 47 (from 15 wtih bitmapText).
  5. I'm currently working on a game with more than 32x32=1024 sprites on the screen at the same time with animation and everything runs 60fps. (iPhone 6 and iPad 4th Gen) But when I introduce 2 bitmaptext objects for score and level, fps drops to 15fps. Even showing fps in render function using game.debug.text has impact on performance and I have to draw a horizontal progress bar for fps instead of text. Is there a way to improve the performance with bitmapTexts?
  6. Phaser Button Click/Touch and Cancel problem

    I think you guys are doing a great job already. It's just people like me coming from different backgrounds with old habits sometimes look at wrong places.
  7. Phaser Button Click/Touch and Cancel problem

    Thanks for the link. Really helpful and I didn't know it existed.
  8. Generally when you click or tap a button on mobile devices and then don't do mouse-up or lift touch on the same button and do it elsewhere the action is cancelled. But the Phaser buttons don't behave like that. Do the mouse-down on the button, drag and do the mouse-up outside the button, the button-click is still triggered. Is there a way to fix/change that behaviour? PS: I just tested that when you use the event.onInputUp on sprite etc, it is still fired when the onInputUp happens outside the object.
  9. 1. There are examples where you can use assets, I don't see any option to register and upload? 2. How do I select the Phaser version to use in Sandbox editor?
  10. Can I show the load progress of sprite Atlas?

    Thanks Cudabear. i can use the total number of bytes downloaded as I already know the total size of the atlas. Can that information (bytes downloaded) be obtained from Loader or other Phaser object?
  11. Is it possible to show the loading progress of a png sptire atlas and its json file? Something like we used to do in flash with totalBytes and loadedBytes?
  12. Game list of phaser games

    Just made my first html5 game while learning phaser (ver 2.8.7): Yellow Out - https://www.quickflashgames.com/games/yellow_out/
  13. Phaser.CANVAS, Phaser.WEBGL or Phaser.AUTO ?

    Can you please give examples of cases when it should not be set to AUTO? I'm currently working on a game and when I set it to AUTO the fps is 3-8 on iOS (iPhone 6) but with CANVAS it jumps to 59!
  14. Same background image in all states

    Hello, I'm new to the Phaser framework and I'm trying to have a single backgound and logo througout all the states in a phaser game. I add the background image in the very first state but when I start the next state using: this.game.state.start("State2"); the background image disappears. Do I have to load the background image in every state? Thanks
  15. [Phaser][Completed] - Pop Pop Bubble Wrap

    A fun little game. Many I ask how did you package it for Android and iOS?