Impact

This forum is read only and just serves as an archive. If you have any questions, please post them on github.com/phoboslab/impact

9 years ago by davidg0

I connected the earthquake entity to the trigger, and I set the duration and strength,
but nothing happens when the player passed the trigger.
There're nothing in console, and I required it in the main.js.
Why this doesn't work? Should I add sth. else?

9 years ago by Apiheld

davidg, see that Search box in the upper right? That shows you the answer :)

http://impactjs.com/forums/help/earthquake-trigger-question

9 years ago by davidg0

Quote from Apiheld
davidg, see that Search box in the upper right? That shows you the answer :)

http://impactjs.com/forums/help/earthquake-trigger-question

Thanks a lot :) But I still don't understand how it works!

9 years ago by drhayes

Do you have code that tracks the player's movement? It'll look like ig.game.screen.x = <some number> or something.

That post the Apiheld sent you to is saying that the earthquake trigger and the "camera" positioning code are fighting it out and the "camera" is winning. Find the ig.game.screen.x code in your game, comment it out, and see if that fixes your issue.

9 years ago by davidg0

Quote from drhayes
Do you have code that tracks the player's movement? It'll look like ig.game.screen.x = <some number> or something.

That post the Apiheld sent you to is saying that the earthquake trigger and the "camera" positioning code are fighting it out and the "camera" is winning. Find the ig.game.screen.x code in your game, comment it out, and see if that fixes your issue.

Yes, my game is a 3D game and I tried the earthquake in my 2D game which has the tracking camera, but it still not work!
Page 1 of 1
« first « previous next › last »