Eusong Posted May 7, 2018 Share Posted May 7, 2018 I was wondering where the code for the mind control debuff is stored? I'm going to use it for...something. >u> Any help is appreciated. Link to comment Share on other sites More sharing options...
ksaab Posted May 7, 2018 Share Posted May 7, 2018 scripts/prefabs/mindcontroller.lua Link to comment Share on other sites More sharing options...
Eusong Posted May 7, 2018 Author Share Posted May 7, 2018 Thank you! You wouldn't happen to know how to extend the effect, would you? Everything I've tried fails. Link to comment Share on other sites More sharing options...
ksaab Posted May 7, 2018 Share Posted May 7, 2018 (edited) Debuff works only when it is pushed to the player entity very often: function CustomMkDisable(player) if player._customMkTask ~= nil then player._customMkTask:Cancel() player._customMkTask = nil end end function CustomMkEnable(player) if not player:HasTag("player") or player:HasTag("playerghost") or player._customMkTask ~= nil then return end player._customMkTask = player:DoPeriodicTask(0.25, function(inst) inst.components.debuffable:AddDebuff("mindcontroller", "mindcontroller") end) end Edited May 7, 2018 by ksaab Link to comment 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