Jump to content

The Phaser 3 Wishlist Thread :)


rich
 Share

Recommended Posts

 

Here's another vote for promises! I think it'd be handy to chain tweens with promises:

this.game.add.tween(this.player).to({ x: '+1', y: '+2' }).then((tween) => { return tween.to({ x: '+10', y: '+2' }); });

 

Is the .then replacing onCompleteCallback?

 

 

If so, oh lord that would be amazing.

Link to comment
Share on other sites

If you are just going to tween the same target object, promises are not necessary, try this instead (which is already supported by Phaser):

this.game.add.tween(this.player).to({ x: ['+1', '+10'], y: ['+2', '+2'] });

You can even use this way to let your player follow a bezier path by setting its interpolation method.

Link to comment
Share on other sites

  • 3 weeks later...

Internalization.

Here are some links for implementations.

 
May be able to use the Microsoft Internationalization and Localization language packs to help create your own language files using one of the JavaScript implementations.
Link to comment
Share on other sites

  • 2 weeks later...

I'd love to see an IDE similar to the Godot engine in Lazer. http://www.godotengine.org/projects/godot-engine It's a very slick implementation, very comprehensive with a impressive list of features including debugger, scripting console, resource manager, inspector, "run project in IDE", etc. I know of the Phaser Editor, http://phasereditor.boniatillo.com/ but I'm shy about using it, preferring to see an IDE that is kept current with Lazer releases as they occur.

 

Personally, while I'm an experienced coder, I think a single downloadable "one stop shop" solution would appeal to entry level, and possibly more experienced game developers.

 

Cheers.

Link to comment
Share on other sites

Full shader control

 

Current mechanism only allows for writing fragment shaders, but for certain effects I also need to modify vertex shader. To make my own full shader, I have to create and initialize a PIXI shader manually, then create blank filter, and then add compiled shader to the filter. Making a fragment+vertex shader should be as easy as supplying both fragment and vertex shader source to the Phaser.Filter constructor.

 

Rendering polygons

 

I've just been prospecting for ways to render a smoke trail, but found that there's no easy way to do it. Rope class isn't nearly flexible enough to do what I wanted. I practically have to implement my own PIXI class just to render a strip of triangles with variable color and alpha on edges and arbitrary vertex positions.

Link to comment
Share on other sites

My 2 cents of a feature I would like to see in Phaser3:

 

I wish 'Group' object would allow to access children by their name.

 

Something like:

var myGroup = game.add.group();var sprite = game.add.sprite(0,0, 'ball_img');sprite.name = 'ball_image'myGroup.getChildByName('ball_image');

This means that every object (sprite, image, group, button...) would have 'name' property (I think some of them already have but not really used - only for debug).

 

This feature would allow better handling of objects inside a group and between different groups.

 

For example: If I would like to use the 'swap' method, at this point I need to keep references to those objects which cause to a lot of boilerplate code! , BUT, by implementing the above feature we could have called 'swap' with instance's names! much easier...

 

CreateJS has it builtin - and coming primarily from this framework I found it so hard not to have this feature!

 

Thank you!

Link to comment
Share on other sites

Possibility to make objects unaffected by pause. Examples:

audio.ignorePause = true; // the music will continue to play during pause (default to false of course)

sprite.animations.ignorePause = true; // this sprite's animation will run even during pause

sprite.body.ignorePause = true; // this sprite's physics will run even during pause

sprite.ignorePause = true; // this sprite has physics and animation updates during pause

 

Example of usage:

* Pause screen

* Metroid NES, when you get on an important item the jingle should play unaffected and everything else should freeze until it's finished. (jingle.ignorePause = true; jingle.onComplete.add(function(){this.game.paused=false;},this); jingle.play(); )

* An action adventure in which you talk with a NPC surrounded by enemies. The music should continue, the NPC should be animated, the text should be interactive (all unaffected by pause) but all else should freeze.

* Other stuff :-)

Link to comment
Share on other sites

  • 2 weeks later...
On 1/1/2016 at 0:22 AM, SiriusCG said:

... I know of the Phaser Editor, http://phasereditor.boniatillo.com/ but I'm shy about using it, preferring to see an IDE that is kept current with Lazer releases as they occur.

 

 

Hi @SiriusCG

Good comment to highlights our philosophy: we work on Phaser Editor to be full compatible always with the last version of Phaser. As soon as Lazer is ready we start "migrating" Phaser Editor to it. It should not be the huge task since we never override Phaser or provide any extra plugin, we support plain Phaser so we want to deliver a tool for newbies who need to learn Phaser and experienced developers who loves to code and hack them self. Just note that many of the project templates are verbatim copies of the official Phaser Examples.  

Link to comment
Share on other sites

  • 2 weeks later...

I'd like to be able to create a sprite without having to know which atlas the texture came from. In Pixi.js this is easy because all textures are in one texture cache, so I can call var sprite = new PIXI.Sprite(PIXI.TextureCache["my-image.png"]); and don't have to specify the atlas.

The downside is that this means you can't have two images with the same name even in separate atlases, but frankly that is a price I'm willing to pay as the benefits outweigh it in my opinion. One such benefit being that you can use texturepacker multipacking and not worry about which atlas things end up in.

Link to comment
Share on other sites

I'd like to be able have some randomness to the start settings of particles. For example I'd like to have their start x, y, rotation and alpha values randomised within given ranges.

I'd also like to be able to specify an array of textures that should be used by each particle as 'movieclip' type animation.

Even better would be to have a set of say 4 or so arrays of textures and have each of the particles randomly assigned one of those arrays.

Link to comment
Share on other sites

I'd like to be able to add Points to Groups in the same way as Display Objects. This way I can use them as "anchor points" that are affected by all the transforms applied to the group. Later, I can reference these points and use them to calculate coordinates.

One use case might be, for example, spawning a bullet at the end of a gun's barrel. If I add an anchor point at the end of the barrel during group creation, I can reference that point later on, and I can spawn a bullet at its position. I know this can be accomplished using hidden sprites, but I feel like that might be a lot of overhead, especially when an object is cloned hundreds of times. Plus, it feels really hacky.

Link to comment
Share on other sites

Some ideas

- Good integration with Observables, so we can treat game events like streams and react that way. [here's an example]. I think this would be an even better way to handle async than promises. There's a learning curve, but the payoff for games is awesome.

- Clear patterns for UI integration. I tried to get that one called zebra working, but it was clunky. Theres also Feathers UI, but I don' tknow much about that. There's also html integration, but then there's issues of z index, etc.

- Better plugin pattern. The old decorator-ish one required too much knowledge of Phaser internals.

- good module loading system, and community support of a loder like rollup with tree-shaking. which leads to...

- Phaser is more modular and able to import only necessary pieces.

- Rely on core PIXI modules, if we're using pixi (not a customized version)

...but if we do customize pixi, its via a seperate shimming module.

Link to comment
Share on other sites

  • rich unpinned this topic
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...