跳到主要内容
版本:Next

Class SessionRespawn

Namespace: OblivionMp.Sdk.Serverside
Assembly: OblivionMp.Sdk.Serverside.dll

When the server refills a cell with the items, plants, container loot and spawns it was seeded with. A cell refills once IntervalGameHours of game time have passed since it was last filled.

public sealed class SessionRespawn

Inheritance​

object ← SessionRespawn

Inherited Members​

object.GetType(), object.ToString(), object.Equals(object?), object.Equals(object?, object?), object.ReferenceEquals(object?, object?), object.GetHashCode()

Remarks​

The interval is not saved, so a mod that changes it sets it again every time the server starts.

Constructors​

SessionRespawn()​

public SessionRespawn()

Fields​

DefaultIntervalGameHours​

The game's own interval, 72 game hours.

public const float DefaultIntervalGameHours = 72

Field Value​

float

Properties​

IntervalGameHours​

The game hours between two refills of a cell.

public float IntervalGameHours { get; }

Property Value​

float

Methods​

RespawnNow(Cell)​

Refills cell on the next server tick however much of its interval is left, and starts its interval again from then. A cell that has not been seeded yet is filled by its first seeding instead.

public void RespawnNow(Cell cell)

Parameters​

cell Cell

SetInterval(float)​

Sets the game hours between two refills of every cell.

public void SetInterval(float gameHours)

Parameters​

gameHours float