I was wondering how to make a game based on turns and not on real time events. I will appreciate any advice
look (its buggy) http://www.flowlab.io/game/play/415073
So here’s one way you could do it:
- Create a player object and some enemies
- Put switches in front of your player controls
- When the player takes an action, turn off the switches and send an “enemy start” message to the enemies
- When the enemies get an “enemy start” message, they can take one action then send a “player start” message to the player, which turns his controls back on. You can add a bit of delay with a timer if you want the enemy turn to last longer.
Here’s an example:
is there a way to make enemies move towards you using this technique?
Yes, the enemies can move however you like. There are various ways to make an enemy chase you.
Here is a simple example, by pointing the enemy at the player and moving forward: http://flowlab.io/game/view/188859
Here is a more sophisticated example, moving the enemy without changing its direction by comparing the enemy and player positions:
Thank you very much! This will definitely be in one of my new boss battles