Jump to content

Damaging Player Health


Recommended Posts

So I want player to suffer some damage. I checked CK wiki and seems that things have changed. GetActorvalue not supported after version 1.5.

here's what I have scripted so far and how do I add player damage to health in this script please?

 

Explosion Property MyBang Auto
Actor Property PlayerREF Auto
Actor Property MyActor Auto
Message Property MyMSG Auto

Event OnHit(ObjectReference akAggressor, Form akSource, Projectile akProjectile, bool abPowerAttack, bool abSneakAttack, bool abBashAttack, bool abHitBlocked)

if (akAggressor == Game.GetPlayer())
MyActor.placeAtMe(MyBang)
MyActor.Kill()
PlayerREF.Kill()
MyMSG.show()

endif
EndEvent

 

Link to comment
Share on other sites

O_o what do you mean it's not supported? All the GetActor functions are valid. You just can't use health as a condition to check in the condition system, due to a never-fixed CK bug. Use it in your script.

 

Also make sure you are using the right wiki and not looking at Fallout 4 functions where things have changed dramatically in papyrus(It is now GetValue).

Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...