alexmr06 Posted August 25, 2015 Share Posted August 25, 2015 Hello/Bonjour, I am young all in programming, I learn at the same time I try. Is it possible to tell me how to do for an enemy spawn randomly from the top much like a tetris ? Even if of a collision with the enemy, hero dies.My game is almost over, then these are two things which I stop... Thx for the help and sorry to my bad english ^^. ( It's been two weeks I galleys above ) Link to comment Share on other sites More sharing options...
in mono Posted August 25, 2015 Share Posted August 25, 2015 var x = Math.floor(Math.random() * game.width);var y = 0;var spawnPoint = new Phaser.Point(x, y);I'd do something like that. Link to comment Share on other sites More sharing options...
alexmr06 Posted August 26, 2015 Author Share Posted August 26, 2015 ok Thank you for taking the time to read and answer me. I will try it tonight when I'm in peace without children :3. if I have a little problem, I would always ask you if you accept of course. ( thereafter ) Link to comment Share on other sites More sharing options...
Recommended Posts