how far can i move on grid

0 favourites
  • 5 posts
From the Asset Store
Snap to visible grid - perfect solution for any game genre
  • heey,

    I have a problem. I am making a turn based stratagy game that has a lot in common with "advance wars".

    In this game, you can make units and move this units around the map. but it only can move once a turn and only a few tiles. the mape is grid-based. I want to indicate how far a unit can move, when you hover over it with a mouse. how do i do this?

    I Really have no clue and just tried some stuff that did not worked at all.

  • I have done something similar using an invisible sprite pinned to the unit, and the sprite becomes visible when you hover the unit. The sprite can just be a half-transparent colored grid that is the size of how many steps the unit can move.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • i like your sullotion.

    but what do you do when a path is blocked? or when you can not move as far as normal because the units have to walk trough a forest

  • You could make the tiles have invisible sprites on them, becoming visible on certain conditions when hovering the unit (for instance; if distance from grid to unit is less than X make grid visible). This way you can handle 'forest' and 'endoftheworld' movement as well.

    Obstacles is the real challenge, I think there is no easy way to implement the movement around obstacles without using alot of different conditions.

  • Uses a couple rex plug ins. I think pathfinder?

    Just a jump start for you.

    Use the project anyway you want.

    A lot of this can be found in the FAQ I just compiled it a long long while ago.

    xanderbot.site50.net/map

    xanderbot.site50.net/map/map1.capx

    Advance Wars Fog of War:

    xanderbot.site50.net/map/lineosite.capx

    Prohibiting movement can be handled a number of ways,

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)