-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathcards.schema.json
78 lines (78 loc) · 2.74 KB
/
cards.schema.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
{
"$id": "cards.schema.json",
"type": "object",
"description": "A list of cards, sorted by card type.",
"properties": {
"$schema": {
"type": "string"
},
"actions": {
"$ref": "#/$defs/cards"
},
"stances": {
"$ref": "#/$defs/cards"
}
},
"required": [
"$schema",
"actions",
"stances"
],
"additionalProperties": false,
"$defs": {
"path": {
"type": "string",
"pattern": "^[a-z_]+(/[a-z_]+)*$"
},
"cards": {
"type": "object",
"description": "A map of card names to their specifications.",
"additionalProperties": {
"type": "object",
"description": "Specifications of a card.",
"properties": {
"count": {
"type": "integer",
"description": "The amount of copies of the card in the library.",
"minimum": 0
},
"range": {
"$ref": "#/$defs/path",
"description": "The card's range image, relative to 'assets/hexes/range' (optional)."
},
"effects": {
"type": "array",
"description": "A list of up to three effects.",
"maxItems": 3,
"items": {
"type": "object",
"description": "An effect to display on the card.",
"properties": {
"type": {
"$ref": "#/$defs/path",
"description": "The effect's circle image, relative to 'assets/effect'."
},
"text": {
"type": "string",
"description": "Text to be displayed next to the circle (optional)."
}
},
"additionalProperties": false,
"required": [
"type"
]
}
},
"info": {
"type": "string",
"description": "Additional text to be displayed at the bottom of the card (optional)."
}
},
"additionalProperties": false,
"required": [
"effects"
]
}
}
}
}