Table of Contents

Struct ResourceChangedEvent

Namespace
Core.Resources
Assembly
Core.dll

ENGINE: Event fired when a resource amount changes for a country. Subscribe via EventBus for reactive UI updates.

public struct ResourceChangedEvent : IGameEvent
Implements

Fields

CountryId

The country whose resource changed

public ushort CountryId

Field Value

ushort

NewAmount

New amount

public FixedPoint64 NewAmount

Field Value

FixedPoint64

OldAmount

Previous amount

public FixedPoint64 OldAmount

Field Value

FixedPoint64

ResourceId

The resource type that changed

public ushort ResourceId

Field Value

ushort

Properties

Delta

The difference (NewAmount - OldAmount)

public FixedPoint64 Delta { get; }

Property Value

FixedPoint64

IsDecrease

True if resource decreased

public bool IsDecrease { get; }

Property Value

bool

IsIncrease

True if resource increased

public bool IsIncrease { get; }

Property Value

bool

TimeStamp

Event timestamp (auto-set by EventBus)

public float TimeStamp { readonly get; set; }

Property Value

float