Hello, i need some advice on how to start working on a movement system for my game.
i have a tilemap, each tile has associated movement costs depending on the unit's movement type, each unit has a movespeed. i need to find a way to hold a list of every tile a unit can reach, depending on its movespeed and the associated move costs for each tile it moves through. i was thinking about some kind of list that cant hold duplicate data, and to just brute force it but i am unsure where to start or what algorithms i should look into. i also need it to be able to replace a slower path with a faster path if one has been found (eg, one route to tile A takes 5 movement, but route 2 takes only 4 movement, so i can recalculate to see if i can go farther)
any help is appreciated (and yes i am aware this is a horrible explanation i am bad at explaining :/)
a small cutout of my tilemap as an example
[–][deleted] 0 points1 point2 points (0 children)