Max0Takumi Posted April 5, 2018 Share Posted April 5, 2018 Hey'a how's it goin'? I was wondering if anyone could help me with a custom perk i would like added to my Custom Character for DST. I would like to be able to have it so i don't lose sanity while going thru a wormhole. It's only a minor thing i know but I'd thought it'd be a nice little perk. Thanks! Link to comment Share on other sites More sharing options...
icantevenname Posted April 13, 2018 Share Posted April 13, 2018 I have a character who gets totally drained of sanity when jumping into wormholes. It may not be what you're looking for, but maybe you rework it to suit your needs. In the character's modmain, put AddPrefabPostInit( "wormhole", function(inst) if not GLOBAL.TheWorld.ismastersim then return end local onActivate_old = inst.components.teleporter.onActivate inst.components.teleporter.onActivate = function(inst, doer, ...) if doer.prefab == "(character)" then doer.components.sanity:SetPercent(0) end return onActivate_old(inst, doer, ...) 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