[SUPPORT] Advanced Turn Based Tile Toolkit

Hi there! It is a bit hard for me to know exactly what is going on here. If you can end the turn and move a new puppet etc. then I doubt it is something wrong with the Action, as that would likely stop the action queue and prevent any further actions from occuring (or at least throw an error).

Since I don’t know what you have modified I can’t give you the exact answer, but these are the steps I would personally use to investigate this: In BP_Ability add a breakpoint to ServerInteract. This is the event that should fire when you click a valid tile with any ability. When you click the enemy to attack it, it should trigger the breakpoint. From there keep clicking Skip and see at which points it breaks off before leading to the attack. Consider comparing this by doing the same in a fresh project and see where they differ. Perhaps this will let you solve the problem on your own. If not, report back to me on the behavior and I’ll weigh in.

1 Like

Thank you so much, that helped a lot!

Pfff and as I hoped/suspected, the problem was really simple, which was great - but also really embarrassing, haha.

The breakpoint troubleshooting showed the ability didn’t have a valid target. Apparently in my testing around with puppet classes and changing meshs, at some point I replaced the enemy puppet without realising it and never designated the replacement as an enemy. No wonder the attack action didn’t run, it had no enemy to target. Now I feel like facepalming. Leaving this up anyway, maybe someone in the future stumbles across the same dumb mistake and finds this here, haha.

Welp, at least I learned a lot about troubleshooting. Thank you so much again! Your toolkit is a big reason I’m even learning UE in the first place, because this is 100% the sort of game I adore and would like to make for my project and even from outside, the toolkit already made such a useful and comprehensive impression.

Glad you were able to solve it! And yeah, more often than not it is something simple and stupid like that. I get stuck on similar stuff all the time :slight_smile: Thankfully debugging is also a skill one can get better at! I’m humbled that my kit was part of the reason you started using UE. If you use Discord, feel free to join our little community there (link on the store page).

1 Like

How do you link the grid manager to the landscape? For a specific example, how would i use the grid manager to procedurally generate a hex map like in civilization or for the king of different terrains and enemies. Lets first just home in on at new game start, not worry about spawning in new enemies as game progresses.

Hey, so I’m not 100% sure what you mean with linking the grid manager to the landscape. The grid manager has options for automatically generating a walkable grid on top of any underlying terrain (see the first four tutorials of my tutorial playlist which goes into this generation).

But if you want to get into full procedural generation of a Civ-style map with intelligent placement of coastlines, mountains, rivers etc. that is a huge topic, and ATBTT does not include something like that by default. The underlying structure of ATBTT should be friendly for adding that sort of thing, though. I recommend looking at Red Blob Games’ excellent tutorials on procedural map generation on grids: https://www.redblobgames.com/

Thanks I will take a look at his resources. I wasn’t meaning to presume that ATTBT could out of the box auto generate intelligent terrain. What i was trying to ask (poorly forgive me I’m still new) is there a way to essentially use the grid manager as the landscape guide, and have physical tiles of landscape generated in the same hex size and shape as the grid? I understand the actual tile generation itself would need its own blueprint. But can the grid manager be called upon somehow to act as the blank grid stencil? And if so how do i go about referencing the grid when setting up my procedural map generator?

I guess the specific point I’m trying to hone in on, is how to ensure that the actual landscape prints its tiles in the same hex size as the grid manager, so that when generated at run time the 2 spearate elements, landscape and grid manager, are synched up.

If this is outside the scope of the tool kit, no biggie. ATTBT is still perfect for the tactical combat side of the game, on separate combat maps. Your videos have been super helpful and inspiring!

Ok, thanks for elaborating. I’d say the answer to your question is yes, you can use ATBTT as a base for this. If you look at the function I have for generating the instanced static meshes that preview the grid, you are essentially looking for a (much) more complex version of that. The Grid Manager has functions for getting the correct tile location, finding adjacent tiles or tiles in a set range, finding the shortest path between tiles etc. All of these things should be useful as part of procedural generation of a Civ-style map.

When I first started using UE4 way back in 2014 I communicated a lot with another dev here called @Zeustiak. He made a super impressive Civ-style hex grid map generator. We went a lot of back and forth on finding the best ways to do instanced grids, pathfinding etc. in blueprints. It seems all the fantastic screenshots are now unfortunately gone, but there is probably still a lot you can learn from reading his thread: Map Generator 3.0 - Please Critique!

Good day. in old version i use the blueprint for set number of return attack.
theare is in new versin?

How to alow range unit te make return attack to other range unit if they are in range?

Hey another question for you. I’ve been trying to integrate “Easy Quests” free quest system from the marketplace. Followed all the steps to migrate needed code over to my character and got quest giver placed etc. When running in game, approaching or walking over quest giver does nothing. I assume the interaction needs to be sequenced through the turn manager, but I’m not quite sure how to do that.

In the new HoMM example map, counter attacks are handled within the interface function DefaultAttackHoMM, which is implemented in BP_Unit_Anim_HoMM.

You will wind a branch at the start of this implementation for attack range, which you can

Hey, it is a bit hard for me to know exactly what is going on here, as I don’t know how EasyQuests works. Sounds like it might be using some sort of collision trigger when approaching the quest giver? If so you’ll need to set up the collision for your puppets appropriately. But this is mostly guesswork, as I have no idea how that asset functions.

1 Like

I decided to go a different route and just hand make quests widget, objective widget, quests, and objective blueprints. I followed a youtube guide that does this in 3rd person game mode. Following his guide, I had no problem getting the quest log to open and populate in the 3rd person project.

Then, I migrated the blueprints over to an ATTBT project. That’s where the issues start. I think I have narrowed down the cause. In the 3rd person tutorial I followed, he uses the standard ThirdPersonCharacter for some needed code, and to be referenced in all the quest and objective blueprints. I cannot find a separate ThirdPersonCharacter_puppet, it’s just a pawn class that functions differently than the actors that come with the toolkit.

What I’ve tried so far. First, I tried moving code from BP_Unit_anim_character over to ThirdPersonCharacter to try to get 3PC to register to the grid, in the same manner as your tutorial videos about puppets connects Golden to the grid, for example. That didn’t work. 3PC just sits there like a piece of scenery.

Then I moved all the quest coding (J to open journal, and get quests on event play start) from 3PC over to Unit_Anim_Character. The issue I run into here, is that U_A_C is not a pawn, and the coding in the objective and widget blueprints only works for pawns, they wont compile properly when casting to actors. I did notice that the code for J = open quest widget seemed to work in the U_A_C event graph, but the objective widget (inside quest widget) doesn’t populate like it did in the 3PC only game.

So I moved on to moving the same 2 lines of code over to BP_Character_puppet, and changed all references in the other blueprints to reference it. Seems to compile fine, but I still don’t get any data populating my quest widget when i press j. Side note, BP_C_P has its own event start. I assume hooking up the get quests blueprint to the existing event start would work. Assuming BP_C_P is even the right place to put said code. My understanding from watching your tutorials was that puppet only accounts for visual representation, and all game logic was held in the BP_Unit_Anim.

Also, when needing to cast to a player controller, do I need to be casting to PlayerController, or PlayerController_ATTBT?

This is driving me nuts, I’ve spent 20+ hours on it trying to work out every possibility I could before bugging you about it here.

Hey there! This kit is very amazing! I’ve never seen such a modular toolset. I’ve begun working on some levels for a project of mine. I just have one question.

Is there a slightly more comprehensive tutorial or overview on how to setup a basic networked multiplayer demo?

What I need is to be able to host a lobby server, for players to be able to connect to it and get paired into a level together. All games would be 1v1, so a server browser would be a bit redundant.

I noticed there is some networking UI in the Toolkit assets and I managed to look through some of the networking blueprints, but I’m still a bit lost.

Can anyone give me a hand?

Hi again. It is still a bit tricky for me to know exactly what is happening here, since I don’t know how the asset in question works. That they have hard coupled a quest system to the pawn class seems a bit weird to me, but I guess I’ve heard of worse coding. I can only make guesses here, but I’m guessing that you are supposed to move into some trigger which activates a quest UI or the like?

I think this might be easier to solve on Discord, where we can go a bit back and forth and we can try to figure out what is the relevant part of the code together. Check out the original post of this thread to find it.

As for casting the player controller, that all depends on what you need. If you only need to access functionality that is contained in the base PlayerController class, no need to cast it. If you need any of the custom stuff in PlayerController_ATBTT you’ll need to cast to it (or use an interface).

Hey, have you tried to run the MPSpawn example map? It lets multiple players join the same map and only starts the game once all have clicked to start. It seems like your question might be more about general networking than anything specific to ATBTT (might be wrong here), so make sure you know how to set up such a map in a simple project without ATBTT first. Then you can see if you run into any ATBTT specific problems that I can help with.

New hotfix is out! It seems like the engine code for detecting infinite loops has gotten more sensitive in UE4.27, which can cause a false positive in the Action Manager, causing ATBTT to crash. This hotfix addresses this issue.

v3.22 (for version 4.27. Live 24.09.21):

  • Fixed potential infinite loop false positive in Action Manager
  • Fixed issue in HoMM map where swordsmen would turn into their swords in a packaged game (pretty weird bug, I know)
  • Fixed issue where the camera would not be centered on the grid in a packaged project in the HoMM example map.
  • Other minor fixes (see Trello)

Hi Monokel. I am working on a turn based strategy much like the original fallouts. Are you able to assist me with how to implement displaying a character sheet that contains the attributes/stats of the active character. I wish to work with the experimental realtime/Turnbased template. I have my game template planned in an excel spreadsheet and plan on using your toolkit as the framework and replacing the variables with newly created ones. Is this as simple as replacing the current variables with the new ones? I ask this because variables in my system like HP or AP are derived from combining attribute variables in a function for eg Health is a combination of Strength and Endurance so I create a function and promote the result to a variable. Would that be a correct way to start replacing the current variables?

Thank you for your time and effort on this toolkit, Its a great investment.
Thanks for taking the time to reply to my questions I will most likely have many more in the future =)

Hey, I’m also a big fan of the old Fallouts :slight_smile: Your question is a bit broad, but something like this should absolutely be possible to add. Will of course take some work, though. You are free to add your own additional attribute variables to BP_Unit. Alternately you can create your own child unit of BP_Unit and add your custom variables to this one.

I recommend looking at my tutorial for making a game similar to Heroes of Might and Magic. Obviously a very different game, but in it I go over how to add a new custom attribute to units (stack size, in that case). Perhaps that will give you something to build upon: ATBTT - Experiments - HoMM-Style Combat #1 - YouTube

Hi ,did you make any progress on making it easier to control groups of characters as squads? I was just looking at adding a “Squad” enum to BP_Unit, but it looks like i’ll have to do a lot of looping and checking over other BP_units. What do you think?

Hi, depends on what you mean by squads. Somethin like in Civ is pretty easy. Essentially single units, just with lots of skeletal meshes. If you are doing something where you need to be able to individually control and target the troops within the squad that are all standing on the same tile, then that can get quite a lot more tricky depending on what you need.

1 Like

Hey @

I got a basic multiplayer test level working, based on everything I found on the kit. I’m now working on getting some basic UI going so that you can connect through some sort of matchmaking.

Right now I want to make a dedicated server architecture going for it. Do you think you could roughly point me to how I could build a dedicated server for a networked ATBTT level since I want there to be multiple matchmaking servers that you could choose from that connect you to another user in a “game room”, which would be a dedicated server networked ATBTT level.

I’d like to set a group of BP_Units as squad and then have them move and attack as a unit. The system you made is unit-centric, so maybe I should replace the BP_Unit with a BP_Squad across the board and handle individual units as a special case. For path planning, target choice, etc I could have a C++ class to handle the added chaos.

Does that sound like a reasonable approach? You’ve made such a great starting point I feel like I’ll still save a ton of time even with a major refactor like that.