Overriding functions in blueprints is a bit weird like that. You’ll notice that quite a few of my functions have a boolean output variable called bSuccess that isn’t really used. This is mainly so that child blueprints overriding this function will have it overridden as a function and not an event.
If you’re basing your abilities on BP_Ability_Laser the AI value calculation is largely based around hit percent chances. It loops through all tiles in move range and checks the hit chance to hit various enemies from each tile, as well as the chance of being hit from those units at each tile. You can add your hit chance modification into that code as well. The simplest way to do this is to modify the FindAbilitySpecificTileValueModifier function of Laser. Something like this should do the trick:
I’m assuming you’re basing the abilities of your units off BP_Ability_MoveAttack. The code for switching to another unit for this ability is held in the DefaultClick function of BP_Ability. You need to add a check here that prevents you from switching units if the current unit has already acted (which in the default toolkit means that it has less than its max AP). This should work:
Yep, I know updated videos are sorely needed. I’m planning to start working on that next weekend. The code for destroying units is a bit weird in the toolkit, and it is because of the action system and multiplayer. You don’t want to destroy a unit actor as part of the server side code, because all that stuff happens instantly, before animations are run. The units cannot be destroyed before all their animations have finished running. However, the unit still needs to be dead as far as the game logic is concerned, so it is removed from the GridUnits and InitiativeOrder arrays/maps (The RemoveUnitFromGame function).
Also, if the game is multiplayer we cannot simply destroy the unit immediately after the death animation is done playing on the server, as the clients might lag behind due to poor connections. Because of this a special action is called using the action system (called QueueDestroy). This action is run by the action manager, setting a life span to destroy the actor. This is by default set to 30 seconds, which should prevent issues for anything but the most extreme network issues. I’m not that happy with this hardcoded timer, though, and am currently working on a more flexible and intelligent solution to this particular problem.
Anyways, for your particular unit this means that you need to add functionality that hides it after it is killed, from the reference point of the client, but is still not destroyed, from the game logic’s point of view. Check out BP_Unit_Anim and the AnimateDeath event where the health bar is hidden. You want to hide the unit mesh here as well.