Download

[SUPPORT] Advanced Turn Based Tile Toolkit

Good day Kurt. You have lelp me already alot. But i still have a question. Last time for disable selection unit at start game i did what u said:“In the “Begin new turn” comment box in the Event Graph of BP_TurnManager, at the rightmost node that calls EndActiveActorTurn set AutoNextTurn to false.”.And its work nice. But only for faction Player. How can i do same for faction Enemy?

It gets stuck in WaitForOngoingActions in TurnManager’s BeginActorTurn with TurnManager being the active actor. Can not figure out what’s the difference to the first time combat starts here.

Hi there, glad to hear you’re enjoying the toolkit. The initiative system is unfortunately a bit clunky at the moment, but hopefully you can modify it to suit your needs. I am currently working on an update that will improve the initiative system specifically.

For the initiative automatically being set to 100, 200 etc., this is because of construction script code in BP_Unit_Anim_Debug, which is a unit I’ve made for quick debugging. I do not recommend using this unit as a basis for your own units. Rather base them on BP_Unit_Anim (for skeletal mesh units).

A bit trickier, this one. This is also something that should be easier to implement after the next update. There is a strange tendency for support requests to show up concerning precisely the stuff I’m currently trying to fix :stuck_out_tongue: That is probably a good thing, I guess.

Here is a quite hacky solution, but one that should do the trick (pastebin):

Hmm, then it seems like there is some action that is started which is never ended. Try calling EndAction from the action manager. If that does not work, add this to the action manager to debug what actions are being called and see what the last one to be called was. It might give you a hint to why this ongoing action is being waited for and not completed:

@Monokkel WOW! Thanks so much. Its work as i wish.Perfect. Have a nice time, gl hf.

Small update for the developers waiting for the Turn Manager update. Refactoring the turn system is like trying to rip off a loose thread and it starts unraveling half your sleeve. I think I’ve finally got a pretty good handle on it now and am making good progress, but the way the turn system is tied up to unit ownership, factions and networked replication means that I’m refactoring these aspects of the toolkit as well. I will go to vacation in Japan early next month and will be gone all of August, and with the amount of stuff I need to fix I’m doubtful I’ll get it done before then, meaning that the next update will likely not be before September. There is a chance I can get it finished before I leave, but thought I’d give you all a heads up.

Happy to hear that! It might not be the most elegant solution, but good that it works for your purposes.

Oh man, I just got back from work and get to play now, and your leaving us… Just stay and work… Just kidding man, enjoy your well deserved holiday. Only a month though?
Are you gonna go see the nuke plants and watch for ufo’s… I"m thinking my wife and I should go to Japan in January and Europe in Feb, Retirement is gonna be nice… Have fun on your trip.

Take care, Monokkel! Thank you for letting us know your schedules so that we can plan accordingly.

Thanks! No plans for nuke plants and ufo’s. Mainly shrines, izakayas and arcades :slight_smile: I won’t go completely dark and will try to respond to support questions reasonably frequently, but progress on updates will be put on hold.

Thanks and no worries!

hello, sorry if this has been asked before. I was wondering if this currently, or at least potentially can, support procedural generation for tiles in the grid manager?

hi knut

Have a great holiday in Japan

a question:
I’m starting to build modular parts for my project environment and I’ve decided that I need a different proportions and therefore I have to change the size of tiles in the grid manager

  1. I made a new grid tile mesh of the desired size.
  2. I changed the grid tile mesh with the new one I made in the grid manager
    Everything seems to work fine (of course I have to change the size of the markers ect…)

My question is whether, to the best of your knowledge, there is no need to change additional parameters (such as the Tile x and Tile y variables ect….)? Am I expected to have problems as a result of the change? Or did I did enough and can continue to work properly without other problems?

thanks in advance

leo

@Monokkel Sorry for the delay. Just following up on my hover tile bug. There doesn’t seem to be any recognizable pattern in terms of tile height, tile location, or client. Sometimes a tile will not register the hover and display the decal and then 10 seconds later if you hover over the same tile it doesn’t register and display. I recorded a short clip of me showing the bug in game, and also a short clip of me scrolling through the hover blueprint in the BP Ability Base. I also created a print string to show when the tile hover was registering and when it wasn’t. Let me know if you have any insight into what’s going on.

ATBTT Hover Tile Bug
https://youtube.com/watch?v=azHqg4rxL0s](https://slack-redir.net/link?url=https%3A%2F%2Fyoutu.be%2FazHqg4rxL0s&v=3)

ATBTT Hover Tile Bug Blueprint
https://youtube.com/watch?v=YWa_MO096ls

Thank you!

Good day Knutt,
i have several question that i mention in Epic Games, but u deliver me to this forum.

  1. actualy i neet to change the win condition trigger
  2. as i speak before there is a condition where 2 player fight (automatically by AI) the game stop without any of unit dies
  3. I need to add physical damage, magical damage, pure damage and poison damage or ability based input variable, i already added all of it but physical damage since the original name was ‘damage’ so how can we add variable property and insert it into config menu
  4. Poison damage and regeneration will dealt in every cycle (ot every turn) how we put this variable into the blueprint?
  5. Last but not least, one day i need to setup all unit before the board begin, like menu or so on, do you have any blueprint to do so?

Nothing like that is built-in, but the procedural line-trace system I’ve included for auto-generating grids based on underlying terrain should work well in tandem with many other types of procedural generation. As long as you make your generated tiles conform to the dimensions of the grid and have the floors block PathTrace and walls block WallTrace you should be fine.

Hi Leo, you should indeed not have to change any other paramaters, as these variables will be altered automatically based on the size of the default tile mesh. Actually, in newer versions of the toolkit you do not even have to change the tile mesh, as you can just resize the grid manager directly (as you would any mesh or actor). However, using a new tile mesh is still recommended, as you would otherwise have to correct for the Grid Manager’s transform for any new custom stuff you add.

Thanks for showing the issue in such detail. I have to ask, does this also happen on the server or just for connecting clients?

Hey Darvis, thanks for posting again here. The comments on the product page are much too limited. Now for your questions:

  1. What do you need to change it to? Normally GameOver is set from BP_Unit when a unit is killed (after checking that only a single faction remains). For a new win condition you would disable this and instead set bGameOver in BP_TurnManager to true when your custom win condition occurs.

  2. From what I understood this is related to the game over code. If you plan to disable the standard win condition anyway, this should solve the issue.

  3. Not sure if you follow. If you’ve already added all the others, why is adding one more an issue? What is the end result you want to achieve here, and what do you mean by config menu?

  4. This could be done by using a status effect (BP_StatusEffect). You could make a poison status effect and have it deal damage on RunOnTurnStart or RunOnTurnEnd. Check out the mind control ability and status effect in the advanced example to get an idea of how to set this up.

  5. I don’t have a menu implemented for this specifically, but for whatever solution you end up implementing, you should be able to just spawn units onto the grid using SpawnActor, and the construction script should automatically add the units to the grid (and initiative order if you tick this box).

So I changed the ClientDisplayHover event in BP_AbilityBase to Run on Server and yes the same problem occurred.

Sorry, I was not clear. When you run your game in the editor with two or more players, one of the players will have the game run on the server, while the rest are clients (unless RunDedicatedServer is true). When running with a single player and RunDedicatedServer set to false, so you are just running it on the server, are you still seeing the issue? There is a known issue where clients send input to the server while moving the hover marker quickly, causing the server output back to the client to be choppy.

Just ran the game with 1 player and RunDedicatedServer set to false and yes still the same issue. I have been thinking this may be some type of performance issue. I did not notice that when I run the game with RunDedicatedServer set to false the hover attempts over the UI are very choppy.

Ok, looking at your video again this does anyway look different from that issue. I doubt it is a performance issue. My current guess is that the line traces might not return the correct location at some point, though not entirely sure why. To explore this I suggest you add print strings to every step of the hover execution chain to see at what specific place it stops. Break points are not practical here, since the issue happens randomly.

hi knut

I thought so, thank you very much for the explanation

cheers

leo

Good news, everyone. As an unprecedented event I actually managed to complete the update before my estimated date. Since this is a moderate refactoring I’d normally consider delaying release until the next engine update, in order to keep the current live version stored by Epic as the 4.22 version of the toolkit. However, the changes between the 4.21 and 4.22 for this toolkit were small enough that I don’t think this will be a big problem, as people could simply download and convert the 4.21 version. Also, if the next engine version is released while I’m on vacation I’d prefer not to spend time testing and updating then.

The main change in this update is a complete refactoring of the Turn Manager. I found the old version to be clunky and cumbersome; the result of trying to squeeze multiple turn systems into a D&D-like skeleton. One of the things developing this toolkit has taught me is that modularity is the key to flexibility, and so I’ve made sure the new Turn Manager is easily modifiable. Because of this I’ve included three turn managers. The base one is an XCOM-style setup with one faction at a time having their turn. The child actor variants is a D&D-style turn manager with an initiative based turn order and a more Fire Emblem/strategy game style turn manager very similar to the XCOM one, but where units are not selected automatically.

I will of course need to make a new tutorial video on this, which is a bit annoying, as the TurnManager one is fairly recent. This I almost certainly won’t get done before my vacation, however, so hopefully the new TurnManger is intuitive enough for people. If not, just let me know in this thread.

Update details:

v2.3 (Pending)

  • Refactored Turn Manager
  • Added variant Turn Managers similar to XCOM, D&D and Fire Emblem, respectively
  • Simplified and optimized unit ownership for networked multiplayer
  • Added display of range and movement when selecting enemy units
  • Added WASD for movement and TAB for unit switching.

No worries. Be aware that although I see no reason why you should have any issues, I have done most of my testing on grids with the standard tile size. If you encounter any problems, please let me know. Such an issue would likely look like something shifted a bit north-west of where you would expect it to be. But like I said, I doubt you’ll see anything like that.

hey thanks for getting back so quickly. sorry what i meant was more of a random generation of tile placement as opposed to random terrain generation. Similar to how XCOM generates their plots and parcels.I did try to modify the instance creation of the grid manager but had no luck in getting it to randomize tiles. It only winded up choosing one or the other for the entire grid despite the random function being ran per iteration of the forloop.