Reworked the way that entities are loaded so they're more dynamic and can be configured without modifying C++code.
This commit is contained in:
parent
1f7214fcd4
commit
9ce4fbd552
6 changed files with 94 additions and 42 deletions
|
@ -2,36 +2,42 @@
|
|||
"PLAYER_TILE": {
|
||||
"foreground": [255, 200, 125],
|
||||
"background": [30, 20, 75],
|
||||
"hp": 100,
|
||||
"damage": 10,
|
||||
"display":"\ua66b"
|
||||
"components": [
|
||||
{"type": "Tile", "config": {"chr": "\ua66b"}},
|
||||
{"type": "Combat", "config": {"hp": 200, "damage": 15}}
|
||||
]
|
||||
},
|
||||
"SNAKE": {
|
||||
"foreground": [90, 172, 74],
|
||||
"background": [30, 20, 75],
|
||||
"hp": 15,
|
||||
"damage": 5,
|
||||
"display":"\u06b1"
|
||||
"components": [
|
||||
{"type": "Tile", "config": {"chr": "\u06b1"}},
|
||||
{"type": "Combat", "config": {"hp": 20, "damage": 15}}
|
||||
]
|
||||
},
|
||||
"GOBLIN": {
|
||||
"foreground": [50, 200, 125],
|
||||
"background": [30, 20, 75],
|
||||
"hp": 75,
|
||||
"damage": 30,
|
||||
"display":"\u06bf"
|
||||
"components": [
|
||||
{"type": "LightSource", "config": {"strength": 70, "radius": 1.8}},
|
||||
{"type": "Tile", "config": {"chr": "\u06bf"}},
|
||||
{"type": "Combat", "config": {"hp": 50, "damage": 35}}
|
||||
]
|
||||
},
|
||||
"UNICORN": {
|
||||
"foreground": [25, 200, 125],
|
||||
"background": [30, 20, 75],
|
||||
"hp": 50,
|
||||
"damage": 20,
|
||||
"display":"\u17a5"
|
||||
"components": [
|
||||
{"type": "Tile", "config": {"chr": "\u17a5"}},
|
||||
{"type": "Combat", "config": {"hp": 2000, "damage": 5}}
|
||||
]
|
||||
},
|
||||
"RAT": {
|
||||
"foreground": [75, 200, 125],
|
||||
"background": [30, 20, 75],
|
||||
"hp": 5,
|
||||
"damage": 1,
|
||||
"display":"\u08ac"
|
||||
"components": [
|
||||
{"type": "Tile", "config": {"chr": "\u08ac"}},
|
||||
{"type": "Combat", "config": {"hp": 10, "damage": 5}}
|
||||
]
|
||||
}
|
||||
}
|
||||
|
|
|
@ -5,8 +5,12 @@
|
|||
"foreground": [24, 205, 189],
|
||||
"background": [230, 20, 120],
|
||||
"description": "A torch that barely lights the way. You wonder if it'd be better to not see the person who murders you.",
|
||||
"type": "LIGHT",
|
||||
"display": "\u0f08"
|
||||
"inventory_count": 1,
|
||||
"components": [
|
||||
{"type": "LightSource", "config": {"strength": 70, "radius": 2.0}},
|
||||
{"type": "Tile", "config": {"chr": "\u0f08"}},
|
||||
{"type": "Weapon", "config": {"damage": 35}}
|
||||
]
|
||||
},
|
||||
"SWORD_RUSTY": {
|
||||
"id": "SWORD_RUSTY",
|
||||
|
@ -14,8 +18,24 @@
|
|||
"foreground": [24, 205, 189],
|
||||
"background": [24, 205, 189],
|
||||
"description": "A sword left to rot in a deep hole where it acquired a patina of dirt and tetanus. You aren't sure if it's more deadly for you to hold it or for the people you stab with it.",
|
||||
"type": "WEAPON",
|
||||
"display":"\u1e37"
|
||||
"inventory_count": 1,
|
||||
"components": [
|
||||
{"type": "Weapon", "config": {"damage": 15}},
|
||||
{"type": "Tile", "config": {"chr": "\u1e37"}}
|
||||
]
|
||||
},
|
||||
"SWORD_LIGHT_AND_FLAME": {
|
||||
"id": "SWORD_LIGHT_AND_FLAME",
|
||||
"name": "Sword of Light and Flame",
|
||||
"foreground": [24, 205, 189],
|
||||
"background": [24, 205, 189],
|
||||
"description": "A sword so powerful, a great man from the Land of The Rising Sun thrust it into the ocean of Nerf to chill its effects.",
|
||||
"inventory_count": 1,
|
||||
"components": [
|
||||
{"type": "LightSource", "config": {"strength": 70, "radius": 1.8}},
|
||||
{"type": "Tile", "config": {"chr": "\u0236"}},
|
||||
{"type": "Weapon", "config": {"damage": 30}}
|
||||
]
|
||||
},
|
||||
"CHEST_SMALL": {
|
||||
"id": "CHEST_SMALL",
|
||||
|
@ -23,8 +43,11 @@
|
|||
"foreground": [24, 205, 189],
|
||||
"background": [24, 205, 189],
|
||||
"description": "A small chest of gold. You wonder who would leave something like this around.",
|
||||
"type": "LOOT",
|
||||
"display":"\uaaea"
|
||||
"components": [
|
||||
{"type": "Tile", "config": {"chr": "\uaaea"}},
|
||||
{"type": "Loot", "config": {"amount": 10}}
|
||||
],
|
||||
"inventory_count": 1
|
||||
},
|
||||
"WALL_TORCH": {
|
||||
"id": "WALL_TORCH",
|
||||
|
@ -32,7 +55,11 @@
|
|||
"foreground": [24, 205, 189],
|
||||
"background": [24, 205, 189],
|
||||
"description": "A torch on a wall you can't pick up.",
|
||||
"type": "FIXED_LIGHT",
|
||||
"inventory_count": 0,
|
||||
"components": [
|
||||
{"type": "Tile", "config": {"chr": "\u06bf"}},
|
||||
{"type": "LightSource", "config": {"strength": 60, "radius": 1.8}}
|
||||
],
|
||||
"display": "☀"
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue