pimous Posted March 22, 2015 Share Posted March 22, 2015 Hi everyone, I am new in the phaser world, so I have some dummy questions.I have a monster and he is always jumping and I want he accelerates when the player is below it. How I can do that ? I catch the position of the player and then I change the monster.body.gravity.y to 1000 (instead of 100). But after the monster doesn't the same jumps. How I can fix that ? To solve this problem I think I should not change the gravity but the monster speed. How i can do that ? Thank you Link to comment Share on other sites More sharing options...
MichaelD Posted March 22, 2015 Share Posted March 22, 2015 try setting the velocity valuemonster.body.velocity.y = 10;// with 0 it should not move at all pimous 1 Link to comment Share on other sites More sharing options...
pimous Posted March 22, 2015 Author Share Posted March 22, 2015 Thanks for the advices !I tested and it I think it works MichaelD 1 Link to comment Share on other sites More sharing options...
Recommended Posts