View Full Version : Tanks that make their own route. Help???

04-22-2012, 10:15 PM
Hello all you members of this amazing community :D

I stumbled upon a video on Youtube called "The History of Videogames" and noticed this game that is somewhat alike to what I planned to make a while ago. The game is 2:18 in http://www.youtube.com/watch?feature=player_detailpage&v=q6a3ZvPKIvY#t=137s . I quit the project since I couldn't figure out how to make the tanks make out a route by themself. I woul appreciate any link to a tutuorial or just a clue on how to make this.

Thanks in advance.
// TomBurk

04-14-2013, 08:39 PM
e.i A*-Algorythm

04-14-2013, 10:56 PM
The video is not available in my country (US)

I can try to help though...but without seeing it, I might be wrong.

I'd put a bunch of tags randomly in the level. Have a randomizer (set to override pattern) activate one tag at a time, and have the tank follow the tag. When the tank gets close to the tag, activate the randomizer again to select a new tag. The tank should now randomly move around the level by itself.

04-16-2013, 07:00 PM
I made a basic waypointing system which allows enemies to take up to two turns to locate the player in a fields of halls. (http://www.youtube.com/watch?v=V8AiugRMd-o) It's difficult to explain, but the idea is that the enemy tries to locate a waypoint that in the line of sight of the player and itself. If such a waypoint does not exist, the enemy travels to the closest waypoint and then searches for a waypoint that's in the line of sight of both the player and itself. If such a waypoint exists, the enemy follows it. If the enemy is directly in the line of sight of the player, it directly pursues it. To accomplish this I used pieces of hologram fired in four cardinal directions from the enemy which then hit waypoints or the player, which in turn activate tags that the enemy uses to determine what waypoint to follow, and what kind of waypoint to follow. (Do they follow the nearest waypoint, a waypoint within the line of sight of the player and themselves, or do they directly pursue the player?)

This logic could be modified so that the tanks follow a set path, or determine one to travel on when it's not neccessary for the enemy to track the player. I can give it to you, but I can't guarantee its effectiveness in terrain unlike the terrain used in the YouTube video I made unless it's modified to be more advanced, and you'll have to get your hands dirty in some logic to suit it to your needs. (I'm sure you won't mind that, though. :P)