Jump to content

DST Custom Character coding HELP

Recommended Posts

So I wanted to make a custom character in DST but there is a part of the idea that I don't know how to code and couldn't find any tutorials about it, I would really appreciate if someone could help me out

I was originally thinking of a character that could resurrect after death yet every time after resurrection the maximum sanity will decline 25 (Originally starts off with 150 sanity). I think I could handle other part of the idea except for this part that I absolutely have no clue how to code. It would be better if the coding includes that he leaves no skeleton but two nightmare fuels when he dies but I suppose this part could be optional...

Could anyone help me with this??


Link to comment
Share on other sites

inst:ListenForEvent("respawnfromghost", function_name)
--this should check for when you respanwed

This will run a function every time you resurrected from a ghost

inst.components.sanity:AddSanityPenalty(reason, percent_amount)
--reason is used to identify the reason when removing later

--reason is given and then removed

these are the function and a basic description of how it works

Edited by thomas4846
maybe clarify a thing
  • Like 1
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...