Table of Contents

Class CharacterEntity

Namespace
FishMMO.Database.Npgsql.Entities
Assembly
FishMMO-DB.dll

Database entity representing a player character.

public class CharacterEntity : IVersionedEntity
Inheritance
CharacterEntity
Implements
Inherited Members

Properties

Abilities

Navigation collection of character ability entries.

public ICollection<CharacterAbilityEntity> Abilities { get; set; }

Property Value

ICollection<CharacterAbilityEntity>

AccessLevel

Access level / permission tier for this character.

public byte AccessLevel { get; set; }

Property Value

byte

Account

Account name that owns this character.

public string Account { get; set; }

Property Value

string

Achievements

Navigation collection of character achievements.

public ICollection<CharacterAchievementEntity> Achievements { get; set; }

Property Value

ICollection<CharacterAchievementEntity>

Archetypes

Navigation collection of character archetype entries.

public ICollection<CharacterArchetypeEntity> Archetypes { get; set; }

Property Value

ICollection<CharacterArchetypeEntity>

Attributes

Navigation collection of character attribute entries.

public ICollection<CharacterAttributeEntity> Attributes { get; set; }

Property Value

ICollection<CharacterAttributeEntity>

BindScene

Bind point scene name.

public string BindScene { get; set; }

Property Value

string

BindX

Bind point world position X. Uses float for Unity Vector3 compatibility.

public float BindX { get; set; }

Property Value

float

BindY

Bind point world position Y.

public float BindY { get; set; }

Property Value

float

BindZ

Bind point world position Z.

public float BindZ { get; set; }

Property Value

float

Buffs

Navigation collection of active character buffs.

public ICollection<CharacterBuffEntity> Buffs { get; set; }

Property Value

ICollection<CharacterBuffEntity>

Deleted

Soft delete flag.

public bool Deleted { get; set; }

Property Value

bool

Faction

Navigation collection of character faction standings.

public ICollection<CharacterFactionEntity> Faction { get; set; }

Property Value

ICollection<CharacterFactionEntity>

Flags

Character flags bitmask (e.g. for status effects or customization flags).

public int Flags { get; set; }

Property Value

int

Friends

Navigation collection of character friend entries.

public ICollection<CharacterFriendEntity> Friends { get; set; }

Property Value

ICollection<CharacterFriendEntity>

Guild

Navigation reference to the guild membership record.

public CharacterGuildEntity Guild { get; set; }

Property Value

CharacterGuildEntity

ID

Primary key.

public long ID { get; set; }

Property Value

long

InstanceID

Instance ID of the current instance the character occupies (0 if over-world).

public long InstanceID { get; set; }

Property Value

long

InstanceRotW

Instance spawn rotation W component (quaternion).

public float InstanceRotW { get; set; }

Property Value

float

InstanceRotX

Instance spawn rotation X component.

public float InstanceRotX { get; set; }

Property Value

float

InstanceRotY

Instance spawn rotation Y component.

public float InstanceRotY { get; set; }

Property Value

float

InstanceRotZ

Instance spawn rotation Z component.

public float InstanceRotZ { get; set; }

Property Value

float

InstanceX

Instance spawn position X. Uses float for Unity Vector3 compatibility.

public float InstanceX { get; set; }

Property Value

float

InstanceY

Instance spawn position Y.

public float InstanceY { get; set; }

Property Value

float

InstanceZ

Instance spawn position Z.

public float InstanceZ { get; set; }

Property Value

float

ItemCooldowns

Navigation collection of character item cooldowns.

public ICollection<CharacterItemCooldownEntity> ItemCooldowns { get; set; }

Property Value

ICollection<CharacterItemCooldownEntity>

Items

Navigation collection of every item this character owns, across all containers.

public ICollection<CharacterItemEntity> Items { get; set; }

Property Value

ICollection<CharacterItemEntity>

Remarks

Replaces the separate Inventory, Equipment and Bank collections; the container an item sits in is now a column on the row rather than a choice of table.

KnownAbilities

Navigation collection of character known ability entries.

public ICollection<CharacterKnownAbilityEntity> KnownAbilities { get; set; }

Property Value

ICollection<CharacterKnownAbilityEntity>

LastChannelSwitchUtc

When this character last switched open-world channel (UTC), or MinValue if it never has.

public DateTime LastChannelSwitchUtc { get; set; }

Property Value

DateTime

Remarks

Persisted rather than held in memory because a channel switch is implemented as a disconnect: the character is released here and re-routed by the world server, quite possibly to a different scene server. Any cooldown kept per connection — or even per process — is therefore reset by the very act it is meant to limit, and only ever throttles switches that failed. This is the only place the limit can live and still mean anything.

LastSaved

Timestamp of the last save operation (UTC).

public DateTime LastSaved { get; set; }

Property Value

DateTime

LockReason

Why it was locked, as staff wrote it.

public string? LockReason { get; set; }

Property Value

string

LockedAt

When the current lock was placed.

public DateTime? LockedAt { get; set; }

Property Value

DateTime?

LockedBy

The staff account that placed the lock.

public string? LockedBy { get; set; }

Property Value

string

LockedUntil

When a staff character lock lapses (UTC), or null when the character is not locked.

public DateTime? LockedUntil { get; set; }

Property Value

DateTime?

Remarks

A lock keeps the character out of the world while staff work on it: character select refuses it and a scene server that holds it kicks it. The lock is in force only while this instant is in the future, so an expired lock needs nothing to clear it.

There is deliberately no lock without an end. A forgotten permanent lock strands a player with no message they can act on; an operator who needs longer extends it on purpose.

ModelIndex

Character model/prefab index.

public int ModelIndex { get; set; }

Property Value

int

MuteReason

What the operator gave as the reason for the mute.

public string? MuteReason { get; set; }

Property Value

string

Muted

Whether this one character is muted in chat.

public bool Muted { get; set; }

Property Value

bool

Remarks

Beside the account's own mute rather than instead of it: a character mute leaves the player's other characters able to talk, which is the proportionate answer when only one of them was the problem. MutedUntil null with this set means no end. Never written by the save path, whose UPDATE names its columns explicitly.

MutedBy

Account of the operator who applied the mute. Not a foreign key, deliberately.

public string? MutedBy { get; set; }

Property Value

string

MutedUntil

When the character's mute lifts (UTC), or null for a mute with no end.

public DateTime? MutedUntil { get; set; }

Property Value

DateTime?

Name

Character display name.

public string Name { get; set; }

Property Value

string

Remarks

[COLLATE NOCASE for case insensitive compare. this way we can't both create 'Archer' and 'archer' as characters] note: the collation has been added in the DbContext OnModelCreating function since the Postgres provider doesn't support collations via attributes

NameLowercase

Lowercase copy of Name for case-insensitive lookups.

public string NameLowercase { get; set; }

Property Value

string

Party

Navigation reference to the party membership record.

public CharacterPartyEntity Party { get; set; }

Property Value

CharacterPartyEntity

PetBuffs

Navigation collection of pet buff entries.

public ICollection<CharacterPetBuffEntity> PetBuffs { get; set; }

Property Value

ICollection<CharacterPetBuffEntity>

Pets

Navigation reference to the character's pet.

public ICollection<CharacterPetEntity> Pets { get; set; }

Property Value

ICollection<CharacterPetEntity>

Quests

Navigation collection of character quest progress entries.

public ICollection<CharacterQuestEntity> Quests { get; set; }

Property Value

ICollection<CharacterQuestEntity>

RaceID

Character race template ID.

public int RaceID { get; set; }

Property Value

int

RotW

Current rotation W component (quaternion).

public float RotW { get; set; }

Property Value

float

RotX

Current rotation X component.

public float RotX { get; set; }

Property Value

float

RotY

Current rotation Y component.

public float RotY { get; set; }

Property Value

float

RotZ

Current rotation Z component.

public float RotZ { get; set; }

Property Value

float

SceneHandle

Current scene handle the character is in.

public long SceneHandle { get; set; }

Property Value

long

SceneName

Current scene name the character is in.

public string SceneName { get; set; }

Property Value

string

Selected

Whether this character is the currently selected/active character for the account.

public bool Selected { get; set; }

Property Value

bool

SessionLeaseExpiresUtc

Lease expiry timestamp for dead-server recovery. A server should extend this periodically while it still owns the character.

public DateTime SessionLeaseExpiresUtc { get; set; }

Property Value

DateTime

SessionOwnerServerId

Current owning Scene Server instance ID (0 means unowned).

public long SessionOwnerServerId { get; set; }

Property Value

long

SessionOwnerToken

Ownership token that changes every successful claim (Guid.Empty means unowned). Used to prevent stale releases/transitions.

public Guid SessionOwnerToken { get; set; }

Property Value

Guid

SessionState

Distributed session state used to coordinate ownership/claims across servers.

public CharacterSessionState SessionState { get; set; }

Property Value

CharacterSessionState

Skills

Navigation collection of character skill entries.

public ICollection<CharacterSkillEntity> Skills { get; set; }

Property Value

ICollection<CharacterSkillEntity>

TimeCreated

Row creation timestamp (UTC).

public DateTime TimeCreated { get; set; }

Property Value

DateTime

TimeDeleted

Timestamp when the character was soft-deleted (UTC), or null if not deleted.

public DateTime? TimeDeleted { get; set; }

Property Value

DateTime?

Version

Concurrency version for optimistic locking.

public long Version { get; set; }

Property Value

long

WorldServerID

World server ID this character belongs to.

public long WorldServerID { get; set; }

Property Value

long

X

Current world position X. Uses float for direct compatibility with Unity's Vector3. Precision is approximately 1.5 cm at 10 km from origin; suitable for most game worlds but may exhibit jitter past ~100 km.

public float X { get; set; }

Property Value

float

Y

Current world position Y.

public float Y { get; set; }

Property Value

float

Z

Current world position Z.

public float Z { get; set; }

Property Value

float