Barotrauma Client Doc
Barotrauma.MonsterEvent Class Reference
Inheritance diagram for Barotrauma.MonsterEvent:
Barotrauma.Event

Public Member Functions

override string ToString ()
 
 MonsterEvent (EventPrefab prefab)
 
override IEnumerable< ContentFileGetFilesToPreload ()
 
override void Init (EventSet parentSet)
 
override string GetDebugInfo ()
 
override void Update (float deltaTime)
 
- Public Member Functions inherited from Barotrauma.Event
override string ToString ()
 
 Event (EventPrefab prefab)
 
virtual void Finish ()
 
virtual bool LevelMeetsRequirements ()
 

Public Attributes

readonly Identifier SpeciesName
 The name of the species to spawn More...
 
readonly int MinAmount
 Minimum amount of monsters to spawn. You can also use "Amount" if you want to spawn a fixed number of monsters. More...
 
readonly int MaxAmount
 Maximum amount of monsters to spawn. You can also use "Amount" if you want to spawn a fixed number of monsters. More...
 
readonly float SpawnDistance
 The monsters are spawned at least this distance away from the players and submarines. More...
 
readonly Level.PositionType SpawnPosType
 Where should the monster spawn? More...
 
readonly int MaxAmountPerLevel = int.MaxValue
 Maximum number of the specific type of monster in the entire level. Can be used to prevent the event from spawning more monsters if there's already enough of that type of monster, e.g. spawned by another event or by a mission. More...
 
- Public Attributes inherited from Barotrauma.Event
int RandomSeed
 
Func< Level.InterestingPosition, bool > SpawnPosFilter
 

Properties

IReadOnlyList< CharacterMonsters [get]
 
Vector2? SpawnPos [get]
 
bool SpawnPending [get]
 
override Vector2?? DebugDrawPos [get]
 
- Properties inherited from Barotrauma.Event
EventPrefab Prefab [get]
 
EventSet ParentSet [get]
 
bool IsFinished [get]
 
virtual Vector2 DebugDrawPos [get]
 

Additional Inherited Members

- Protected Attributes inherited from Barotrauma.Event
bool isFinished
 
readonly EventPrefab prefab
 
- Events inherited from Barotrauma.Event
Action Finished
 

Detailed Description

Definition at line 11 of file MonsterEvent.cs.

Constructor & Destructor Documentation

◆ MonsterEvent()

Barotrauma.MonsterEvent.MonsterEvent ( EventPrefab  prefab)

Definition at line 102 of file MonsterEvent.cs.

Member Function Documentation

◆ GetDebugInfo()

override string Barotrauma.MonsterEvent.GetDebugInfo ( )
virtual

Reimplemented from Barotrauma.Event.

Definition at line 217 of file MonsterEvent.cs.

◆ GetFilesToPreload()

override IEnumerable<ContentFile> Barotrauma.MonsterEvent.GetFilesToPreload ( )
virtual

Reimplemented from Barotrauma.Event.

Definition at line 161 of file MonsterEvent.cs.

◆ Init()

override void Barotrauma.MonsterEvent.Init ( EventSet  parentSet)
virtual

Reimplemented from Barotrauma.Event.

Definition at line 176 of file MonsterEvent.cs.

◆ ToString()

override string Barotrauma.MonsterEvent.ToString ( )

Definition at line 86 of file MonsterEvent.cs.

◆ Update()

override void Barotrauma.MonsterEvent.Update ( float  deltaTime)
virtual

Reimplemented from Barotrauma.Event.

Definition at line 443 of file MonsterEvent.cs.

Member Data Documentation

◆ MaxAmount

readonly int Barotrauma.MonsterEvent.MaxAmount

Maximum amount of monsters to spawn. You can also use "Amount" if you want to spawn a fixed number of monsters.

Definition at line 25 of file MonsterEvent.cs.

◆ MaxAmountPerLevel

readonly int Barotrauma.MonsterEvent.MaxAmountPerLevel = int.MaxValue

Maximum number of the specific type of monster in the entire level. Can be used to prevent the event from spawning more monsters if there's already enough of that type of monster, e.g. spawned by another event or by a mission.

Definition at line 75 of file MonsterEvent.cs.

◆ MinAmount

readonly int Barotrauma.MonsterEvent.MinAmount

Minimum amount of monsters to spawn. You can also use "Amount" if you want to spawn a fixed number of monsters.

Definition at line 21 of file MonsterEvent.cs.

◆ SpawnDistance

readonly float Barotrauma.MonsterEvent.SpawnDistance

The monsters are spawned at least this distance away from the players and submarines.

Definition at line 32 of file MonsterEvent.cs.

◆ SpawnPosType

readonly Level.PositionType Barotrauma.MonsterEvent.SpawnPosType

Where should the monster spawn?

Definition at line 62 of file MonsterEvent.cs.

◆ SpeciesName

readonly Identifier Barotrauma.MonsterEvent.SpeciesName

The name of the species to spawn

Definition at line 16 of file MonsterEvent.cs.

Property Documentation

◆ DebugDrawPos

override Vector2?? Barotrauma.MonsterEvent.DebugDrawPos
get

Definition at line 81 of file MonsterEvent.cs.

◆ Monsters

IReadOnlyList<Character> Barotrauma.MonsterEvent.Monsters
get

Definition at line 77 of file MonsterEvent.cs.

◆ SpawnPending

bool Barotrauma.MonsterEvent.SpawnPending
get

Definition at line 79 of file MonsterEvent.cs.

◆ SpawnPos

Vector2? Barotrauma.MonsterEvent.SpawnPos
get

Definition at line 78 of file MonsterEvent.cs.