[SUPPORT] Advanced Turn Based Tile Toolkit

Great stuff, that should be no problem, Ill just search for the boolean marker then. Thanks!

  1. Not seeing anything like that. Does this happen only for the new version? What error are you getting?
  2. The ability icon display and clicking can be found in WBP_AbilityBox and WBP_Ability.

No worries. As mentioned, though, not every little change is marked, but hopefully all of the most important stuff.

Prepurchase question hereā€¦ It looks like youā€™ve written this all, or mostly in blueprint. Is this available at all in only c++ or is the performance totally fine for this to be running entirely in blueprint? How well will your system plugin with someone who may plan to do most of extra work in c++ and not blueprint?

hi

I am getting this warning in the output log whenever I start to modify the toolkit :

LogScript: Warning: Script Msg: Attempted to access index 0 from array ā€˜CallFunc_GetAllActorsOfClass_OutActorsā€™ of length 0 in ā€˜/Game/AdvancedTurnBasedTileToolkit/Core/Grid/BP_GridActor.BP_GridActor_C:UserConstructionScriptā€™!
LogScript: Warning: Accessed None trying to read property GridManagerRef

Do you understand why this is happening ?

thanks in advance
leo

Yes, this indeed made entirely in blueprints. You need not worry about performance, as this is something Iā€™ve prioritized heavily. For real time games with a lot of stuff going on using C++ will certainly give you a nice performance boost. However, turn-based games have the benefit of limiting the amount of stuff you need to calculate simultaneously, which makes it a great fit for blueprints.

If you want to work in the way Epic recommends, with a combination of C++ and blueprints, then this toolkit should be a good fit. However, if you want to work purely in C++ and donā€™t plan to touch blueprints at all, I think it could be annoying to work with. It is possible to call blueprint functions in C++, but I know that some other things are more difficult. Accessing blueprint created structs in C++, for instance, is quite awkward.

I cannot be certain, since I personally use a combination of both C++ and blueprints in my own projects, and there might be other difficulties I would have ran into if I used C++ which Iā€™m not aware of. There might also be easy workarounds for some of the perceived difficulties, but I cannot give you a definitive answer.

Hmm, Iā€™m guessing one of the grid actors is trying to access the grid manager, game state or another singleton blueprint and failing. It is very likely a warning that does not have any consequence, as Iā€™ve built the blueprints to keep searching before proceeding if they do not find an essential blueprint. The warning should still not be there, of course. I have not been able to reproduce the warning, so are you able to give me the repro steps? The warning says that the GetAllActorsOfClass node in the construction script of BP_GridActor returns null, and the only such node in BP_GridActor is the one that tries to find the grid manager. Have you placed a blueprint of type BP_GridActor (this includes units and tiles) before placing the grid manager? This would have given a warning.

Thanks, one more quick question:

>Levels can be built directly in the UE4 viewport, either through drag and drop or by having the toolkit automatically generate a walkability grid on top of any terrain

Does this include landscape, as well as imported terrain from say blender or something like that?

hi

I didnā€™t place bp_gridactor before placing the grid manager. I modify the stealth componenet and then its begin to show the warning. when I save the project, exit unreal and then fire the project again its all good - no warning. puzzle me why its doing this, like after the modify the grid actor in the ConstructionScrip no doing the ref to the gridmanager.

If you can understand why this happens, I would be happy to know, anyway, thanks for the quick assistance as usual.

cheers
leo

Yep, works with basically anything. Iā€™ve made it so that line traces are traced from the sky down to the ground in the center of every grid tile. Whatever is hit that blocks the custom PathTrace collision channel is added as a potential walkable tile. After that height differences between these trace hits are compared to calculate walkability, in a way that is fully customizable. As long as you set up the collision to block PathTrace you can use landscapes, meshes from blender or whatever else you want.

Hmm, seems like a bit of a corner case, but Iā€™ll look into it. Like I said, I seriously doubt this will affect the game in any way, but it is best practice to remove all warning messages. All that is likely needed is an isValid check after the GetAllActorsOfClass node.

hi

The current problem continues even after I exit the editor and fire again - restarts. I tried to put ā€œis validā€ after GetAllActorsOfClass[FONT=Helvetica,Arial,Verdana,sans-serif] node - didnā€™t help.
I also tried with a new project I created and there (without any change of mine) log gives the same warnings

if you want to see it happening just create a new project and every time you compile the bp_gridactor blueprint you will get lot of warning (same as I worte before).
I do not know the reason for this, but it is even worse when trying to modify some blueprints.

Sorry for the headache :slight_smile:

cheers
leo

Hey !
whats the best way to do cinematics using the ATBTT units?
I tried to move them around in sequencer and encountered some issues.
Do you have experience with ATBTT cinematics which you could share?

Thanks! :slight_smile:

No worries. I try to hunt down and remove any warning messages, so it is great that you gave me the repro steps for this. Checking for validity was not the correct thing to do in BP_GridActor, where one should rather check whether the array of BP_GridManager actors has a size of one. For the child actors of BP_GridActors we can just check if the GridManager reference is valid, however. Like so:


Iā€™ve added this to my WIP branch, so it will be fixed in the next update. These are not warnings that should have any effect on gameplay.

Hmm, not sure. I have not really worked with cinematics in UE4 at all. You can create actions for the action queue and set them to play ā€œWithPreviousā€ to create some cinematic-like stuff, but I have not really tested this out. I imagine the easiest would be to create cinematics using sequencer the old-fashioned way and not use any toolkit-specific stuff for it other than passing tile locations. What specific issues did you encounter?

hi

thanks a lot for the fix.

I understood that this was not a warning that would be a problem with gameplay, but I have a ā€œdiseaseā€ that I can not see these warnings and not understand what they originate from. So many thanks

cheers
leo

To be able to explain better what exactly happens I recreated the bug quick. So when doing any kind of transform animation in the sequencer, the unit gets kind of teleported at begin play to a far spot. There the sequence then plays.
And then I had the idea to delay the ATBTT init process. Since my cinematic has to be a kind of opening sequence on begin play, this would be a solution.
I added a delay of a few seconds (enough for my cinematic) to the BP_ATBTT right after the Begin play event. So it delays all the init stuff.
Basically this works great, the cinematic is playing and all looks good. The project is a vr project btw.
The issue is now after the cinematic is done, the init seems to happen and everything looks fine, but I cant do any button input at all for some reason.

Is there happening some stuff in the atbtt init which could lead to something like that?
Maybe like some logic which handles posessing the unit and this then fails due to bad timing in my delayed case?

Hello ,

I have added abilities to my game that change the height of tiles during gameplay and it has become apparent I need to update the heightmap and tile locations each time my abilities change the height of a tile.
What would be the best way to handle this?

Kind Regard,
Drewbie.

A very healthy disease to have, I would say :slight_smile:

Hmm, hard to know exactly what might be causing it. Last I checked delaying startup should work fine. I will look into it when I have the time.

The location of each tile is (including its height) is contained in the GridLocations TMap in BP_GridManager. If you Add a vector to that array using the appropriate GridIndex you will update the location of that tile. If all you want to change is the height and not change the connections between tiles it is as simple as that. If you want this to affect walkability it becomes a bit more complicated, as you also have to alter the GridEdges array, which is a bit more finicky. Could you explain the desired result in a bit more detail so I know precisely how you want it to work in game?

That helps a great deal for the initial problem.
A character will have an ability to raise or lower a tile a maximum of three height increments or ā€œlevelsā€. The cost of walking to a tile would change depending on the difference in the ā€œlevelsā€ between the tiles. So, I would need to alter the edge costs. Could you shed some light on how that would be implemented?
I just need a function which updates the edge costs of a tile and itā€™s neighbours.

Many thanks.

No worries :slight_smile: For modifying tile connections (edges) it so happens that I helped another developer with this not so long ago. Here is a link to the start of our conversation (it continues over a couple of pages). See if reading that helps you add the feature you want. If not get back to me and Iā€™ll help you along.

In other news I had some fun experimenting with changing the move animation based on properties of the grid. In the gif below the unit jumps if there is a height difference between tiles on the move path over a certain threshold. Also it crouches if it finds a custom blueprint (the blue frames) in the GridObjects TMap. Early experimentation, but it looks promising:

https://media.giphy.com/media/EQ6sZo84wJX09Y5YjV/giphy.gif

In other news I had some fun experimenting with changing the move animation based on properties of the grid. In the gif below the unit jumps if there is a height difference between tiles on the move path over a certain threshold. Also it crouches if it finds a custom blueprint (the blue frames) in the GridObjects TMap. Early experimentation, but it looks promising:

Thatā€™s awesome , just what I need !!
I am now working on something similar and having difficulty implementing it.
Iā€™ll wait patiently until itā€™s ready :slight_smile:

Your suggestion worked well, although with a bug.
The tile gets raised and all the location variables are correct, but the movement decals are floating above the tiles. Also, when the units move it moves along this floating path when moving across raised tiles.

On reading your conversation with Studder, you sent him the project with the fixes for this issue. Could you screenshot the fix for me please?

Untitled1.png

Have you got a fix for me?

Regards,
Drewbie.

Be warned that I can take quite a while before something like this is added in an update. If you want to try it yourself it basically boils down to having the movement to each tile be a separate action. In SimulateMove, I add an ActionQueue for each move step instead of queuing the single, large move action. For each step in SimulateMove I check whatever properties of the grid I want for the tile that is being exited and the one being entered and use that to choose the specific move step action and/or input variables to modify the movement.

Seems the issue here is that you are setting the height change in the GridLocations TMap to twice the height of what you are moving the tile meshes. Check your code and see if there is any reason why it would be doubled for one or halved for the other. Are you running anything twice by accident, perhaps?