Jump to content

Recommended Posts

Hi! I'm very new to the world of Don't Starve modding and lua, and I was wondering if I could get some help?

 

I'm trying to make a character whose sanity benefits from evergreen trees. Either restoring sanity gradually from being around the trees(similar to how Willow would gain sanity from being around fire), or obtaining a small amount of sanity from chopping trees down(around the same amount as one would get from pocking a flower).

 

I've tried altering Willow's sanity code for fire in her prefabs, but I'm not sure if I've done it correctly, as it's just resulted in the game crashing and/or nothing happening. Is there any way I could get some help?

 

Thanks!

@chizuu

If the game crashes, u should look in your logfile why it crashed.(C:\Users\youruser\Documents\Klei\DoNotStarve\log.txt).

u can also add print()-statements to the code to output values at differnet points of the code, so u can find out why it doesnt happen the way u want.

both of these things are in any luatutorials in here, which leads me to believe u didnt read any of them :/

u can also post the code here if u want us to have a look at it.

use spoilertags

--lot of code

Hello and welcome to the modding community of Don't Starve. If you haven't had any coding experiences before, prepare for after hours. Nah, just kidding :p

 

Willow is very complicated, don't use her stuff. If you have the RoG DLC, look at wathgirthr. There's also a mod character or two which have similiar perks.

 

I recommend to try to understand basic Lua statements first, followed by the pine cone prefab, and maybe this or that inbetween.

 

u can also post the code here if u want us to have a look at it.
use spoilertags


--lot of code

 

You make spoiler tags like the following, but without spaces:

[ spoiler] This could be your advertisement space! [ /spoiler ]

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...