Scriptname aaaHitStopdisable extends ActiveMagicEffect  

Keyword property WeapTypeBow auto
Spell property aaaHitSlowTime auto
ImageSpaceModifier property aaaHitSlowTimeImod auto
GlobalVariable Property aaaHitStopPowAttackTime auto
GlobalVariable Property aaaHitStopTime auto
GlobalVariable Property aaaHitStopCamStr auto
GlobalVariable Property aaaHitStopBlurStr auto
GlobalVariable Property aaaHitStopContStr auto
Actor property player auto
float PowAttack

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

	if ( (akAggressor == player) && (akSource as Weapon) && (!player.IsInKillMove()) && !akSource.HasKeyword(WeapTypeBow) && !akProjectile)
	float Cont	= aaaHitStopContStr.GetValue()
	float Cam	= aaaHitStopCamStr.GetValue()
	float Blur 	= aaaHitStopBlurStr.GetValue()
	float Time	= aaaHitStopTime.GetValue()
	
	if(abPowerAttack==true)
		PowAttack = aaaHitStopPowAttackTime.GetValue()
	else
		PowAttack = 0
	endif			

		Game.ShakeController(Cont, Cont,0.25 + PowAttack)
		Game.ShakeCamera(None, Cam ,0.25 + PowAttack)
		aaaHitSlowTimeImod.Apply(Blur)
		if !(Time == 0)
			aaaHitSlowTime.Cast(player,player)
			Utility.Wait(Time + PowAttack)
			player.DispelSpell(aaaHitSlowTime)
		endif
	endif



EndEvent