Scriptname SuH_spellES_vitaldrain_hate extends activemagiceffect  

actor property PlayerRef auto

Event OnEffectStart(actor akTarget, actor akCaster)
	float h = akCaster.GetActorValue("health")
	float m = akCaster.GetActorValue("magicka")
	float s = akCaster.GetActorValue("Stamina")
	int xh = Math.Floor(h*0.25)
	int xm = Math.Floor(m*0.25)
	int xs = Math.Floor(s*0.25)
	int pow = Math.Floor((xh + xm + xs)*0.8)
	akTarget.DamageActorValue("health", pow)
	akCaster.DamageActorValue("health", xh)
	akCaster.DamageActorValue("Magicka", xm)
	akCaster.DamageActorValue("Stamina", xs)
endEvent