mood
Mood datum
Contains the logic for controlling a living mob's mood/
Vars | |
last_stat | Tracks the last mob stat, updates on change Used to stop processing SSmood |
---|---|
mob_parent | The parent (living) mob |
mood | The total combined value of all moodlets for the mob |
mood_events | List of mood events currently active on this datum |
mood_level | Used to track what stage of moodies they're on (-20 to 20) |
mood_modifier | Moodlet value modifier |
mood_screen_object | The screen object for the current mood level |
shown_mood | the total combined value of all visible moodlets for the mob |
Procs | |
add_mood_event | Adds a mood event to the mob |
clear_mood_event | Removes a mood event from the mob |
has_mood_of_category | Returns true if you already have a mood from a provided category. You may think to yourself, why am I trying to get a boolean from a component? Well, this system probably should not be a component. |
hud_click | Handles clicking on the mood HUD object |
modify_hud | Sets up the mood HUD object |
on_revive | Called when parent is ahealed. |
print_mood | Prints the users mood, sanity, and moodies to chat |
remove_temp_moods | Removes all temporary moods |
unmodify_hud | Removes the mood HUD object |
update_mood | Updates the mobs mood. Called after mood events have been added/removed. |
update_mood_icon | Updates the mob's mood icon |
update_nutrition_moodlets | Handles mood given by nutrition |
Var Details
last_stat
Tracks the last mob stat, updates on change Used to stop processing SSmood
mob_parent
The parent (living) mob
mood
The total combined value of all moodlets for the mob
mood_events
List of mood events currently active on this datum
mood_level
Used to track what stage of moodies they're on (-20 to 20)
mood_modifier
Moodlet value modifier
mood_screen_object
The screen object for the current mood level
shown_mood
the total combined value of all visible moodlets for the mob
Proc Details
add_mood_event
Adds a mood event to the mob
Arguments:
- category - (text) category of the mood event - see /datum/mood_event for category explanation
- type - (path) any /datum/mood_event
clear_mood_event
Removes a mood event from the mob
Arguments:
- category - (Text) Removes the mood event with the given category
has_mood_of_category
Returns true if you already have a mood from a provided category. You may think to yourself, why am I trying to get a boolean from a component? Well, this system probably should not be a component.
Arguments
- category - Mood category to validate against.
hud_click
Handles clicking on the mood HUD object
modify_hud
Sets up the mood HUD object
on_revive
Called when parent is ahealed.
print_mood
Prints the users mood, sanity, and moodies to chat
remove_temp_moods
Removes all temporary moods
unmodify_hud
Removes the mood HUD object
update_mood
Updates the mobs mood. Called after mood events have been added/removed.
update_mood_icon
Updates the mob's mood icon
update_nutrition_moodlets
Handles mood given by nutrition