build-engine-randomizer
build-engine-randomizer copied to clipboard
support spawning new items with different palettes
for Blood: https://github.com/thomasrogers03/bloom/blob/master/bloom/resources/sprite_types.yaml
as json
{
"0": {
"category": "decoration",
"name": "Decoration"
},
"1": {
"category": "player",
"invisible": true,
"name": "Player Start",
"properties": [
{
"from": "data_1",
"link_to_tile": "offset",
"name": "Player Number",
"offset": -1,
"type": "int"
}
],
"repeats": {
"x": 16,
"y": 16
},
"tile_config": {
"start_tile": 2522
}
},
"2": {
"category": "player",
"invisible": true,
"name": "Bloodbath Start",
"palette": 5,
"properties": [
{
"from": "data_1",
"link_to_tile": "offset",
"name": "Player Number",
"offset": -1,
"type": "int"
}
],
"repeats": {
"x": 16,
"y": 16
},
"tile_config": {
"from_data": 1,
"start_tile": 2522
}
},
"3": {
"category": "markers",
"invisible": true,
"name": "Off Marker"
},
"4": {
"category": "markers",
"invisible": true,
"name": "On Marker"
},
"5": {
"category": "markers",
"invisible": true,
"name": "Axis Marker"
},
"6": {
"category": "sector links",
"invisible": true,
"name": "Lower Link",
"tile_config": {
"tile": 2331
}
},
"7": {
"category": "sector links",
"invisible": true,
"name": "Upper Link",
"tile_config": {
"tile": 2332
}
},
"8": {
"category": "markers",
"invisible": true,
"name": "Teleport Target"
},
"9": {
"category": "sector links",
"invisible": true,
"name": "Upper Water",
"tile_config": {
"tile": 2332
}
},
"10": {
"category": "sector links",
"invisible": true,
"name": "Lower Water",
"tile_config": {
"tile": 2331
}
},
"11": {
"category": "sector links",
"invisible": true,
"name": "Upper Stack",
"tile_config": {
"tile": 2332
}
},
"12": {
"category": "sector links",
"invisible": true,
"name": "Lower Stack",
"tile_config": {
"tile": 2331
}
},
"13": {
"category": "sector links",
"invisible": true,
"name": "Upper Goo",
"tile_config": {
"tile": 2332
}
},
"14": {
"category": "sector links",
"invisible": true,
"name": "Lower Goo",
"tile_config": {
"tile": 2331
}
},
"15": {
"category": "markers",
"name": "Path Marker",
"properties": [
{
"from": "data_1",
"name": "Marker ID",
"type": "int"
},
{
"from": "data_2",
"name": "Next Marker ID",
"type": "int"
}
],
"tile_config": {
"tile": 2319
}
},
"16": {
"category": "misc",
"name": "Alignable Region"
},
"17": {
"category": "misc",
"name": "Base Region"
},
"18": {
"category": "misc",
"name": "Dude Spawn",
"tile_config": {
"tile": 2077
}
},
"19": {
"category": "misc",
"name": "Earthquake",
"tile_config": {
"tile": 2072
}
},
"20": {
"category": "switches",
"name": "Toggle Switch",
"properties": [
{
"from": "data_1",
"name": "Sound When Turning On",
"type": "sound"
},
{
"from": "data_2",
"name": "Sound When Turning Off",
"type": "sound"
}
],
"repeats": {
"x": 12,
"y": 12
},
"tile_config": {
"tiles": [
318,
982,
1046,
1012,
1070,
1072,
1074,
1076,
1078
]
}
},
"21": {
"category": "switches",
"name": "1-Way Switch",
"properties": [
{
"from": "data_1",
"name": "Sound When Turning On",
"type": "sound"
}
],
"repeats": {
"x": 12,
"y": 12
},
"tile_config": {
"tiles": [
318,
982,
1046,
1012,
1070,
1072,
1074,
1076,
1078
]
}
},
"22": {
"category": "switches",
"name": "Combination Switch",
"properties": [
{
"from": "data_1",
"name": "Start Position",
"type": "int"
},
{
"from": "data_2",
"name": "Activate Position",
"type": "int"
},
{
"from": "data_3",
"name": "Period",
"type": "int"
},
{
"from": "data_4",
"name": "Sound To Play",
"type": "sound"
}
],
"repeats": {
"x": 12,
"y": 12
},
"tile_config": {
"tiles": [
1161,
2532
]
}
},
"23": {
"category": "switches",
"name": "Padlock (1-Shot)",
"repeats": {
"x": 12,
"y": 12
},
"tile_config": {
"tile": 912
}
},
"30": {
"category": "decoration",
"name": "Torch",
"tile_config": {
"tile": 550
}
},
"32": {
"category": "decoration",
"name": "Candle",
"tile_config": {
"tile": 938
}
},
"40": {
"category": "weapons",
"name": "Random Weapon",
"repeats": {
"x": 12,
"y": 12
},
"tile_config": {
"tile": 832
}
},
"41": {
"category": "weapons",
"name": "Sawed Off",
"repeats": {
"x": 10,
"y": 10
},
"tile_config": {
"tile": 559
}
},
"42": {
"category": "weapons",
"name": "Tommy Gun",
"repeats": {
"x": 10,
"y": 10
},
"tile_config": {
"tile": 558
}
},
"43": {
"category": "weapons",
"name": "Flare Pistol",
"repeats": {
"x": 10,
"y": 10
},
"tile_config": {
"tile": 524
}
},
"44": {
"category": "weapons",
"name": "Voodoo Doll",
"repeats": {
"x": 10,
"y": 10
},
"tile_config": {
"tile": 525
}
},
"45": {
"category": "weapons",
"name": "Tesla Cannon",
"repeats": {
"x": 10,
"y": 10
},
"tile_config": {
"tile": 539
}
},
"46": {
"category": "weapons",
"name": "Napalm Launcher",
"repeats": {
"x": 10,
"y": 10
},
"tile_config": {
"tile": 526
}
},
"47": {
"category": "weapons",
"name": "Pitchfork"
},
"48": {
"category": "weapons",
"name": "Spray Can",
"repeats": {
"x": 10,
"y": 10
}
},
"49": {
"category": "weapons",
"name": "Dynamite",
"repeats": {
"x": 10,
"y": 10
}
},
"50": {
"category": "weapons",
"name": "Life Leech",
"repeats": {
"x": 10,
"y": 10
},
"tile_config": {
"tile": 800
}
},
"60": {
"category": "weapons",
"name": "Spray Can",
"repeats": {
"x": 10,
"y": 10
},
"tile_config": {
"tile": 618
}
},
"62": {
"category": "weapons",
"name": "Bundle of TNT",
"repeats": {
"x": 10,
"y": 10
},
"tile_config": {
"tile": 589
}
},
"63": {
"category": "weapons",
"name": "Case of TNT",
"repeats": {
"x": 10,
"y": 10
},
"tile_config": {
"tile": 809
}
},
"64": {
"category": "weapons",
"name": "Proximity Detonator",
"repeats": {
"x": 10,
"y": 10
},
"tile_config": {
"tile": 811
}
},
"65": {
"category": "weapons",
"name": "Remote Detonator",
"repeats": {
"x": 10,
"y": 10
},
"tile_config": {
"tile": 810
}
},
"66": {
"category": "ammo",
"name": "Trapped Soul",
"repeats": {
"x": 6,
"y": 6
},
"tile_config": {
"tile": 820
}
},
"67": {
"category": "ammo",
"name": "4 Shotgun Shells",
"repeats": {
"x": 10,
"y": 10
},
"tile_config": {
"tile": 619
}
},
"68": {
"category": "ammo",
"name": "Box of Shotgun Shells",
"repeats": {
"x": 10,
"y": 10
},
"tile_config": {
"tile": 812
}
},
"69": {
"category": "ammo",
"name": "A Few Bullets",
"repeats": {
"x": 10,
"y": 10
},
"tile_config": {
"tile": 813
}
},
"70": {
"category": "weapons",
"name": "Voodoo Doll",
"repeats": {
"x": 10,
"y": 10
}
},
"72": {
"category": "ammo",
"name": "Full Drum of Bullets",
"repeats": {
"x": 10,
"y": 10
},
"tile_config": {
"tile": 817
}
},
"73": {
"category": "ammo",
"name": "Tesla Charge",
"repeats": {
"x": 6,
"y": 6
},
"tile_config": {
"tile": 548
}
},
"76": {
"category": "ammo",
"name": "Flares",
"repeats": {
"x": 10,
"y": 10
},
"tile_config": {
"tile": 816
}
},
"79": {
"category": "ammo",
"name": "Gasoline Can",
"repeats": {
"x": 10,
"y": 10
},
"tile_config": {
"tile": 801
}
},
"80": {
"category": "ammo",
"name": "Random Ammo",
"repeats": {
"x": 12,
"y": 12
},
"tile_config": {
"tile": 832
}
},
"100": {
"category": "keys",
"name": "Skull Key",
"repeats": {
"x": 8,
"y": 8
},
"tile_config": {
"tile": 2552
}
},
"101": {
"category": "keys",
"name": "Eye Key",
"repeats": {
"x": 8,
"y": 8
},
"tile_config": {
"tile": 2553
}
},
"102": {
"category": "keys",
"name": "Fire Key",
"repeats": {
"x": 8,
"y": 8
},
"tile_config": {
"tile": 2554
}
},
"103": {
"category": "keys",
"name": "Dagger Key",
"repeats": {
"x": 8,
"y": 8
},
"tile_config": {
"tile": 2555
}
},
"104": {
"category": "keys",
"name": "Spider Key",
"repeats": {
"x": 8,
"y": 8
},
"tile_config": {
"tile": 2556
}
},
"105": {
"category": "keys",
"name": "Moon Key",
"repeats": {
"x": 8,
"y": 8
},
"tile_config": {
"tile": 2557
}
},
"106": {
"category": "keys",
"name": "Key 7",
"repeats": {
"x": 8,
"y": 8
},
"tile_config": {
"tile": 2558
}
},
"107": {
"category": "items",
"name": "Doctor's Bag",
"repeats": {
"x": 12,
"y": 12
},
"tile_config": {
"tile": 519
}
},
"108": {
"category": "items",
"name": "Medicine Pouch",
"repeats": {
"x": 10,
"y": 10
},
"tile_config": {
"tile": 822
}
},
"109": {
"category": "items",
"name": "Life Essence",
"repeats": {
"x": 10,
"y": 10
},
"tile_config": {
"tile": 2169
}
},
"110": {
"category": "items",
"name": "Life Seed",
"repeats": {
"x": 10,
"y": 10
},
"tile_config": {
"tile": 2433
}
},
"111": {
"category": "items",
"name": "Red Potion",
"repeats": {
"x": 10,
"y": 10
}
},
"112": {
"category": "items",
"name": "Feather Fall",
"repeats": {
"x": 10,
"y": 10
}
},
"113": {
"category": "items",
"name": "Limited Invisibility",
"repeats": {
"x": 10,
"y": 10
},
"tile_config": {
"tile": 896
}
},
"114": {
"category": "items",
"name": "Invulnerability",
"repeats": {
"x": 10,
"y": 10
},
"tile_config": {
"tile": 825
}
},
"115": {
"category": "items",
"name": "Boots of Jumping",
"repeats": {
"x": 10,
"y": 10
},
"tile_config": {
"tile": 827
}
},
"116": {
"blocking": 0,
"category": "items",
"name": "Raven Flight",
"repeats": {
"x": 12,
"y": 12
},
"tile_config": {
"tile": 828
}
},
"117": {
"category": "items",
"name": "Guns Akimbo",
"repeats": {
"x": 10,
"y": 10
},
"tile_config": {
"tile": 829
}
},
"118": {
"category": "items",
"name": "Diving Suit",
"repeats": {
"x": 12,
"y": 12
},
"tile_config": {
"tile": 830
}
},
"119": {
"category": "items",
"name": "Gas Mask",
"repeats": {
"x": 10,
"y": 10
},
"tile_config": {
"tile": 831
}
},
"120": {
"category": "items",
"name": "Clone"
},
"121": {
"category": "items",
"name": "Crystal Ball",
"repeats": {
"x": 10,
"y": 10
},
"tile_config": {
"tile": 760
}
},
"122": {
"category": "items",
"name": "Decoy"
},
"123": {
"category": "items",
"name": "Doppleganger"
},
"124": {
"category": "items",
"name": "Reflective Shots",
"repeats": {
"x": 10,
"y": 10
},
"tile_config": {
"tile": 2428
}
},
"125": {
"category": "items",
"name": "Beast Vision",
"repeats": {
"x": 10,
"y": 10
},
"tile_config": {
"tile": 839
}
},
"126": {
"blocking": 0,
"category": "items",
"name": "Shadow Cloak",
"repeats": {
"x": 12,
"y": 12
},
"tile_config": {
"tile": 768
}
},
"127": {
"blocking": 0,
"category": "items",
"name": "Rage Shroom",
"repeats": {
"x": 12,
"y": 12
},
"tile_config": {
"tile": 840
}
},
"128": {
"blocking": 0,
"category": "items",
"name": "Delirium Shroom",
"repeats": {
"x": 12,
"y": 12
},
"tile_config": {
"tile": 841
}
},
"129": {
"blocking": 0,
"category": "items",
"name": "Grow Shroom",
"repeats": {
"x": 12,
"y": 12
},
"tile_config": {
"tile": 842
}
},
"130": {
"blocking": 0,
"category": "items",
"name": "Shrink Shroom",
"repeats": {
"x": 12,
"y": 12
},
"tile_config": {
"tile": 843
}
},
"131": {
"category": "items",
"name": "Death Mask"
},
"132": {
"category": "items",
"name": "Wine Goblet"
},
"133": {
"blocking": 0,
"category": "items",
"name": "Wine Bottle",
"palette": 4
},
"134": {
"blocking": 0,
"category": "items",
"name": "Skull Grail"
},
"135": {
"blocking": 0,
"category": "items",
"name": "Silver Grail"
},
"136": {
"category": "items",
"name": "Tome",
"repeats": {
"x": 10,
"y": 10
},
"tile_config": {
"tile": 518
}
},
"137": {
"blocking": 0,
"category": "items",
"name": "Black Chest",
"repeats": {
"x": 12,
"y": 12
},
"tile_config": {
"tile": 522
}
},
"138": {
"blocking": 0,
"category": "items",
"name": "Wooden Chest",
"repeats": {
"x": 12,
"y": 12
},
"tile_config": {
"tile": 523
}
},
"139": {
"category": "items",
"name": "Asbestos Armor",
"repeats": {
"x": 16,
"y": 16
}
},
"140": {
"category": "items",
"name": "Basic Armor",
"repeats": {
"x": 12,
"y": 12
},
"tile_config": {
"tile": 2628
}
},
"141": {
"category": "items",
"name": "Body Armor",
"repeats": {
"x": 12,
"y": 12
},
"tile_config": {
"tile": 2586
}
},
"142": {
"category": "items",
"name": "Fire Armor",
"repeats": {
"x": 12,
"y": 12
},
"tile_config": {
"tile": 2578
}
},
"143": {
"category": "items",
"name": "Spirit Armor",
"repeats": {
"x": 12,
"y": 12
},
"tile_config": {
"tile": 2602
}
},
"144": {
"category": "items",
"name": "Super Armor",
"repeats": {
"x": 12,
"y": 12
},
"tile_config": {
"tile": 2594
}
},
"145": {
"category": "multiplayer",
"name": "Blue Team Base"
},
"146": {
"category": "multiplayer",
"name": "Red Team Base"
},
"200": {
"blocking": 1,
"category": "monsters",
"clipdist": 0,
"name": "Random Creature",
"palette": 0,
"repeats": {
"x": 0,
"y": 0
},
"seq": 0,
"tile_config": {
"tile": 832
}
},
"201": {
"blocking": 1,
"category": "monsters",
"clipdist": 48,
"name": "Cultist w/ Tommy",
"palette": 3,
"repeats": {
"x": 9,
"y": 10
},
"seq": 4096,
"tile_config": {
"tile": 2820
}
},
"202": {
"blocking": 1,
"category": "monsters",
"clipdist": 48,
"name": "Cultist w/ Shotgun",
"repeats": {
"x": 9,
"y": 10
},
"seq": 11520,
"tile_config": {
"tile": 2820
}
},
"203": {
"blocking": 1,
"category": "monsters",
"clipdist": 48,
"name": "Axe Zombie",
"repeats": {
"x": 10,
"y": 10
},
"seq": 4352,
"tile_config": {
"tile": 1170
}
},
"204": {
"blocking": 1,
"category": "monsters",
"clipdist": 48,
"name": "Fat Zombie",
"repeats": {
"x": 12,
"y": 12
},
"seq": 4608,
"tile_config": {
"tile": 1370
}
},
"205": {
"blocking": 1,
"category": "monsters",
"clipdist": 48,
"name": "Earth Zombie",
"repeats": {
"x": 10,
"y": 10
},
"tile_config": {
"tile": 3054
}
},
"206": {
"blocking": 1,
"category": "monsters",
"clipdist": 64,
"name": "Flesh Gargoyle",
"repeats": {
"x": 10,
"y": 10
},
"seq": 4864,
"tile_config": {
"tile": 1470
}
},
"207": {
"blocking": 1,
"category": "monsters",
"clipdist": 84,
"name": "Stone Gargoyle",
"palette": 5,
"repeats": {
"x": 16,
"y": 16
},
"seq": 5120,
"tile_config": {
"tile": 1470
}
},
"208": {
"blocking": 1,
"category": "monsters",
"clipdist": 64,
"name": "Flesh Statue",
"repeats": {
"x": 10,
"y": 10
},
"tile_config": {
"tile": 1530
}
},
"209": {
"blocking": 1,
"category": "monsters",
"clipdist": 64,
"name": "Stone Statue",
"palette": 5,
"repeats": {
"x": 10,
"y": 10
},
"tile_config": {
"tile": 1530
}
},
"210": {
"blocking": 1,
"category": "monsters",
"clipdist": 64,
"name": "Phantasm",
"translucency": 1,
"repeats": {
"x": 10,
"y": 10
},
"seq": 5376,
"tile_config": {
"tile": 3060
}
},
"211": {
"blocking": 1,
"category": "monsters",
"clipdist": 80,
"name": "Hound",
"repeats": {
"x": 10,
"y": 10
},
"seq": 5632,
"tile_config": {
"tile": 1270
}
},
"212": {
"blocking": 1,
"category": "monsters",
"clipdist": 32,
"name": "Hand",
"repeats": {
"x": 8,
"y": 8
},
"seq": 5888,
"tile_config": {
"tile": 1980
}
},
"213": {
"blocking": 1,
"category": "monsters",
"clipdist": 32,
"name": "Brown Spider",
"palette": 7,
"repeats": {
"x": 10,
"y": 10
},
"seq": 6144,
"tile_config": {
"tile": 1920
}
},
"214": {
"blocking": 1,
"category": "monsters",
"clipdist": 32,
"name": "Red Spider",
"palette": 4,
"repeats": {
"x": 10,
"y": 10
},
"seq": 6400,
"tile_config": {
"tile": 1920
}
},
"215": {
"blocking": 1,
"category": "monsters",
"clipdist": 32,
"name": "Black Spider",
"palette": 4,
"repeats": {
"x": 10,
"y": 10
},
"seq": 6656,
"tile_config": {
"tile": 1920
}
},
"216": {
"blocking": 1,
"category": "monsters",
"clipdist": 32,
"name": "Mother Spider",
"repeats": {
"x": 20,
"y": 20
},
"seq": 6912,
"tile_config": {
"tile": 1920
}
},
"217": {
"blocking": 1,
"category": "monsters",
"clipdist": 64,
"name": "Gill Beast",
"repeats": {
"x": 12,
"y": 12
},
"seq": 7168,
"tile_config": {
"tile": 1570
}
},
"218": {
"blocking": 1,
"category": "monsters",
"clipdist": 32,
"name": "Eel",
"repeats": {
"x": 10,
"y": 10
},
"seq": 7424,
"tile_config": {
"tile": 1870
}
},
"219": {
"blocking": 1,
"category": "monsters",
"clipdist": 32,
"name": "Bat",
"repeats": {
"x": 8,
"y": 8
},
"seq": 7680,
"tile_config": {
"tile": 1912
}
},
"220": {
"blocking": 1,
"category": "monsters",
"clipdist": 32,
"name": "Rat",
"repeats": {
"x": 6,
"y": 6
},
"seq": 7936,
"tile_config": {
"tile": 1745
}
},
"221": {
"blocking": 1,
"category": "monsters",
"clipdist": 64,
"name": "Green Pod",
"repeats": {
"x": 10,
"y": 10
},
"seq": 8192,
"tile_config": {
"tile": 1792
}
},
"222": {
"blocking": 1,
"category": "monsters",
"clipdist": 32,
"name": "Green Tentacle",
"repeats": {
"x": 10,
"y": 10
},
"seq": 8448,
"tile_config": {
"tile": 1797
}
},
"223": {
"blocking": 1,
"category": "monsters",
"clipdist": 64,
"name": "Fire Pod",
"palette": 2,
"repeats": {
"x": 10,
"y": 10
},
"seq": 8704,
"tile_config": {
"tile": 1792
}
},
"224": {
"blocking": 1,
"category": "monsters",
"clipdist": 32,
"name": "Fire Tentacle",
"palette": 2,
"repeats": {
"x": 10,
"y": 10
},
"seq": 8960,
"tile_config": {
"tile": 1797
}
},
"225": {
"blocking": 1,
"category": "monsters",
"clipdist": 64,
"name": "Mother Pod",
"palette": 0,
"repeats": {
"x": 10,
"y": 10
},
"seq": 9216,
"tile_config": {
"tile": 1792
}
},
"226": {
"blocking": 1,
"category": "monsters",
"clipdist": 32,
"name": "Mother Tentacle",
"palette": 0,
"repeats": {
"x": 10,
"y": 10
},
"seq": 9472,
"tile_config": {
"tile": 1797
}
},
"227": {
"blocking": 1,
"category": "monsters",
"clipdist": 64,
"name": "Cerberus",
"repeats": {
"x": 16,
"y": 16
},
"seq": 9728,
"tile_config": {
"tile": 2680
}
},
"228": {
"blocking": 1,
"category": "decoration",
"clipdist": 64,
"name": "Unknown",
"repeats": {
"x": 16,
"y": 16
},
"seq": 9984,
"tile_config": {
"tile": 0
}
},
"229": {
"blocking": 1,
"category": "monsters",
"clipdist": 128,
"name": "Tchernobog",
"repeats": {
"x": 16,
"y": 16
},
"seq": 10240,
"tile_config": {
"tile": 3140
}
},
"230": {
"blocking": 1,
"category": "monsters",
"clipdist": 48,
"name": "Tommy Cultist Prone",
"palette": 3,
"repeats": {
"x": 9,
"y": 10
},
"seq": 4096,
"tile_config": {
"tile": 3385
}
},
"231": {
"blocking": 1,
"category": "decoration",
"clipdist": 48,
"name": "Unknown",
"repeats": {
"x": 8,
"y": 9
},
"seq": 12032,
"tile_config": {
"tile": 0
}
},
"232": {
"blocking": 1,
"category": "decoration",
"clipdist": 48,
"name": "Unknown",
"repeats": {
"x": 8,
"y": 9
},
"seq": 12032,
"tile_config": {
"tile": 0
}
},
"233": {
"blocking": 1,
"category": "decoration",
"clipdist": 48,
"name": "Unknown",
"repeats": {
"x": 8,
"y": 9
},
"seq": 12032,
"tile_config": {
"tile": 0
}
},
"234": {
"blocking": 1,
"category": "decoration",
"clipdist": 48,
"name": "Unknown",
"repeats": {
"x": 8,
"y": 9
},
"seq": 12032,
"tile_config": {
"tile": 0
}
},
"235": {
"blocking": 1,
"category": "decoration",
"clipdist": 48,
"name": "Unknown",
"repeats": {
"x": 8,
"y": 9
},
"seq": 12032,
"tile_config": {
"tile": 0
}
},
"236": {
"blocking": 1,
"category": "decoration",
"clipdist": 48,
"name": "Unknown",
"repeats": {
"x": 8,
"y": 9
},
"seq": 12032,
"tile_config": {
"tile": 0
}
},
"237": {
"blocking": 1,
"category": "decoration",
"clipdist": 48,
"name": "Unknown",
"repeats": {
"x": 8,
"y": 9
},
"seq": 12032,
"tile_config": {
"tile": 0
}
},
"238": {
"blocking": 1,
"category": "decoration",
"clipdist": 48,
"name": "Unknown",
"repeats": {
"x": 8,
"y": 9
},
"seq": 12032,
"tile_config": {
"tile": 0
}
},
"239": {
"blocking": 1,
"category": "decoration",
"clipdist": 48,
"name": "Unknown",
"repeats": {
"x": 10,
"y": 10
},
"seq": 12544,
"tile_config": {
"tile": 0
}
},
"240": {
"blocking": 1,
"category": "decoration",
"clipdist": 48,
"name": "Unknown",
"repeats": {
"x": 9,
"y": 10
},
"seq": 4096,
"tile_config": {
"tile": 0
}
},
"241": {
"blocking": 1,
"category": "decoration",
"clipdist": 48,
"name": "Unknown",
"repeats": {
"x": 10,
"y": 10
},
"seq": 4352,
"tile_config": {
"tile": 0
}
},
"242": {
"blocking": 1,
"category": "decoration",
"clipdist": 48,
"name": "Unknown",
"repeats": {
"x": 10,
"y": 10
},
"seq": 4608,
"tile_config": {
"tile": 0
}
},
"243": {
"blocking": 1,
"category": "decoration",
"clipdist": 64,
"name": "Unknown",
"palette": 0,
"seq": 4096,
"tile_config": {
"tile": 0
}
},
"244": {
"blocking": 1,
"category": "monsters",
"clipdist": 48,
"name": "Sleep Zombie",
"repeats": {
"x": 10,
"y": 10
},
"tile_config": {
"tile": 1209
}
},
"245": {
"blocking": 1,
"category": "monsters",
"clipdist": 48,
"name": "Innocent",
"repeats": {
"x": 10,
"y": 10
},
"seq": 12544,
"tile_config": {
"tile": 3798
}
},
"246": {
"blocking": 1,
"category": "monsters",
"clipdist": 48,
"name": "Shotgun Cultist Prone",
"repeats": {
"x": 9,
"y": 10
},
"seq": 11520,
"tile_config": {
"tile": 3385
}
},
"247": {
"blocking": 1,
"category": "monsters",
"clipdist": 48,
"name": "Cultist w/ Tesla",
"palette": 11,
"repeats": {
"x": 9,
"y": 10
},
"seq": 12800,
"tile_config": {
"tile": 2820
}
},
"248": {
"blocking": 1,
"category": "monsters",
"clipdist": 48,
"name": "Cultist w/ Dynamite",
"palette": 13,
"repeats": {
"x": 9,
"y": 10
},
"seq": 13056,
"tile_config": {
"tile": 2820
}
},
"249": {
"blocking": 1,
"category": "monsters",
"clipdist": 48,
"name": "Beast Cultist",
"palette": 12,
"repeats": {
"x": 9,
"y": 10
},
"seq": 13312,
"tile_config": {
"tile": 2820
}
},
"250": {
"blocking": 1,
"category": "monsters",
"clipdist": 32,
"name": "Tiny Caleb",
"repeats": {
"x": 4,
"y": 4
},
"seq": 13568,
"tile_config": {
"tile": 3870
}
},
"251": {
"blocking": 1,
"category": "monsters",
"clipdist": 48,
"name": "Beast",
"repeats": {
"x": 9,
"y": 10
},
"seq": 10752,
"tile_config": {
"tile": 2690
}
},
"252": {
"blocking": 1,
"category": "decoration",
"clipdist": 32,
"name": "Unknown",
"palette": 0,
"seq": 13568,
"tile_config": {
"tile": 0
}
},
"253": {
"blocking": 1,
"category": "decoration",
"clipdist": 48,
"name": "Unknown",
"palette": 41,
"seq": 10752,
"tile_config": {
"tile": 0
}
},
"300": {
"category": "decoration",
"clipdist": 16,
"name": "Unknown",
"repeats": {
"x": 10,
"y": 10
},
"tile_config": {
"tile": 0
}
},
"301": {
"category": "decoration",
"clipdist": 32,
"name": "Unknown",
"repeats": {
"x": 8,
"y": 8
},
"tile_config": {
"tile": 0
}
},
"302": {
"category": "decoration",
"clipdist": 32,
"name": "Unknown",
"repeats": {
"x": 8,
"y": 8
},
"tile_config": {
"tile": 0
}
},
"303": {
"category": "decoration",
"clipdist": 4,
"name": "Unknown",
"repeats": {
"x": 8,
"y": 8
},
"tile_config": {
"tile": 0
}
},
"304": {
"category": "decoration",
"clipdist": 16,
"name": "Unknown",
"repeats": {
"x": 6,
"y": 6
},
"tile_config": {
"tile": 0
}
},
"305": {
"category": "decoration",
"clipdist": 32,
"name": "Unknown",
"repeats": {
"x": 8,
"y": 8
},
"seq": 22,
"tile_config": {
"tile": 0
}
},
"306": {
"category": "decoration",
"clipdist": 16,
"name": "Unknown",
"repeats": {
"x": 8,
"y": 8
},
"tile_config": {
"tile": 0
}
},
"307": {
"category": "decoration",
"clipdist": 32,
"name": "Unknown",
"repeats": {
"x": 8,
"y": 8
},
"tile_config": {
"tile": 0
}
},
"308": {
"category": "decoration",
"clipdist": 16,
"name": "Unknown",
"repeats": {
"x": 6,
"y": 6
},
"seq": 27,
"tile_config": {
"tile": 0
}
},
"309": {
"category": "decoration",
"clipdist": 16,
"name": "Unknown",
"repeats": {
"x": 4,
"y": 4
},
"seq": 29,
"tile_config": {
"tile": 0
}
},
"310": {
"category": "decoration",
"clipdist": 16,
"name": "Unknown",
"repeats": {
"x": 2,
"y": 2
},
"tile_config": {
"tile": 0
}
},
"311": {
"category": "decoration",
"clipdist": 16,
"name": "Unknown",
"repeats": {
"x": 8,
"y": 8
},
"tile_config": {
"tile": 0
}
},
"312": {
"category": "decoration",
"clipdist": 24,
"name": "Unknown",
"repeats": {
"x": 8,
"y": 8
},
"seq": 61,
"tile_config": {
"tile": 0
}
},
"313": {
"category": "decoration",
"clipdist": 24,
"name": "Unknown",
"repeats": {
"x": 8,
"y": 8
},
"seq": 61,
"tile_config": {
"tile": 0
}
},
"314": {
"category": "decoration",
"clipdist": 16,
"name": "Unknown",
"repeats": {
"x": 6,
"y": 6
},
"seq": 23,
"tile_config": {
"tile": 0
}
},
"315": {
"category": "decoration",
"clipdist": 16,
"name": "Unknown",
"repeats": {
"x": 8,
"y": 8
},
"tile_config": {
"tile": 0
}
},
"316": {
"category": "decoration",
"clipdist": 16,
"name": "Unknown",
"repeats": {
"x": 4,
"y": 4
},
"tile_config": {
"tile": 0
}
},
"317": {
"category": "decoration",
"clipdist": 16,
"name": "Unknown",
"repeats": {
"x": 8,
"y": 8
},
"tile_config": {
"tile": 0
}
},
"400": {
"blocking": 0,
"category": "gibbable",
"clipdist": 32,
"name": "TNT Barrel",
"palette": 0,
"repeats": {
"x": 0,
"y": 0
},
"tile_config": {
"tile": 907
}
},
"401": {
"blocking": 0,
"category": "gibbable",
"clipdist": 16,
"name": "Armed Proximity Bomb",
"palette": 0,
"repeats": {
"x": 8,
"y": 8
},
"tile_config": {
"tile": 3444
}
},
"402": {
"blocking": 0,
"category": "gibbable",
"clipdist": 16,
"name": "Armed Remote",
"palette": 0,
"repeats": {
"x": 8,
"y": 8
},
"tile_config": {
"tile": 3457
}
},
"403": {
"blocking": 0,
"category": "decoration",
"clipdist": 32,
"name": "Blue Vase",
"palette": 0,
"repeats": {
"x": 0,
"y": 0
}
},
"404": {
"blocking": 0,
"category": "decoration",
"clipdist": 32,
"name": "Brown Vase",
"palette": 0,
"repeats": {
"x": 0,
"y": 0
}
},
"405": {
"blocking": 0,
"category": "decoration",
"clipdist": 1,
"name": "Crate Face",
"palette": 0,
"repeats": {
"x": 0,
"y": 0
},
"tile_config": {
"tile": 462
}
},
"406": {
"blocking": 0,
"category": "environment",
"clipdist": 1,
"name": "Glass Window",
"palette": 0,
"repeats": {
"x": 0,
"y": 0
},
"tile_config": {
"tile": 266
}
},
"407": {
"blocking": 0,
"category": "gibbable",
"clipdist": 1,
"name": "Fluorescent Light",
"palette": 0,
"repeats": {
"x": 0,
"y": 0
},
"tile_config": {
"tile": 796
}
},
"408": {
"blocking": 0,
"category": "gibbable",
"clipdist": 1,
"name": "Wall Crack",
"palette": 0,
"repeats": {
"x": 0,
"y": 0
},
"tile_config": {
"tile": 1127
}
},
"409": {
"blocking": 0,
"category": "environment",
"clipdist": 1,
"name": "Wood Beam",
"palette": 0,
"repeats": {
"x": 0,
"y": 0
},
"tile_config": {
"tile": 1142
}
},
"410": {
"blocking": 0,
"category": "gibbable",
"clipdist": 1,
"name": "Spider Web",
"palette": 0,
"repeats": {
"x": 0,
"y": 0
},
"tile_config": {
"tile": 1069
}
},
"411": {
"blocking": 0,
"category": "gibbable",
"clipdist": 1,
"name": "Metal Grate 1",
"palette": 0,
"repeats": {
"x": 0,
"y": 0
},
"tile_config": {
"tile": 123
}
},
"412": {
"blocking": 0,
"category": "gibbable",
"clipdist": 1,
"name": "Flammable Tree",
"palette": 0,
"repeats": {
"x": 0,
"y": 0
}
},
"413": {
"blocking": 0,
"category": "gibbable",
"clipdist": 1,
"name": "Machine Gun",
"palette": 0,
"repeats": {
"x": 0,
"y": 0
}
},
"414": {
"blocking": 0,
"category": "gibbable",
"clipdist": 8,
"name": "Falling Walk",
"palette": 0,
"repeats": {
"x": 0,
"y": 0
}
},
"415": {
"blocking": 1,
"category": "gibbable",
"clipdist": 48,
"name": "Kickable Pail",
"palette": 0,
"repeats": {
"x": 0,
"y": 0
}
},
"416": {
"blocking": 0,
"category": "gibbable",
"clipdist": 1,
"name": "Gib Object",
"palette": 0,
"repeats": {
"x": 0,
"y": 0
}
},
"417": {
"blocking": 0,
"category": "gibbable",
"clipdist": 1,
"name": "Explode Object",
"palette": 0,
"repeats": {
"x": 0,
"y": 0
}
},
"418": {
"blocking": 0,
"category": "decoration",
"clipdist": 16,
"name": "Unknown",
"palette": 0,
"repeats": {
"x": 8,
"y": 8
},
"tile_config": {
"tile": 0
}
},
"419": {
"blocking": 0,
"category": "decoration",
"clipdist": 16,
"name": "Unknown",
"palette": 0,
"repeats": {
"x": 8,
"y": 8
},
"tile_config": {
"tile": 0
}
},
"420": {
"blocking": 0,
"category": "decoration",
"clipdist": 16,
"name": "Unknown",
"palette": 0,
"repeats": {
"x": 8,
"y": 8
},
"tile_config": {
"tile": 0
}
},
"421": {
"blocking": 0,
"category": "decoration",
"clipdist": 16,
"name": "Unknown",
"palette": 0,
"repeats": {
"x": 8,
"y": 8
},
"tile_config": {
"tile": 0
}
},
"422": {
"blocking": 0,
"category": "decoration",
"clipdist": 16,
"name": "Unknown",
"palette": 0,
"repeats": {
"x": 0,
"y": 0
},
"tile_config": {
"tile": 0
}
},
"423": {
"blocking": 0,
"category": "decoration",
"clipdist": 1,
"name": "Unknown",
"palette": 10,
"repeats": {
"x": 16,
"y": 16
},
"tile_config": {
"tile": 0
}
},
"424": {
"blocking": 0,
"category": "decoration",
"clipdist": 1,
"name": "Unknown",
"palette": 2,
"repeats": {
"x": 0,
"y": 0
},
"tile_config": {
"tile": 0
}
},
"425": {
"blocking": 1,
"category": "decoration",
"clipdist": 10,
"name": "Unknown",
"palette": 0,
"repeats": {
"x": 12,
"y": 12
},
"tile_config": {
"tile": 0
}
},
"426": {
"blocking": 1,
"category": "decoration",
"clipdist": 8,
"name": "Unknown",
"palette": 0,
"repeats": {
"x": 0,
"y": 0
},
"tile_config": {
"tile": 0
}
},
"427": {
"blocking": 1,
"category": "gibbable",
"clipdist": 32,
"name": "Zombie Head",
"palette": 0,
"repeats": {
"x": 10,
"y": 10
}
},
"428": {
"blocking": 0,
"category": "decoration",
"clipdist": 32,
"name": "Unknown",
"palette": 0,
"repeats": {
"x": 16,
"y": 16
},
"seq": 22,
"tile_config": {
"tile": 0
}
},
"429": {
"blocking": 0,
"category": "decoration",
"clipdist": 32,
"name": "Unknown",
"palette": 0,
"repeats": {
"x": 8,
"y": 8
},
"tile_config": {
"tile": 0
}
},
"430": {
"blocking": 0,
"category": "decoration",
"clipdist": 32,
"name": "Unknown",
"palette": 0,
"repeats": {
"x": 8,
"y": 8
},
"tile_config": {
"tile": 0
}
},
"431": {
"blocking": 1,
"category": "decoration",
"clipdist": 48,
"name": "Unknown",
"palette": 0,
"repeats": {
"x": 12,
"y": 12
},
"tile_config": {
"tile": 0
}
},
"432": {
"blocking": 0,
"category": "decoration",
"clipdist": 48,
"name": "Unknown",
"palette": 0,
"repeats": {
"x": 4,
"y": 4
},
"tile_config": {
"tile": 0
}
},
"451": {
"category": "traps",
"name": "Rock Trap"
},
"452": {
"category": "traps",
"name": "Flame Trap",
"tile_config": {
"tile": 2183
}
},
"454": {
"category": "traps",
"name": "Saw Blade",
"tile_config": {
"tile": 655
}
},
"455": {
"category": "traps",
"name": "Electric Zap",
"tile_config": {
"tile": 1156
}
},
"456": {
"category": "traps",
"name": "Switched Zap",
"tile_config": {
"tile": 1156
}
},
"457": {
"category": "traps",
"name": "Pendulum",
"tile_config": {
"tile": 1080
}
},
"458": {
"category": "traps",
"name": "Guillotine",
"tile_config": {
"tile": 835
}
},
"459": {
"category": "traps",
"name": "Hidden Exploder",
"repeats": {
"x": 1,
"y": 16
},
"tile_config": {
"tile": 908
}
},
"460": {
"blocking": 0,
"category": "decoration",
"name": "Unknown",
"palette": 0,
"repeats": {
"x": 8,
"y": 8
},
"tile_config": {
"tile": 0
}
},
"511": {
"blocking": 2,
"category": "gibbable",
"name": "Gib Wall"
},
"700": {
"category": "environment",
"name": "Trigger Generator"
},
"701": {
"category": "environment",
"name": "Water Drip"
},
"702": {
"category": "environment",
"name": "Blood Drip"
},
"703": {
"category": "environment",
"name": "Fireball Generator"
},
"704": {
"category": "environment",
"name": "Ecto Skul Generator"
},
"705": {
"category": "environment",
"name": "Dart Generator"
},
"706": {
"category": "environment",
"name": "Bubble Generator"
},
"707": {
"category": "environment",
"name": "Multi Bubble Generator"
},
"708": {
"category": "sounds",
"invisible": true,
"name": "SFX Generator",
"properties": [
{
"from": "data_1",
"name": "Sound To Play",
"type": "sound"
}
],
"tile_config": {
"tile": 2519
}
},
"709": {
"category": "sounds",
"invisible": true,
"name": "Sector SFX",
"properties": [
{
"from": "data_1",
"name": "Going On Sound",
"type": "sound"
},
{
"from": "data_2",
"name": "Going On Stop Sound",
"type": "sound"
},
{
"from": "data_3",
"name": "Going Off Sound",
"type": "sound"
},
{
"from": "data_4",
"name": "Going Off Stop Sound",
"type": "sound"
}
],
"tile_config": {
"tile": 2520
}
},
"710": {
"category": "sounds",
"invisible": true,
"name": "Ambient SFX",
"properties": [
{
"from": "data_1",
"name": "Distance To Start Falling Off",
"type": "int"
},
{
"from": "data_2",
"name": "Distance To Stop Playing",
"type": "int"
},
{
"from": "data_3",
"name": "Sound Number",
"type": "sound"
},
{
"from": "data_4",
"name": "Max Volume",
"type": "int"
}
],
"status_number": 12,
"tile_config": {
"tile": 2520
}
},
"711": {
"category": "sounds",
"invisible": true,
"name": "Player SFX",
"palette": 5,
"properties": [
{
"from": "data_1",
"name": "Sound To Play",
"type": "sound"
}
],
"tile_config": {
"tile": 2519
}
},
"10231": {
"blocking": 1,
"category": "decoration",
"clipdist": 48,
"name": "Unknown",
"repeats": {
"x": 8,
"y": 9
},
"seq": 12032,
"tile_config": {
"tile": 0
}
},
"10232": {
"blocking": 1,
"category": "decoration",
"clipdist": 48,
"name": "Unknown",
"repeats": {
"x": 8,
"y": 9
},
"seq": 12032,
"tile_config": {
"tile": 0
}
},
"10233": {
"blocking": 1,
"category": "decoration",
"clipdist": 48,
"name": "Unknown",
"repeats": {
"x": 8,
"y": 9
},
"seq": 12032,
"tile_config": {
"tile": 0
}
}
}
blood = {'swappableItems':{}, 'swappableEnemies':{}, 'keyItems':{}, 'traps':{}, 'switches':{}}
import json
blood_sprites = json.load(open('blood_sprites.json'))
def add_sprite(k, spritenum, v):
d = dict(name=v['name'], category=v['category'], lowtag=k)
if 'repeats' in v:
d.update(xrepeat=v['repeats']['x'], yrepeat=v['repeats']['y'])
if d['category'] in ['weapons', 'ammo', 'items']:
blood['swappableItems'][spritenum] = d
elif d['category'] == 'keys':
blood['keyItems'][spritenum] = d
elif d['category'] == 'monsters':
blood['swappableEnemies'][spritenum] = d
elif d['category'] == 'traps':
blood['traps'][spritenum] = d
elif d['category'] == 'switches':
blood['switches'][spritenum] = d
for k,v in blood_sprites.items():
if 'tile_config' not in v:
continue
if 'tile' in v['tile_config']:
spritenum = v['tile_config']['tile']
add_sprite(k, spritenum, v)
elif 'tiles' in v['tile_config']:
for t in v['tile_config']['tiles']:
spritenum = t
add_sprite(k, spritenum, v)
for k in blood:
print('\n', k)
sprites = list(blood[k].keys())
sprites.sort()
for i in sprites:
s = blood[k][i]
data = 'SpriteInfo(\'' + s['name'] + '\', \'' + s['category'] + '\', lowtag=' + str(s['lowtag'])
if 'xrepeat' in s:
data += ', xrepeat=' + str(s['xrepeat']) + ', yrepeat=' + str(s['yrepeat'])
data += '),'
print(str(i) +': ', data, sep='')
print('')
json
{
832: {
'name': 'Random Ammo',
'category': 'ammo',
'xrepeat': 12,
'yrepeat': 12
},
559: {
'name': 'Sawed Off',
'category': 'weapons',
'xrepeat': 10,
'yrepeat': 10
},
558: {
'name': 'Tommy Gun',
'category': 'weapons',
'xrepeat': 10,
'yrepeat': 10
},
524: {
'name': 'Flare Pistol',
'category': 'weapons',
'xrepeat': 10,
'yrepeat': 10
},
525: {
'name': 'Voodoo Doll',
'category': 'weapons',
'xrepeat': 10,
'yrepeat': 10
},
539: {
'name': 'Tesla Cannon',
'category': 'weapons',
'xrepeat': 10,
'yrepeat': 10
},
526: {
'name': 'Napalm Launcher',
'category': 'weapons',
'xrepeat': 10,
'yrepeat': 10
},
800: {
'name': 'Life Leech',
'category': 'weapons',
'xrepeat': 10,
'yrepeat': 10
},
618: {
'name': 'Spray Can',
'category': 'weapons',
'xrepeat': 10,
'yrepeat': 10
},
589: {
'name': 'Bundle of TNT',
'category': 'weapons',
'xrepeat': 10,
'yrepeat': 10
},
809: {
'name': 'Case of TNT',
'category': 'weapons',
'xrepeat': 10,
'yrepeat': 10
},
811: {
'name': 'Proximity Detonator',
'category': 'weapons',
'xrepeat': 10,
'yrepeat': 10
},
810: {
'name': 'Remote Detonator',
'category': 'weapons',
'xrepeat': 10,
'yrepeat': 10
},
820: {
'name': 'Trapped Soul',
'category': 'ammo',
'xrepeat': 6,
'yrepeat': 6
},
619: {
'name': '4 Shotgun Shells',
'category': 'ammo',
'xrepeat': 10,
'yrepeat': 10
},
812: {
'name': 'Box of Shotgun Shells',
'category': 'ammo',
'xrepeat': 10,
'yrepeat': 10
},
813: {
'name': 'A Few Bullets',
'category': 'ammo',
'xrepeat': 10,
'yrepeat': 10
},
817: {
'name': 'Full Drum of Bullets',
'category': 'ammo',
'xrepeat': 10,
'yrepeat': 10
},
548: {
'name': 'Tesla Charge',
'category': 'ammo',
'xrepeat': 6,
'yrepeat': 6
},
816: {
'name': 'Flares',
'category': 'ammo',
'xrepeat': 10,
'yrepeat': 10
},
801: {
'name': 'Gasoline Can',
'category': 'ammo',
'xrepeat': 10,
'yrepeat': 10
},
519: {
'name': "Doctor's Bag",
'category': 'items',
'xrepeat': 12,
'yrepeat': 12
},
822: {
'name': 'Medicine Pouch',
'category': 'items',
'xrepeat': 10,
'yrepeat': 10
},
2169: {
'name': 'Life Essence',
'category': 'items',
'xrepeat': 10,
'yrepeat': 10
},
2433: {
'name': 'Life Seed',
'category': 'items',
'xrepeat': 10,
'yrepeat': 10
},
896: {
'name': 'Limited Invisibility',
'category': 'items',
'xrepeat': 10,
'yrepeat': 10
},
825: {
'name': 'Invulnerability',
'category': 'items',
'xrepeat': 10,
'yrepeat': 10
},
827: {
'name': 'Boots of Jumping',
'category': 'items',
'xrepeat': 10,
'yrepeat': 10
},
828: {
'name': 'Raven Flight',
'category': 'items',
'xrepeat': 12,
'yrepeat': 12
},
829: {
'name': 'Guns Akimbo',
'category': 'items',
'xrepeat': 10,
'yrepeat': 10
},
830: {
'name': 'Diving Suit',
'category': 'items',
'xrepeat': 12,
'yrepeat': 12
},
831: {
'name': 'Gas Mask',
'category': 'items',
'xrepeat': 10,
'yrepeat': 10
},
760: {
'name': 'Crystal Ball',
'category': 'items',
'xrepeat': 10,
'yrepeat': 10
},
2428: {
'name': 'Reflective Shots',
'category': 'items',
'xrepeat': 10,
'yrepeat': 10
},
839: {
'name': 'Beast Vision',
'category': 'items',
'xrepeat': 10,
'yrepeat': 10
},
768: {
'name': 'Shadow Cloak',
'category': 'items',
'xrepeat': 12,
'yrepeat': 12
},
840: {
'name': 'Rage Shroom',
'category': 'items',
'xrepeat': 12,
'yrepeat': 12
},
841: {
'name': 'Delirium Shroom',
'category': 'items',
'xrepeat': 12,
'yrepeat': 12
},
842: {
'name': 'Grow Shroom',
'category': 'items',
'xrepeat': 12,
'yrepeat': 12
},
843: {
'name': 'Shrink Shroom',
'category': 'items',
'xrepeat': 12,
'yrepeat': 12
},
518: {
'name': 'Tome',
'category': 'items',
'xrepeat': 10,
'yrepeat': 10
},
522: {
'name': 'Black Chest',
'category': 'items',
'xrepeat': 12,
'yrepeat': 12
},
523: {
'name': 'Wooden Chest',
'category': 'items',
'xrepeat': 12,
'yrepeat': 12
},
2628: {
'name': 'Basic Armor',
'category': 'items',
'xrepeat': 12,
'yrepeat': 12
},
2586: {
'name': 'Body Armor',
'category': 'items',
'xrepeat': 12,
'yrepeat': 12
},
2578: {
'name': 'Fire Armor',
'category': 'items',
'xrepeat': 12,
'yrepeat': 12
},
2602: {
'name': 'Spirit Armor',
'category': 'items',
'xrepeat': 12,
'yrepeat': 12
},
2594: {
'name': 'Super Armor',
'category': 'items',
'xrepeat': 12,
'yrepeat': 12
}
}
--
def GetPicnumName(self, picnum: int) -> str:
valname = None
if self.gameMapSettings and picnum in self.gameMapSettings.swappableItems:
valname = self.gameMapSettings.swappableItems[picnum]['name']
elif self.gameMapSettings and picnum in self.gameMapSettings.swappableEnemies:
valname = self.gameMapSettings.swappableEnemies[picnum]['name']
if valname:
return valname# + ' ('+str(picnum)+')'
return str(picnum)
def DescribeSprite(self, sprite) -> str:
name = self.GetPicnumName(sprite.picnum)
# tuple gives parens so it looks better than a list
pos = tuple(sprite.pos)
category = ''
if self.gameMapSettings and sprite.picnum in self.gameMapSettings.swappableItems:
category = self.gameMapSettings.swappableItems[sprite.picnum].get('category', '')
elif self.gameMapSettings and sprite.picnum in self.gameMapSettings.swappableEnemies:
category = self.gameMapSettings.swappableEnemies[sprite.picnum].get('category', '')
info = ' \n' + str(sprite.picnum) + ": SpriteInfo('" + name + "', '" + category + "', lowtag=" + str(sprite.lowtag)
info += ', xrepeat=' + str(sprite.texcoords[0]) + ', yrepeat=' + str(sprite.texcoords[1])
info += '),\n'
if sprite.picnum not in self.gameMapSettings.swappableEnemies:
info = ''
return name + ' ' + str(pos) + desc
also needs the lowtag to go with the palette, at least for Blood
blood = {'swappableItems':{}, 'swappableEnemies':{}, 'keyItems':{}, 'traps':{}, 'switches':{}}
import json
blood_sprites = json.load(open('blood_sprites.json'))
def add_sprite(k, spritenum, v):
palettes = [v.get('palette', 0)]
category = None
d = dict(name=v['name'], category=v['category'], lowtag=k)
if 'repeats' in v:
d.update(xrepeat=v['repeats']['x'], yrepeat=v['repeats']['y'])
if d['category'] in ['weapons', 'ammo', 'items']:
category = 'swappableItems'
elif d['category'] == 'keys':
category = 'keyItems'
elif d['category'] == 'monsters':
category = 'swappableEnemies'
elif d['category'] == 'traps':
category = 'traps'
elif d['category'] == 'switches':
category = 'switches'
if not category:
print(k, spritenum, v, d)
return
if spritenum in blood[category] and 'palettes' in blood[category][spritenum]:
palettes = palettes + blood[category][spritenum]['palettes']
d['palettes'] = list(set(palettes))
blood[category][spritenum] = d
for k,v in blood_sprites.items():
if 'tile_config' not in v:
continue
if 'tile' in v['tile_config']:
spritenum = v['tile_config']['tile']
add_sprite(k, spritenum, v)
elif 'tiles' in v['tile_config']:
for t in v['tile_config']['tiles']:
spritenum = t
add_sprite(k, spritenum, v)
for k in blood:
print('\n\n', k)
sprites = list(blood[k].keys())
sprites.sort()
for i in sprites:
s = blood[k][i]
data = 'SpriteInfo(\'' + s['name'] + '\', \'' + s['category'] + '\', lowtag=' + str(s['lowtag'])
if 'xrepeat' in s:
data += ', xrepeat=' + str(s['xrepeat']) + ', yrepeat=' + str(s['yrepeat'])
if s['palettes'] != [0]:
data += ', palettes=' + str(s['palettes'])
data += '),'
print(str(i) +': ', data, sep='')
print('')
sys.exit(0)