Jump to content

Is it possible to create a character that makes nearby players passively lose sanity?

Recommended Posts

I'm really new to modding, as in I'm working on my first mod, a character for DST. I am wondering if there is a way to have a constant and passive area of effect around your character that makes others slowly lose sanity. This might sound undesirable, and it honestly is, but I think that it is a necessary attribute of the character I'm making.

Link to comment
Share on other sites

Put this in YOURCHARACTER.lua inside the master_postinit

inst.components.sanityaura.aura = -TUNING.SANITYAURA_LARGE

Instead of "LARGE" you can also use "TINY", "MED", "SMALL" or "HUGE".

If those don't meet your requirements you can also multiply one of them by a number for a stronger or weaker effect like so..

inst.components.sanityaura.aura = -TUNING.SANITYAURA_LARGE * 2 -- Double the effect's power

inst.components.sanityaura.aura = -TUNING.SANITYAURA_LARGE * .5 -- Halved the effect's power

Hope this helped you :D!

Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Create New...