Release Healer Man 0.1.22
This commit is contained in:
1 parent
f6f2375145
commit
7f6001723a
144 files changed
+54107
-690
No files matched your search
@@ -7,6 +7,20 @@ export type DungeonWorldObjectKind =
|
||||
| "switch"
|
||||
| "key"
|
||||
| "chest"
|
||||
| "resource"
|
||||
| "generic"
|
||||
| "chair"
|
||||
| "spell-focus"
|
||||
| "text"
|
||||
| "trap"
|
||||
| "transport"
|
||||
| "camera"
|
||||
| "ritual"
|
||||
| "mailbox"
|
||||
| "fishing-hole"
|
||||
| "aura-generator"
|
||||
| "spellcaster"
|
||||
| "destructible"
|
||||
| "npc"
|
||||
| "quest-object"
|
||||
| "trigger";
|
||||
@@ -21,6 +35,14 @@ export interface DungeonWorldObjectSource {
|
||||
readonly files: readonly string[];
|
||||
readonly templateId?: number;
|
||||
readonly spawnId?: number;
|
||||
readonly gameObjectType?: number;
|
||||
readonly clientDisplayId?: number;
|
||||
readonly clientModelPath?: string;
|
||||
/** Unscaled client x/y/z display bounds retained for asset/collision review. */
|
||||
readonly clientBounds?: {
|
||||
readonly min: MobVector3;
|
||||
readonly max: MobVector3;
|
||||
};
|
||||
readonly note?: string;
|
||||
}
|
||||
|
||||
@@ -45,6 +67,8 @@ export interface DungeonWorldObjectInteraction {
|
||||
export interface DungeonWorldObjectVisual {
|
||||
/** Optional independently packaged GLB. Procedural geometry remains the safe fallback. */
|
||||
readonly assetUrl?: string;
|
||||
/** Source-adapted records stay hidden until their client display is reviewed. */
|
||||
readonly hidden?: boolean;
|
||||
readonly color?: string;
|
||||
readonly emissive?: string;
|
||||
readonly scale?: MobVector3;
|
||||
@@ -111,6 +135,24 @@ export function validateDungeonWorldObject(object: DungeonWorldObjectDefinition)
|
||||
if (object.interaction && (!object.interaction.signalId.trim() || object.interaction.range <= 0)) {
|
||||
throw new Error(`Dungeon world object ${object.id} has an invalid interaction.`);
|
||||
}
|
||||
if (object.visual?.assetUrl && object.visual.hidden) {
|
||||
throw new Error(`Dungeon world object ${object.id} cannot hide an authored visual asset.`);
|
||||
}
|
||||
if (object.source?.gameObjectType !== undefined && (
|
||||
!Number.isInteger(object.source.gameObjectType)
|
||||
|| object.source.gameObjectType < 0
|
||||
|| object.source.gameObjectType > 35
|
||||
)) {
|
||||
throw new Error(`Dungeon world object ${object.id} has an invalid source gameobject type.`);
|
||||
}
|
||||
const clientBounds = object.source?.clientBounds;
|
||||
if (clientBounds && (
|
||||
!clientBounds.min.every(Number.isFinite)
|
||||
|| !clientBounds.max.every(Number.isFinite)
|
||||
|| clientBounds.min.some((value, axis) => value >= clientBounds.max[axis])
|
||||
)) {
|
||||
throw new Error(`Dungeon world object ${object.id} has invalid client display bounds.`);
|
||||
}
|
||||
}
|
||||
|
||||
export function nearestDungeonWorldInteraction(
|
||||
|
||||
Reference in new issue
Block a user