PDA

View Full Version : IsUnderAttack



nenci494
12-29-2016, 07:10 PM
hello guys,
i just came back to scripting from a long break.
Done some smithing scripts and stuff to get into it again. Now im struggling with some stuff.
It seems i cant get MyPlayer.IsudnerAttack to work. i even tried copy pasting the script part from the tutorial but still the script doesnt seem to notice if my player is under attack or not. is it just me doing something wrong? or is there a trick :P
i would also be thankfull if there would be some kind of bypass if its broken or smth.
Couldnt find something about it on the forum so i'll give it a try.

thanks buds

P.S. sorry for my bad english :P
P.S.2: this is the error i get [Error] Avoided using null'd pointer at: TReflectActor.IsUnderAttack

anoobis
12-29-2016, 07:21 PM
You'll have to avoid the functions that use the following hooks until the reflection devs find time to update the class updater:

Actor_SpokenText: THook = ['NULL', 1];
Actor_CombatCycle: THook = ['NULL', 1];
Actor_Health: THook = ['NULL', 1];
Actor_MaxHealth: THook = ['NULL', 1];

nenci494
12-29-2016, 07:32 PM
Thanks for the fast answer. just made a simple little function which is looking if theres a hp bar over the localplayer. not really professional but working for now :D