Jump to content

Recommended Posts

I need help coding traits for my custom character.

I would like him to be able to:

1. As a sort of either or situation the player can make, have more movement speed if his health falls to 30 or below if he doesn't have a weapon wielded at the cost of sanity or if he has a weapon and can receive a damage boost when his health falls to 30 or below (with a small defense bonus if that's possible)

2. Do more damage to all boss monsters (not much more than normal, but just a bit more).

The main problem is that I don't know the coding for any of these traits.

Any help is appreciated.

I had made a post about this a long time ago. I looked over what replies were there, but I still don't understand what to do.

I'm not sure how to correctly conditionally trigger these traits, but to go faster you can paste this into your character's .lua


 inst.components.locomotor.walkspeed = 4
 inst.components.locomotor.runspeed = 6    (default values), change as needed

and for attack multiplier (although not specifically toward bosses)

inst.components.combat.damagemultiplier = 1    (change value as needed)

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