[SUPPORT] Advanced Turn Based Tile Toolkit

I apologize again for taking a while to reply. As mentioned I’m checking the thread and my e-mails somewhat less often while on vacation as I’ve filled up most days with activities. I’ll be living on a boat for some days next week and I’m uncertain if I will be able to check the thread at all during that time, but feel free to post questions and I’ll try to answer them as soon as I’m able.

Great that you managed to solve the problem yourself :slight_smile: I hope it didn’t take too long to figure out.

Cooleyo has linked to the correct video in his comment above (thanks!). In it I cover how to make area attacks with friendly fire. I’m uncertain if you’ll be able to simply input negative damage in the receive damage event in Unit_Parent to heal, but it should be trivial to modify the code to accept this if it’s not the case. Even if it works you will probably want to add an if-statement that prevents unit from being healed beyond max health.

I think your solution sounds pretty reasonable, but it might be able to make it even simpler depending on what you’re after. Creating a switch that runs a different piece of code each time Attack Victim is called in Unit_Parent is useful if you want to input your custom attack and run all the code that usually leads up to a custom attack (like the unit moving to the victim before attacking). If so I’d use a switch like you suggest, but I’d use an Enum instead of an integer, so you can more easily distinguish between the different attacks by looking at your code. If however you want to add effects that can trigger instantaneously when you click whatever action button you have added you can simply have clicking the button trigger a piece of code directly, without going through a switch. This depends on what you’re after. I must admit that menus and buttons is one of those things I know very little of, as I haven’t used them in UE4 yet (I’m pretty specialized when it comes to my skills at the moment). I’m positive it’s very simple to set up, though, but I cannot check from where I am at the moment. I imagine you can look at any tutorial for UMG and you will learn how you can run a specific blueprint event or function by clicking on a button you have added. Then you’d simply need to change your enum variable and/or run your attack code.

No need to apologize. There’s a lot of stuff to figure out once you’re starting out and I’m happy to help. Currently the current pawn is whichever pawn is currently selected, which means that if you’re switching between active pawns there is no way to figure out what is the “real” current pawn (since there is no such concept in the toolkit). If you have a situation where a different pawn is selected, but another pawn is actually the real current pawn you’ll have to add that yourself. I would add a new variable of type Unit_Parent in ATBTT_GameMode (called real current pawn or something else) and set this up when the current pawn is set up/switched in the game mode, but not switch it in ATBTT_PlayerController when you switch between units by clicking on them (the part in the bottom right of the blueprint graph if I remember correctly) if this is what you’re trying to achieve.

Thanks! I’m looking forward to seeing what you’ll make. Feel free to ask me anything you’re unsure about in this thread, and I’ll try to answer as soon as I’m able (which will be quicker once I’m back from vacation at the end of this month).

Yeah, randomness shouldn’t be hard to do. It’s mostly just if-statements tied up to a random number in range which is again based on the value of some stat. Glad to hear you found it simple.

Ok, thanks for letting me know. That makes a lot more sense for me, as I thought it was odd for Firaxis to add such a fundamental change to the underlying grid system just to achieve a minor change on some maps. Rotated walls should be simple enough to do with the toolkit.