jim716

Members
  • Content Count

    7
  • Joined

  • Last visited

  1. I'm trying to add a modal group to the stage (using the option in the Phaser.Group constructor) that I can use across states. This works fine. The modal group persists between states and appears above my state graphics. I'd like to have that group (with full size image) block input for the state graphics below. I've added a background sprite to my group that covers the screen and turned inputEnabled to true, but I'm still able to click on the state objects below. I've also tried adjusting the input priority - still no luck. Is it possible to make this stage layer block input from my state layer. Thanks
  2. Took a look and the answer from drhayes is your answer...
  3. Not very familiar with the PhoneGap Cloud workflow, but I've used Cordova quite a bit. In looking at your code, my initial suggestion would be to move the Phaser code into the onDeviceReady method (in index.js). The 'deviceready' event is fired when Cordova and its plugins are initialized. So in general, you'll want to wait to execute your own code until this event is fired. I learned to develop for Cordova with Phaser using Intel XDK, which is a Cordova IDE and cloud-build service (probably a lot like PhoneGap). Intel XDK includes a Phaser template and does have some tutorials in their documentation - most of which should apply to Cordova in general. Intel XDK also includes the Ripple Emulator, which runs Cordova apps in a simulated device on your PC/Mac. Although it doesn't work with all the Cordova plugins, I found it invaluable when learning because of how quickly you can test your code. Take a look - I'm sure you can probably use Ripple with PhoneGap as well.
  4. Hi, I'm wondering if there are general guidelines for getting the best audio experience in IE 9/10/11 (HTML Audio vs. Web Audio). I have a game that uses several short sound FX that in Chrome/Firefox work as expected. In IE, often the FX don't even play. This is especially true if the same effect is used several times in a row - think gun shots. I wondering what people do to handle this situation. Here's some basic questions: What is the best option for file format - I'm using 44100kHz, 32-bit, 96Kbps CBR MP3.Is it possible to play the same sound repeatedly and have it overlap? For example, a gunshot that resonates - can I have multiple gunshots overlap. SoundJS seems to do this in IE..., but I'm hoping to not have to implement a special audio API.Is there a good way to initialize the SFX for best performance? In other words, is it better to call game.add.audio and store the sound in the game object, or is it OK to create them each time a state is created? Does any decoding, initialization happen when calling game.add.audio?Would using Audio Sprites make this better? Why?Any other suggestions would be greatly appreciated. I've looked at several of the games posted recently in the News Section and I've found some games in IE handle audio very well (Cut it), while some don't have sound in IE (Odyssey). Just trying to figure out the best approach to handle sounds in IE. If someone has an example that would be even better. If necessary, I don't mind loading special assets just for IE. I'm using load.pack for all my resources, so having a special pack file is not a problem. Thanks in advance!
  5. With RC2, I ran into an issue with load.pack and relative paths. I received an 404 error when loading because it inserted the word undefined in my path. This error does not occur with RC1.
  6. I would like to use the Phaser loader (game.load) to load a configuration json file prior to calling my boot state. I know that I can do so, but have to wait until the game object is booted. What is the correct way to know when the game object is booted, so the load object is initialized? Waiting in a timed loop for isBooted seems like the wrong approach. I've tried assigning my own function to device.whenReady and oddly it seems to work, but I'm concerned this is not the correct approach either. Any advice is appreciated.
  7. Hi, Are there any functions or callbacks that are invoked when a Sprite is added or removed from the stage/world? I would like certain sprites to be able to initialize or shutdown input, etc. based on being on stage. Thanks!