Table of Contents

Class DeadEntityException

Namespace
ElectricDrill.AstraHealth.Exceptions
Assembly
com.electricdrill.astra-health.Runtime.dll

Exception thrown when attempting to perform health-modifying operations on a dead entity. This exception indicates a programming error where the caller attempted to heal, damage, or otherwise modify the health of an entity that has already died.

public class DeadEntityException : InvalidOperationException
Inheritance
object
Exception
SystemException
InvalidOperationException
DeadEntityException

Constructors

DeadEntityException(string, long, long, string)

Initializes a new instance of the DeadEntityException class.

public DeadEntityException(string entityName, long currentHp, long deathThreshold, string attemptedOperation)

Parameters

entityName string

The name of the dead entity.

currentHp long

The current health points of the entity.

deathThreshold long

The death threshold value.

attemptedOperation string

The operation that was attempted.

Properties

AttemptedOperation

Gets the operation that was attempted on the dead entity.

public string AttemptedOperation { get; }

Property Value

string

CurrentHp

Gets the current health points of the dead entity.

public long CurrentHp { get; }

Property Value

long

DeathThreshold

Gets the death threshold of the entity (health value at or below which the entity is considered dead).

public long DeathThreshold { get; }

Property Value

long

EntityName

Gets the name of the entity that was dead when the operation was attempted.

public string EntityName { get; }

Property Value

string