5391 downloadsThis is the mod of Wunk, a custom character made by Vivalavie and Inward. Compatible with or without the Reign of Giants DLC. Wunk is a punk addicted to drugs. - His movement speed and attack speed increase when his sanity decreases, but he's slowed when he has a good rate of sanity. - He slowly loses health when his sanity is too low. - He can craft a peace pipe and a hell pipe, to smoke and gain health points, but his hunger and sanity decrease. - He has a new stat : his rate of drug. Wunk needs to smoke regularly, else he loses his speed powers. But a monster will spawn if his rate of drug is too high ! Eating raw mushrooms also increases this rate. Wunk also has : - Custom speech - Custom sounds - His look changes when he starts to be crazy Stats : Hunger : 150 Sanity : 125 Health : 150
Thanks for your answers ^^ I already created a custom component to make my character lose health. There is an Update(dt) function that checks if the conditions are valid or not and if they are, I use the health:DoDelta function. It works well but the badge on the interface isn't actualized (I mean we don't see the down arrow which indicates to the player that he's actually losing health). That's why I had to rewrite the healthbadge file. And about the shadow creatures I took a look at Elinor and the creator creates completely another spawner file, so I guess it's the best way to do it.
Hi modders, I have a problem for a while now I didn't find how to solve it yet. I hope no one asked for that on the forum because I searched for a solution for a long time. I would like to rewrite an Update function : my mod is a custom character and some things in the world are different for him. I would like to create my own shadow creatures and make them spawn only while playing him. I took a look at sanitymonsterspawner.lua and that's the SanityMonsterSpawner:UpdateMonsters(dt) that I would like to change (I need to change the chances to spawn and the prefabs to spawn). Same problem for the healthbadge.lua because he loses health from another thing and I need to update the badge when he's losing health (there's another condition for him, in addition with starving, freezing, overheating and on fire). The only solution I found is to rewrite the entire file in my mod folder and I detect if that's my character or not because there is not a SetUpdateFn(fn) function or something like that. But I guess that's not a good way to do it because it can create conflicts with other mods and with future updates, right ? Any suggestion, please ?