Persisted data shape for a body location.

interface Data {
    __kind?: string;
    amputability: string;
    bleedingSusceptibility: string;
    bodyPartCode: string;
    isFumble?: boolean;
    isStumble?: boolean;
    name?: string;
    probWeight: number;
    protectionBase: {
        blunt: number;
        edged: number;
        fire: number;
        piercing: number;
    };
    shockValue: number;
    shortcode: string;
}

Hierarchy (View Summary)

Properties

__kind?: string

Discriminator kind, written on serialization (SohlEntity.toJSON) and read back on revival. Optional as constructor input — it is derived from the concrete class, not supplied by callers.

amputability: string

Amputability tier (Amputability value).

bleedingSusceptibility: string

Bleeding tier (BleedingSusceptibility value).

bodyPartCode: string

Shortcode of the BodyPart this location belongs to. A location whose code matches no part is not reachable in the hierarchy (see sohl.entity.body.BodyStructure.orphanedLocations).

isFumble?: boolean

Whether a serious/grievous injury here can cause a fumble.

isStumble?: boolean

Whether a serious/grievous injury here can cause a stumble.

name?: string

Display name of the location.

probWeight: number

Weight used in random hit location selection

protectionBase: { blunt: number; edged: number; fire: number; piercing: number }

Base protection values for different impact aspects

Type declaration

  • blunt: number

    Base protection against blunt impact.

  • edged: number

    Base protection against edged impact.

  • fire: number

    Base protection against fire impact.

  • piercing: number

    Base protection against piercing impact.

shockValue: number

Base shock value for injuries to this location (subject to modifiers)

shortcode: string

Unique location identifier within its part.