personality 
Personality Singleton
Contains information about a personaility.
A personality is designed to be a small modifier to the way a mob reacts to moodlets or world events.
For example, a mob with the Callous personality would not receive a positive moodlet for saving someone's life.
They're not meant to be full blown quirks that hold state and such. If you NEED state, consider making a quirk, or moving your behavior into a component the personality applies.
Vars | |
desc | Required: Description of the personality. Phrased to be "In character" - i.e. "I like to help people!" Rather than OOC 0 i.e. "When helping people, I get a positive moodlet." |
---|---|
groups | What groups does this personality belong to? Personalities in the same group are mutually exclusive. |
name | Required: Name of the personality |
neg_gameplay_desc | Optional: Short blurb on what negative effects this personality has on gameplay, for ui |
neut_gameplay_desc | Optional: Short blurb on what neutral effects this personality has on gameplay, for ui |
personality_trait | Easy way to apply a trait as a part of a personality. |
pos_gameplay_desc | Optional: Short blurb on what positive effects this personality has on gameplay, for ui |
processes | Does this personality need to process every tick? If true, you'll need to override on_tick() with logic |
savefile_key | Required: The key to use when saving this personality to a savefile. Don't change it once it's set unless you want to write migration code |
Procs | |
apply_to_mob | Called when applying this personality to a mob. |
on_tick | Called every SSpersonality tick if processes is TRUE.
Don't call parent if you override this, that's for error checking |
remove_from_mob | Called when removing this personality from a mob. |
Var Details
desc 
Required: Description of the personality. Phrased to be "In character" - i.e. "I like to help people!" Rather than OOC 0 i.e. "When helping people, I get a positive moodlet."
groups 
What groups does this personality belong to? Personalities in the same group are mutually exclusive.
name 
Required: Name of the personality
neg_gameplay_desc 
Optional: Short blurb on what negative effects this personality has on gameplay, for ui
neut_gameplay_desc 
Optional: Short blurb on what neutral effects this personality has on gameplay, for ui
personality_trait 
Easy way to apply a trait as a part of a personality.
pos_gameplay_desc 
Optional: Short blurb on what positive effects this personality has on gameplay, for ui
processes 
Does this personality need to process every tick? If true, you'll need to override on_tick() with logic
savefile_key 
Required: The key to use when saving this personality to a savefile. Don't change it once it's set unless you want to write migration code
Proc Details
apply_to_mob
Called when applying this personality to a mob.
- who - The mob to apply this personality to.
This mob is asserted to have
mob_mood
.
on_tick
Called every SSpersonality tick if processes
is TRUE.
Don't call parent if you override this, that's for error checking
remove_from_mob
Called when removing this personality from a mob.
This is not called as a part of the mob being deleted.
- who - The mob to remove this personality from.
This mob is asserted to have
mob_mood
.