Barotrauma Client
Loading...
Searching...
No Matches
Barotrauma.PetBehavior Class Reference

Public Types

enum  StatusIndicatorType { None , Happy , Sad , Hungry }
 

Public Member Functions

 PetBehavior (XElement element, EnemyAIController aiController)
 
StatusIndicatorType GetCurrentStatusIndicatorType ()
 
bool OnEat (Item item)
 
bool OnEat (Character character)
 
bool OnEat (Identifier tag)
 
void Play (Character player)
 
string GetTagName ()
 
void Update (float deltaTime)
 

Static Public Member Functions

static void SavePets (XElement petsElement)
 
static void LoadPets (XElement petsElement)
 

Properties

float Hunger [get, set]
 
float Happiness [get, set]
 
float UnhappyThreshold [get, set]
 At which point is the pet considered "unhappy" (playing unhappy sounds and showing the icon)
 
float HappyThreshold [get, set]
 At which point is the pet considered "happy" (playing happy sounds and showing the icon)
 
float MaxHappiness [get, set]
 
float HungryThreshold [get, set]
 At which point is the pet considered "hungry" (playing unhappy sounds and showing the icon)
 
float MaxHunger [get, set]
 
float HappinessDecreaseRate [get, set]
 
float HungerIncreaseRate [get, set]
 
float PlayForce [get, set]
 
float PlayTimer [get, set]
 
EnemyAIController AIController = null [get]
 
Character Owner [get, set]
 

Member Enumeration Documentation

◆ StatusIndicatorType

Enumerator
None 
Happy 
Sad 
Hungry 

Constructor & Destructor Documentation

◆ PetBehavior()

Barotrauma.PetBehavior.PetBehavior ( XElement element,
EnemyAIController aiController )

Member Function Documentation

◆ GetCurrentStatusIndicatorType()

StatusIndicatorType Barotrauma.PetBehavior.GetCurrentStatusIndicatorType ( )

◆ GetTagName()

string Barotrauma.PetBehavior.GetTagName ( )

◆ LoadPets()

static void Barotrauma.PetBehavior.LoadPets ( XElement petsElement)
static

◆ OnEat() [1/3]

bool Barotrauma.PetBehavior.OnEat ( Character character)

◆ OnEat() [2/3]

bool Barotrauma.PetBehavior.OnEat ( Identifier tag)

◆ OnEat() [3/3]

bool Barotrauma.PetBehavior.OnEat ( Item item)

◆ Play()

void Barotrauma.PetBehavior.Play ( Character player)

◆ SavePets()

static void Barotrauma.PetBehavior.SavePets ( XElement petsElement)
static

◆ Update()

void Barotrauma.PetBehavior.Update ( float deltaTime)

Property Documentation

◆ AIController

EnemyAIController Barotrauma.PetBehavior.AIController = null
get

◆ Happiness

float Barotrauma.PetBehavior.Happiness
getset

◆ HappinessDecreaseRate

float Barotrauma.PetBehavior.HappinessDecreaseRate
getset

◆ HappyThreshold

float Barotrauma.PetBehavior.HappyThreshold
getset

At which point is the pet considered "happy" (playing happy sounds and showing the icon)

◆ Hunger

float Barotrauma.PetBehavior.Hunger
getset

◆ HungerIncreaseRate

float Barotrauma.PetBehavior.HungerIncreaseRate
getset

◆ HungryThreshold

float Barotrauma.PetBehavior.HungryThreshold
getset

At which point is the pet considered "hungry" (playing unhappy sounds and showing the icon)

◆ MaxHappiness

float Barotrauma.PetBehavior.MaxHappiness
getset

◆ MaxHunger

float Barotrauma.PetBehavior.MaxHunger
getset

◆ Owner

Character Barotrauma.PetBehavior.Owner
getset

◆ PlayForce

float Barotrauma.PetBehavior.PlayForce
getset

◆ PlayTimer

float Barotrauma.PetBehavior.PlayTimer
getset

◆ UnhappyThreshold

float Barotrauma.PetBehavior.UnhappyThreshold
getset

At which point is the pet considered "unhappy" (playing unhappy sounds and showing the icon)


The documentation for this class was generated from the following file: