-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
c4bf0d0
commit 5d2e8d1
Showing
6 changed files
with
1,376 additions
and
1,299 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,51 +1,54 @@ | ||
{ | ||
"$schema": "http://json-schema.org/draft-07/schema#", | ||
"$id": "https://easecation.github.io/ECConfigSchema/ecnpc/container.schema.json", | ||
"type": "object", | ||
"properties": { | ||
"reference": { | ||
"type": "string" | ||
}, | ||
"dialogue": { | ||
"type": "object" | ||
}, | ||
"hook": { | ||
"type": "object" | ||
}, | ||
"skin": { | ||
"type": "array", | ||
"items": { | ||
"type": "object", | ||
"properties": { | ||
"skinId": { | ||
"type": "string" | ||
}, | ||
"skinData": { | ||
"type": "string", | ||
"format": "uri" | ||
}, | ||
"skinPack": { | ||
"type": "string", | ||
"format": "uri" | ||
}, | ||
"geometryName": { | ||
"$schema": "http://json-schema.org/draft-07/schema#", | ||
"$id": "https://easecation.github.io/ECConfigSchema/ecnpc/container.schema.json", | ||
"title": "ECNPCContainer schema", | ||
"type": "object", | ||
"properties": { | ||
"reference": { | ||
"type": "string" | ||
}, | ||
"geometryData": { | ||
"type": "string", | ||
"format": "uri" | ||
} | ||
}, | ||
"required": ["skinId"], | ||
"additionalProperties": false | ||
} | ||
"dialogue": { | ||
"type": "object" | ||
}, | ||
"hook": { | ||
"type": "object" | ||
}, | ||
"skin": { | ||
"type": "array", | ||
"items": { | ||
"type": "object", | ||
"properties": { | ||
"skinId": { | ||
"type": "string" | ||
}, | ||
"skinData": { | ||
"type": "string", | ||
"format": "uri" | ||
}, | ||
"skinPack": { | ||
"type": "string", | ||
"format": "uri" | ||
}, | ||
"geometryName": { | ||
"type": "string" | ||
}, | ||
"geometryData": { | ||
"type": "string", | ||
"format": "uri" | ||
} | ||
}, | ||
"required": [ | ||
"skinId" | ||
], | ||
"additionalProperties": false | ||
} | ||
}, | ||
"npc": { | ||
"type": "array", | ||
"items": { | ||
"$ref": "prefab.schema.json" | ||
} | ||
} | ||
}, | ||
"npc": { | ||
"type": "array", | ||
"items": { | ||
"$ref": "prefab.schema.json" | ||
} | ||
} | ||
}, | ||
"additionalProperties": true | ||
"additionalProperties": true | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,75 +1,88 @@ | ||
{ | ||
"$schema": "http://json-schema.org/draft-07/schema#", | ||
"$id": "https://easecation.github.io/ECConfigSchema/ecnpc/dialogue.handler.schema.json", | ||
"type": "object", | ||
"description": "对话的handler配置", | ||
"properties": { | ||
"type": { | ||
"type": "string", | ||
"description": "handler类型", | ||
"enum": ["dialogue", "action", "random"] | ||
} | ||
}, | ||
"required": ["type"], | ||
"oneOf": [ | ||
{ | ||
"$ref": "dialogue.schema.json" | ||
}, | ||
{ | ||
"type": "object", | ||
"description": "PlayerAction回调", | ||
"properties": { | ||
"$schema": "http://json-schema.org/draft-07/schema#", | ||
"$id": "https://easecation.github.io/ECConfigSchema/ecnpc/dialogue.handler.schema.json", | ||
"title": "ECNPC dialogue handler schema", | ||
"type": "object", | ||
"description": "对话的handler配置", | ||
"properties": { | ||
"type": { | ||
"const": "action", | ||
"description": "PlayerAction回调" | ||
}, | ||
"callback": { | ||
"oneOf": [ | ||
{ | ||
"type": "object", | ||
"$ref": "../playeraction/playeraction.schema.json" | ||
}, | ||
{ | ||
"type": "array", | ||
"items": { | ||
"$ref": "../playeraction/playeraction.schema.json" | ||
} | ||
} | ||
] | ||
"type": "string", | ||
"description": "handler类型", | ||
"enum": [ | ||
"dialogue", | ||
"action", | ||
"random" | ||
] | ||
} | ||
}, | ||
"required": [ | ||
"type", | ||
"callback" | ||
] | ||
}, | ||
{ | ||
"type": "object", | ||
"properties": { | ||
"type": { | ||
"const": "random", | ||
"description": "随机进行处理" | ||
"required": [ | ||
"type" | ||
], | ||
"oneOf": [ | ||
{ | ||
"$ref": "dialogue.schema.json" | ||
}, | ||
{ | ||
"type": "object", | ||
"description": "PlayerAction回调", | ||
"properties": { | ||
"type": { | ||
"const": "action", | ||
"description": "PlayerAction回调" | ||
}, | ||
"callback": { | ||
"oneOf": [ | ||
{ | ||
"type": "object", | ||
"$ref": "../playeraction/playeraction.schema.json" | ||
}, | ||
{ | ||
"type": "array", | ||
"items": { | ||
"$ref": "../playeraction/playeraction.schema.json" | ||
} | ||
} | ||
] | ||
} | ||
}, | ||
"required": [ | ||
"type", | ||
"callback" | ||
] | ||
}, | ||
"handler": { | ||
"type": "array", | ||
"description": "随机处理器配置", | ||
"items": { | ||
{ | ||
"type": "object", | ||
"properties": { | ||
"weight": { | ||
"type": "number", | ||
"description": "随机权重" | ||
}, | ||
"handler": { | ||
"$ref": "#" | ||
} | ||
"type": { | ||
"const": "random", | ||
"description": "随机进行处理" | ||
}, | ||
"handler": { | ||
"type": "array", | ||
"description": "随机处理器配置", | ||
"items": { | ||
"type": "object", | ||
"properties": { | ||
"weight": { | ||
"type": "number", | ||
"description": "随机权重" | ||
}, | ||
"handler": { | ||
"$ref": "#" | ||
} | ||
}, | ||
"required": [ | ||
"weight", | ||
"handler" | ||
] | ||
} | ||
} | ||
}, | ||
"required": ["weight", "handler"] | ||
} | ||
"required": [ | ||
"type", | ||
"handler" | ||
], | ||
"description": "随机进行处理" | ||
} | ||
}, | ||
"required": ["type", "handler"], | ||
"description": "随机进行处理" | ||
} | ||
] | ||
] | ||
} |
Oops, something went wrong.