Jump to content

Phaser Arcade Emitter's speed is not working (Phaser-CE 2.7.3)


JTronLabs
 Share

Recommended Posts

I've had this problem for awhile now, and just figured out what went wrong. Figured I'd post for the future generations. I was setting up emitters and no matter what I did, they didn't have any speed. Eventually I discovered it is because emitter.gravity is a point object (not a number), you need to use setTo. I tried to reproduce the error in sandbox, but it still works for some weird reason.

Regardless, you can fix the issue by doing 

    emitter.gravity.setTo(0, 0);

Instead of 

    emitter.gravity = 0;

 

Link to comment
Share on other sites

  • 3 weeks later...
 Share

  • Recently Browsing   0 members

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