[SUPPORT] Advanced Turn Based Tile Toolkit

Hello from a fellow Norwegian :slight_smile: Great toolkit this! Iā€™m working on this little learning project we have going as well, so Iā€™ll attempt to clarify a bit. Iā€™m the dumb character artist doing a learn, so donā€™t expect any programmer intelligence out of me either.

I watched him try this, and what happened was some odd things where the square decal spawned on top of the hexagonal one on that units turn, both for the red and blue. This was on a copied grid manager though. It worked fine when editing the original (which we really donā€™t want to do, since weā€™re almost certain to break it at some point). Any idea what could cause this?

Golden, thanks for this!

What I think he is asking here is having the enemies with initiative of one all go one after the other, have the player units with the same initiative go after that (or before, depending), and then rinse and repeat for initiative 3, 10 etc. This is likely to group enemies spawned with a set initiative to go sequentially one after the other, without having the camera bouncing back and forth if itā€™s set to follow the units for instance. Bit of a marginal use case as far as i can tell, but hey, weā€™re learning.

Edit: Spoke to the man who posted, and yes he would indeed like to know if it is possible to make the units move at the same time, to save time when large hordes of enemies move in a horde mode type of game for instance. Pathing will likely be a nightmare, I know. Is it possible to simulate the moves individually, but then have the animations play at the same time?

Takk for hjelpen!

No worries, Iā€™ll do my best to explain and just let me know if you need more details.

Ah, sorry. That is a result of one of the uglier hacks in the toolkit. For the default abilities Iā€™ve set it up so that they choose a square or hexagonal markers based on the class of the current grid manager. This is just there for easy testing and debugging. For a released game there is no reason to have code that decides which markers to use based on the grid, as you will in all likelihood be using one or the other. So Iā€™d recommend just setting the markers directly. If youā€™re using BP_Ability_MoveAttack on your units, edit this ability and set the meshes of the various marker components to the meshes you want to use.

There are three different Turn Managers in the toolkit for various initiative behaviors. For a D&D-style initiative use BP_TurnManager_Initiative. If you ise the BP_ATBTT_Initiative GameState this turn manager will be used. Note that this will sorts units in initiative at startup, but not the new ones you add during the game. To sort the new units, call SortActorsInInitiativeOrder in the turn manager you are using, like so:

Ok, so that is a bit of a challenge, if doable. The toolkit is split up into gameplay logic that happens instantly and animation the plays out sequentially. I have played around with ways to have these animated actions run at the same time, either through sorting of the queued actions or through the use of multiple action managers working in parallel, but this is definitely not trivial to implement. If you are dead set on having this feature I can give it some more thought.

Bare hyggelig :slight_smile:

Thanks for clarifying, Raiken! Haha. And thank you for quick support. Iā€™ll do what you said when I finish work with regards to the spawning and initiative order etc.

No, I wouldnā€™t want impose on your time anymore! It was just a thought I had because I have plans for a horde defence sort of mode, and 20+ enemy turns in a row, with individual animations might get tiresome for the player :slight_smile: But I could very easily just hack the movement speed or something to get it working more quickly.

This is what happens when two studio artists try their hand at devā€¦it will look very pretty but probably play out incredibly janky :stuck_out_tongue:

Thanks again!

Hi i have the same problem here, Did you find a way to fix it?
Have a great day

Happy to help, and let me know if you need any more assistance :slight_smile:

Hey ecstrider, Iā€™m not able to reproduce the issue you are describing. Perhaps youā€™re placing the meshes so that the height difference to adjacent tiles is greater than HeightImpassableCutoff? Try adjusting either the meshesā€™ height or the value of HeightImpassableCutoff. If that doesnā€™t work, could you post a screenshot of how the problem looks?

Hi there!
the HeightimpassableCutoff was the ā€œIssueā€ i had it a default. i increased it 300 and i was able to walk up the stairs. Thanks for the the reply. Have a great day and be safe.

Hi Monokkle, I am trying to find where can i change the colors of the tiles. I even deleted the color blue and red color from the grid manager and when i press play they come up.

Glad that did the trick :slight_smile:

Hey ecstrider, you can set it up directly in the ability your units are using. In BP_Ability_Move check the components in the actor. You can change the decals and meshes used by that ability there directly.

Edit: By the way, if you want to prevent decals from bleeding onto the walls, select the wall meshes and set bReceivesDecals to false in their rendering settings.

Hello ,

Its been awhile but everything in my project is now working wonderfully and I wanted to ask how do you limit the playerā€™s camera movement in this toolkit?
Just to prevent them from going out of bounds or the edge of the map.

Thanks< EagleEyeGamma

Great that the project is going well :slight_smile: Iā€™ve hacked together something you can use to constrain the camera. It is a bit ugly, but functional. I might play around with it a bit and include something like this in a future update. Add the following function to the Pan comment box in BP_GridCamera:

https://i.imgur.com/9X6GiBM.png

This is the function body (pastebin):

https://i.imgur.com/BO5DJ5E.png

Hope that gives you the result you are looking for :slight_smile:

In action:

I was trying to add this too, as it would be a great idea to not have the player fly off the map. But cant add the code, If i paste it onto blue print screen the Unreal Engine crashesā€¦

Try copying parts of the graph or recreating it manually. Maybe blueprintue doesnā€™t like calls to functions from function libraries?

Thanks so much for the blueprint and it works great however on my end it weirdly locks onto certain parts of the map and wonā€™t allow you to move the camera to other parts of the grid itself for some reason on maps Iā€™ve made in the toolkit.

Ok, thatā€™s too bad. I hacked it together pretty quickly, so there are probably some issues Iā€™m unaware of. Are you able to reproduce the issues on a new map? If so, can you give me the steps to reproduce it?

I figured it out it, just has to do with changing the Multiplier for the Return Value and the number given in the multiplier for the Min value for the clamps. So Iā€™m now trying to figure out a value that can work for any and all maps.Also any idea how to make change levels a bit more cleanly? Iā€™ve tried it on my own but its awkward as it cuts you straight to the level without showing the victory screen, Iā€™ve tried putting a normal delay but it doesnā€™t want to show up for this function. I think a solution might be having a menu pop up after the win or lose screen pops up but maybe that would be cluttered?

For blocking the grid camera from panning infinitely there is likely some minor adjustment that needs to be made to make sure it works for all maps. Iā€™ll look a bit more into it.

Edit: Seems to work fine on all grid sizes on my end. Have you altered the grid in any way? Different tile meshes etc? What options have you enabled for the GridManager?

As for loading a map after the victory screen, you cannot add a delay inside a function, but you can do so in the event graph just before you call your OpenLevel function.

hi

I ran into a problem that I have tried to solve for hours but unsuccessfully, hoping you could help me.

1. in my set up i start with other level (not with a gridmanager inside). in the game mode bp_atbtt on beginplay i am going to a widget(instead of continue with the core setup) , then from this widget i am opening another level (with the gridmanager inside) and from there i continue to the activate atbtt.
the problem is that after the level is open its get stack (noting happens) . i saw that the grid manager reference in the setup core blueprints returns noting and it doesnā€™t get to the client setup ever. i have tried to use a delay after the open level (not in a function) but the delay for some reason is not working( its get stuck there).
if i use stream level then is working, but i donā€™t want to use stream level. i am very confused about that one. i donā€™t fully understand what is going there.

edit: now i am sure that i definitely need to do some sort of delay after the open level, but no matter what i do its not working.

  1. if i open the level (with the stream level option) and then i spawn unit then every thing works great. the problem is if i have a unit that was not spawned (was placed on the grid before) then i get error with the function handle unit spawning. i understand that this function is called from the construction scrip and still donā€™t have reference for the turn manager and that is the error i am getting (i think). what can i do about it?

cheers

leo

Hey @, does the hybrid map example still exist in the toolkit? All I see is the teleport experimental map and I was excited to know this toolkit had such an example when I purchased it. If it doesnā€™t exist anymore, do you have it anywhere that I can reference?

Thanks!

Hey leo, sorry that this is taking a bit of time. This is a non-trivial problem, so I need to spend a bit of time to figure it out. I will let you know when I have a solution.

hi

no problem, there is no rush. thanks for looking at it.

leo