[SUPPORT] Advanced Turn Based Tile Toolkit

give me 5 min, i will write you back

hi knut

just open the jungle raid map, on every unit press the end turn button, it will never go to the ai(enemy) faction(the end turn button just act like swap to next unit). its not a big problem- and maybe you meant it to be like that.

p.s - my wife think i have a secret affair on the internet :slight_smile:

Ah, I see. That is intentional. The Jungle Raid map includes the Stealth Component with the enemy faction set to unaware at startup. This means that they will not act until they are made aware, by the player either moving into their line of sight or making noise close by. If you want to disable this, select the grid manager and find the Stealth component. Remove the enemy faction from the unaware factions list.

(my wife is asleep. I won’t tell her if you don’t tell yours)

oh…, sorry knut forgot about the stealth component, hope i didn’t waste too much of your time on this.

No worries. I did not spend more than a few minutes on this. Even though it was intentional it is useful to know that this is not transmitted clearly enough to the developer.

Programmer noob here, trying to implement xcom-style cameras to this kit. I downloaded the xcom 2 developer tools and was looking around in their camera scripts, found the OverTheShoulder script, but was confused at the mention of Matinee in this:

// Over the shoulder cameras are a special variety of Matinee style camera
// that automatically adjust themselves to keep both the shooter and the target
// correctly framed in screen space, regardless of where they are on screen.
// They are authored as “shots” in matinee, where spheres are placed to
// represent where the shooter and target’s heads should be in frame. In game then,
// this camera will look at where the actual shooter and target’s heads are,
// and automatically rotate the camera location as needed to ensure that they appear
// in frame in exactly the same location as they did in matinee.

I was expecting to find some code and base myself on that logic to replicate it with blueprints for now, but the mention of Matinee as a core element in this threw me off. Do you guys know what’s the benefit of doing this with Matinee, if Ue4’s version of it even is oriented for this sort of work?

I really should take a look at the XCOM 2 developer tools at some point. As far as I know, XCOM 2 was made on a modified UE3. I have not done anything with Matinee myself, so I’m not sure what the best approach is in that regard. If I was to do something like what is described here based on what I know, I would probably use a separate camera actor (or attach a camera component to each unit), then place the camera behind the shoulder of the shooting unit and rotate it to face the target, Then maybe add some subtle movement or zoom with timelines to spice it up. But I’m sure you can do it better using Matinee, though I’m not experienced enough with it to tell you how.

hi justo

i think xcom used Matinee In order to achieve the effect of a dynamic camera (they said in one of the interview’ they wanted a movie affect), the effect creates an element like a camera in the film(cutscene) - the camera has dynamic movement or crane movement and you can not mimic this effect only with code, also camera animation and timeline alone will be very limited.
So the benefit of the Matinee, or rather the ability of the matinee is to bring the transition to the shoulder camera that will be seen as an action movie (note that in xcom the camera is not static and you have a fell of a movie)

What knut has written sounds a great idea - maybe will not bring the same result but definitely more simple i think.
Unfortunately, I did not try to connect Matinee to code in such a situation so I can not help you with that, sorry


Leo bar, thank you for the answer, that is very helpful!! I was under the impression that something like a camera’s transition from one point to the other was possible in blueprints, much like it is to move any object xyz units. Isn’t it just a matter of coding in the desired camera movements?

I guess it may not be that simple…Well, I guess I’ll look into how doing this via Matinee is possible. Thanks again, any and all comments on this are super appreciated.

hi justo

you can make a camera transition from one point to the other in blueprints, its possible. but i mean you cant get the same affect of movie camera, only with Matinee.

look a the little details(sometimes its hard to see in the beginning).

but what knut wrote above is actually, will give you some good result. give the camera desired movement and rotation in blueprint, and then add some shake, zoom ect with camera animation and timeline) so it will feel less mechanic(you want to get the feel like there is some human behind the camera, not a camera driven by code)

also i would use a cine camera actor
hope this will help you


[USER=“641905”]leo bar[/USER] : Thanks a lot for giving suggestions to @Justo. Matinee is not really something I’ve worked with, but I think it is best suited here. But if that doesn’t work, my solution using conventional blueprints should do the trick, though it will likely be more cumbersome to implement.

Just a heads up matinee has been deprecated last I checked use sequencer. It is allot easier to use.

Also what is coming in the next version of the toolkit?

Yeah, true. I meant sequencer. Shows how much I’ve used those features.

You can check out my Trello for a list of new features. This update mainly consists of refactoring parts of the toolkit in order to make it more performant and flexible, so there is not that much in the way of new features, except for experimental inclusions for custom move animations (teleporting, jumping etc. as part of movement) and an outline material for move range.

There are low level changes that mean that making certain types of modifications will be easier, however. The biggest one is that I’ve changed how grid indexes work so that instead of constraining the size of the grid to GridSizeX * GridSizeY I am basically saying that the grid always has a size of 1000*1000 tiles. This means that you can easily add new tile locations outside the bounds of the initial grid at runtime. Since I’m now using TMaps instead of arrays for all grid sized arrays this does not require me to have huge zero-filled arrays for this to work.

Other changes include changing multi-level grids so that the level of a particular tile corresponds predictable to the relative height compared to the grid manager, which simplifies some of the multi-level tile algorithms.

Also, hexagonal grids are now contained in their own child blueprint of BP_GridManager, overriding functions as appropriate instead of having a million banches in the various scripts in the grid manager. I’ve also changed the hexagonal grid math to convert back and forth from cube coordinates for several functions, making these simpler and more efficient.

Basically a lot of changes that do not change the basic functionality of the toolkit, but which makes it easier to modify in the future. If you have a heavily modified version of the toolkit already, converting to this version will be challenging and not really give you any new features out of the box, so unless you want to do something fancy with multi-level or huge, sparse grids you can quite safely stick with the earlier version. The UE4.20 version of the toolkit converts without issues to UE4.21.

“quote”“This means that you can easily add new tile locations outside the bounds of the initial grid at runtime.” I was wondering, will we be able to add new tiles at a different height as well?. I have been keeping an eye on trello…thank for all your hard work.

Indeed. That is one of the reasons I refactored the heightmap stuff at the same time.

My head is spinning…so much I could do with that…Thanks

Hi guys, could anyone enlighten me as to why do empty scenes spawn BP_ATBTT and the whole combo of blueprints like GridManager, GridCamera, etc? I tried unplugging the Activate ATBTT from the Event BeginPlay in BP_ATBTT too, but it’s all still spawning. Where in the project is it being stated to spawn it always, and is it necessary for everything to work?

Looking forward to seeing what you’ll do with it :slight_smile:

Hey, that would be because of the game mode selected in World Settings, which spawns all the actors chosen in the game mode’s defaults.

Thanks a lot for the link to the docs Monokkel, I’ll read it. Y O U R O C K

Happy to help :slight_smile: