amusapik Posted July 15, 2010 Share Posted July 15, 2010 Scn CriticalHit Short RandomPercentShort SkillVarRef MeFloat LuckSkillFloat BladeSkill Begin ScriptEffectStart If isEssential == 0 Set RandomPercent to getRandomPercent Set LuckSkill to player.getActorValue Luck Set BladeSkill to player.getActorValue Blade Set SkillVar to (LuckSkill + BladeSkill) * 0.025 If SkillVar < 1 Set SkillVar to 1 Endif If RandomPercent <= SkillVar Message "Critical Hit" ;Set Me to getself ;your functions (eg. Player.Pushactoraway Me 100) Endif EndifEnd What do i need to do to get this code to work? Link to comment Share on other sites More sharing options...
amusapik Posted July 17, 2010 Author Share Posted July 17, 2010 Scn CriticalHit Short RandomPercentShort SkillVarRef MeFloat LuckSkillFloat BladeSkill Begin ScriptEffectStart If isEssential == 0 Set RandomPercent to getRandomPercent Set LuckSkill to player.getActorValue Luck Set BladeSkill to player.getActorValue Blade Set SkillVar to (LuckSkill + BladeSkill) * 0.025 If SkillVar < 1 Set SkillVar to 1 Endif If RandomPercent <= SkillVar Message "Critical Hit" ;Set Me to getself ;your functions (eg. Player.Pushactoraway Me 100) Endif EndifEnd What do i need to do to get this code to work?Id like for the "your function" to be an actuall damage increase modifyer based on weapon skill and luck. something liketha damage bonus when in stealth mode.any ideas? Link to comment Share on other sites More sharing options...
Recommended Posts