Quantcast
Channel: GameDev.net
Viewing all articles
Browse latest Browse all 17625

How to avoid moving entities from occupying the same location in A*

$
0
0

So I have a A* implementation that works pretty well however there is one thing I am not able to wrap my head around.

This game is turn based and after the player moves, all the other entities move at the same time. The issue I am trying to figure out how to handle is preventing the entities from occupying the same tile at the same time. Since all the entities move at the same time (which is needed as there could be a few dozen being simulated and moving each one on their own would take away to long …


Viewing all articles
Browse latest Browse all 17625

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>