rons0n Posted July 27, 2018 Share Posted July 27, 2018 One of my characters can give players sanity by doing emotes in general but I wanted it to be more specific this time. Specifically, the sitting emote and over time(like 5 sanity per second while sitting), how would I approach that? Much thanks to anyone who chimes in! Heres what I have initially: inst:ListenForEvent("emote", function(inst, data) if inst:HasTag("cheery") then inst.components.sanity:DoDelta(15) inst.components.hunger:DoDelta(-15) for k, v in pairs(AllPlayers) do if v ~= inst and v:IsNear(inst, 16) and v.components.sanity then v.components.sanity:DoDelta(15) end end end end) 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