TheKittensEcho Posted March 31, 2022 Share Posted March 31, 2022 Would anyone know exactly how one would go about making a modded character receive reduced damage from Charlie? Or at the very least if there's some sort of mod which had something similar to this I could look through? I genuinely haven't been able to find anything that references her damage aside from Negating it entirely. Link to comment https://forums.kleientertainment.com/forums/topic/138765-perk-help-for-reducing-charlies-damage/ Share on other sites More sharing options...
Monti18 Posted April 1, 2022 Share Posted April 1, 2022 There is no easy way to change it directly. If you add this to the master postinit of your character prefab, it should work: Spoiler if inst.components.combat then local old_GetAttacked = inst.components.combat.GetAttacked inst.components.combat.GetAttacked = function(self,attacker, damage, weapon, stimuli,...) if stimuli == "darkness" then damage = damage * 0.5 --half of damage, change it to what you want end return old_GetAttacked(self,attacker, damage, weapon, stimuli,...) end end Link to comment https://forums.kleientertainment.com/forums/topic/138765-perk-help-for-reducing-charlies-damage/#findComment-1554385 Share on other sites More sharing options...
TheKittensEcho Posted April 2, 2022 Author Share Posted April 2, 2022 Thanks, for the Code! This will really help with the Mod I'm working on! Link to comment https://forums.kleientertainment.com/forums/topic/138765-perk-help-for-reducing-charlies-damage/#findComment-1554661 Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now