Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
Tags
(1 edit)

Will be approaching this problem with a different solution.


Instead of having the chicken in the front "block" people in the back, we simply ask the chickens in the back if there's anyone "in front".

For a simple 2-grid setup like above, this is very simple: we just need to check if any enemies columns > target column.

However, the problem in general is we ASSUME what "front" and "back" means. Direction matters.

For simplicity, I will be adding a direction to the grid, so that the left grid is

3 2 1

While the right grid is

1 2 3

I'm not sure if this should affect tile designation though. For example, (1, 1) is normally in the top-left corner, but if we were to "flip" the grid horizontally, does that means (1, 1) is now  the top-right corner?

Something to consider. But let's think about more than just two grids. What if there are three grids? What if they are facing up and down? Perhaps it would be better to define "front" with respect to the direction of each battler?

(1 edit)

We can ignore flipping the grids around if we have a way to determine the "position" of each grid.

__ G4 __
G1 G2 G3
__ G5 __

Consider this grid layout.  If you only consider G1 and G2 (which is our two grid layout), G1 is "left" of G2. Which means if a chicken is standing on G1, then the "front" most column is on the right, while the "backmost" column is on the left.

On the other hand, if the chicken was standing on G3, then the "front" most column is on the left, and the back most columns is on the right

We don't consider the diagonal cases for now, but I think this approach should be suitable for even 4-sided attacks shown above.

Actually with this grid approach, we can basically implement skill ranges for multi-grid setups.

You would just need a way to "connect" grids together, and then we'll know "distance" between different tiles on different grids.

For example, the right-most tile on G1 will be one tile away from the left-most tile on G2.

And why not 9 grids and using the numerical pad like fighting games notation (example soulcalibur notation) :

G7 G8 G9

G4 G5 G6

G1 G2 G3


It also opens diagonal ranges. The middle grid would be the Grid 5

Could be extended like that too. I just didn't want to bother with diagonals at this point lol

(+1)

Oh, also I was looking for tabletop rpg fantasy maps and I found something that MIGHT give you an idea for you grid system on this store page :

https://www.drivethrurpg.com/product/256706/City-Modular-MapTiles-COTBS

Near the middle of the page, there is an animation of a modular arena, on twitter you said something about shrinking arena so that might be interesting!