Skip to content

Commit

Permalink
Spiral mine jsonify (#48003)
Browse files Browse the repository at this point in the history
  • Loading branch information
Night-Pryanik authored and ZhilkinSerg committed Apr 20, 2021
1 parent 7cd6e4b commit 6dfb0cf
Show file tree
Hide file tree
Showing 15 changed files with 546 additions and 161 deletions.
20 changes: 20 additions & 0 deletions data/json/furniture_and_terrain/terrain-walls.json
Original file line number Diff line number Diff line change
Expand Up @@ -1482,5 +1482,25 @@
"ter_set": "t_null",
"items": [ { "item": "rock", "count": [ 3, 8 ] }, { "item": "pebble", "count": [ 20, 38 ] } ]
}
},
{
"type": "terrain",
"id": "t_pillar",
"name": "pillar",
"looks_like": "t_column",
"description": "A concrete column that helps keep the mine's ceiling and walls from collapsing.",
"symbol": "1",
"color": "light_gray",
"move_cost": 0,
"coverage": 80,
"flags": [ "WALL", "PERMEABLE", "MINEABLE" ],
"bash": {
"str_min": 120,
"str_max": 200,
"sound": "crash!",
"sound_fail": "whump!",
"ter_set": "t_reb_cage",
"items": [ { "item": "rock", "count": [ 10, 22 ] } ]
}
}
]
20 changes: 11 additions & 9 deletions data/json/mapgen/mine/mine_shaft.json
Original file line number Diff line number Diff line change
Expand Up @@ -43,28 +43,28 @@
"rows": [
"###### ## #################### #######",
"###### ## ################### ########",
"###### ## ############# #### #########",
"###### ## ############# #### #########",
"####### ############### ### ##########",
"######## ############### ## ###########",
"######## ############## ############",
" ###### ################ ##########",
" ## ################# ###########",
"# ##### ###### ###########",
" ## ################# ###########",
"# ##### ###### ###########",
" #### ## ",
"###### ### #### #### ",
"###### |-| #### ##### ",
"###### |----|<|--| ",
"##### |!@@...!@@| #### #####",
"### |.@@....@@| ######### ######",
"### |.@@....@@| ######### ######",
" +.......@@| ########## ######",
"*****************=========| # ######## ####",
" +.......®®| ####### ####",
" +.......®®| ####### ####",
" |.........| ######### ####",
"# |.........| ######### #",
"## |LLLL|SSSS| ######### #",
"#### |----|----| ######## #",
"## |LLLL|SSSS| ######### #",
"#### |----|----| ######## #",
"###### ######### ",
"####### ## ####### ######## "
"####### ## ####### ######## "
],
"terrain": {
"<": "t_ladder_up",
Expand All @@ -78,6 +78,7 @@
"=": "t_conveyor",
"*": "t_railroad_track_small",
"®": "t_thconc_floor",
"№": "t_pillar",
"L": "t_thconc_floor",
"S": "t_thconc_floor"
},
Expand All @@ -86,7 +87,8 @@
"L": [ { "item": "clothing_work_set", "chance": 50 }, { "item": "hardware_clothing", "chance": 50 } ],
"S": { "item": "mine_equipment", "chance": 80 }
},
"place_vehicles": [ { "vehicle": "trolley", "x": 10, "y": 16, "chance": 100, "status": 0 } ]
"place_vehicles": [ { "vehicle": "trolley", "x": 10, "y": 16, "chance": 100, "status": 0 } ],
"monsters": { " ": { "monster": "GROUP_MINER", "chance": 1, "density": 0.0005 } }
}
}
]
190 changes: 190 additions & 0 deletions data/json/mapgen/mine/mine_spiral.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,190 @@
[
{
"type": "monstergroup",
"name": "GROUP_MINER",
"default": "mon_zombie_miner",
"monsters": [ ]
},
{
"type": "mapgen",
"method": "json",
"om_terrain": [ [ "mine_spiral_west", "mine_spiral_central", "mine_spiral_east" ] ],
"object": {
"fill_ter": "t_rock_floor",
"rows": [
"########################################################################",
"@@@@@@@@@@@@@@@@@@@@@@@@@###############################################",
"@ @###############################################",
"@ ##################### @###############################################",
"@ #@@@@@@@@@@@@@@@@@@@# @###############################################",
"@ #@ @# @###############################################",
"@ #@ ############### @# @###############################################",
"@ #@ #@@@@@@@@@@@### @# @###############################################",
"@ #@ #@ ># @# @###############################################",
"@ #@ #@ @@@@@@@@@### @# @###############################################",
"@ #@ #@ ############ @# @###############################################",
"@ #@ #@ @# @###############################################",
"@ #@ #@@@@@@@@@@@@@@@@# @#####################@@@@@@@@@@@@@@@@@@@@@@@@@@",
"@ #@ ################## @#####################! @@@@@@@@@@@!@@@@@@@@@@ !",
"@ #@ @##################### ",
"@ #@@@@@@@@@@@@@@@@########################### ",
"@ ############################################**************************",
"@ @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@## #### ",
"@ # ## ",
"@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@##### ! @@@@@@@@@@!@@@@@@@@@@ !",
"###############################################@@@@@@@@@@@@@@@@@@@@@@@@@",
"########################################################################",
"########################################################################",
"########################################################################"
],
"terrain": {
"@": [ [ "t_rock", 4 ], [ "t_rock_floor", 1 ] ],
"#": "t_rock",
"*": "t_railroad_track_small",
"!": "t_pillar",
">": "t_slope_down"
},
"items": { " ": { "item": "mine_equipment", "chance": 1 } },
"monsters": { " ": { "monster": "GROUP_MINER", "chance": 1, "density": 0.001 } }
}
},
{
"type": "mapgen",
"method": "json",
"om_terrain": [
[ "mine_spiral_-1_nw", "mine_spiral_-1_n", "mine_spiral_-1_ne" ],
[ "mine_spiral_-1_sw", "mine_spiral_-1_s", "mine_spiral_-1_se" ]
],
"object": {
"fill_ter": "t_rock_floor",
"rows": [
"####################################@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@",
"####################################@ @",
"########@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ 1 1 ###### @",
"########@ # @",
"########@ @@@@@@@@@@@@@@@@@@@@@@@@@@@ # #### @",
"########@ @##################@######@ # #~ # @",
"########@ @# @######@ # # @",
"########@ @# @@@@@@@@@@@@@@@ @######@ ###### @",
"########@ @# @#############@ @######@ @",
"########@ @# @####< #@ @######@ @",
"########@ @# @########### #@ @######@ @",
"########@ @# @@@@@@@@@@@@ #@ @######@ 1 1 1 @",
"########@ @# #@ @######@ @",
"########@ @################@ @######@ @",
"########@ @@@@@@@@@@@@@@@@@@ @######@ @",
"########@ @######@ @",
"########@@@@@@@@@@@@@@@@@@@@@@######@ @",
"####################################@ @",
"####################################@@@@@@@@@@@@@@@@@@@@@@@ @",
"##########################################################@ @",
"##########################################################@ @",
"#####@@@@@@@@@@@@@@@@@@####@@@@@@@@@@@@@@@@@@@############@ @",
"##### #### @############@ @",
"##### #### #### #### ############@ @",
"#####%%%%%%######%%%%%%####!!!!!!######$$$$$$ ############@ @",
"#####% ###### %####! ##### $ ############@ @",
"#####% %%%%######%%%% %####! !!!!##### $$$$ $ ############@ @",
"#####% % %######% % %####! ! !##### $ >$ $ ############@ @",
"#####% %######% %####! !##### $ $ ############@ @",
"#####%%%%%%######%%%%%%####!!!!!!##### $$$$$$ ############@ @",
"#### ###### ## ##### ############@ @",
"### ###### @####@ @############@ @",
"#@ @@@@@@@######@@@@@@@@@@@@@@@@@####@@@@@@@@############@ @",
"#@ @#####################################################@ @",
"#@ @####################################################### @",
"#@ @@@@@@@######@@@@@@@@@@@@@@@@######@@@@@@@@@@@@@@@@@@@### @",
"### ###### ###### ## @",
"#### ###### ## ###### ### #### ##",
"##### ###### #### ###### ##### ###### ###",
"#####^^^^^^######^^^^^^####&&&&&&######&&&&&&######******######******###",
"#####^ ###### ^####& ###### &######* ###### *###",
"#####^ ^^^^######^^^^ ^####& &&&&######&&&& &######* ****######**** *###",
"#####^ ^ ^######^ ^ ^####& & &######& & &######* * *######* * *###",
"#####^ ^######^ ^####& &######& &######* *######* *###",
"#####^^^^^^######^^^^^^####&&&&&&######&&&&&&######******######******###",
"##### #### #### #### ###### ###### ###",
"##### @##@ @####@ ###",
"#####@@@@@@@@@@@@@@@@@@@##@@@@@@@@@@@@@@@@@@@@####@@@@@@@@@@@@@@@@@@@###"
],
"terrain": {
"@": [ [ "t_rock", 4 ], [ "t_rock_floor", 1 ] ],
"#": "t_rock",
">": "t_slope_down",
"<": "t_slope_up",
"$": "t_lava"
},
"furniture": { "&": "f_wreckage", "^": "f_rubble", "%": "f_rubble_rock", "!": "f_rubble_landfill" },
"nested": {
"1": { "chunks": [ [ "spiral_cw", 25 ], [ "spiral_ccw", 25 ], [ "spiral_boulder_cw", 25 ], [ "spiral_boulder_ccw", 25 ] ] }
},
"item": { "*": { "item": "rock", "chance": 100 } },
"npcs": { "~": { "class": "spiral_madman" } }
}
},
{
"type": "mapgen",
"method": "json",
"om_terrain": [
[ "mine_spiral_finale_nw", "mine_spiral_finale_n", "mine_spiral_finale_ne" ],
[ "mine_spiral_finale_sw", "mine_spiral_finale_s", "mine_spiral_finale_se" ]
],
"object": {
"fill_ter": "t_rock_floor",
"rows": [
"###### 1 1 1 1 1 1 1 1 ",
"# ",
"# #### ",
"# #! # ",
"# # ",
"###### ",
" ",
" ###### ",
" # ",
" #### # ",
" # !# # ",
" # # ",
" ###### ",
" ",
"###### 1 1 1 1 1 1 ###### ",
"# # ",
"# #### #### # ",
"# #! # # # # ",
"# # # # ",
"###### ###### ",
" ",
"###### ###### ###### ",
"# # # ",
"# #### #### # #### # ",
"# # # # !# # # # # ",
"# # # # # # ",
"###### ###### ###### ",
" < ",
"###### 1 ###### 1 1 1 ###### ",
"# # # ",
"# #### # #### #### # ",
"# #! # # #! # # # # ",
"# # # # # # ",
"###### ###### ###### ",
" ",
"###### ###### ",
"# # ",
"# #### #### # ",
"# # # # !# # ",
"# # # # ",
"###### ###### ",
" ",
"###### 1 1 1 1 1 1 1 1 ",
"# ",
"# #### ",
"# #! # ",
"# # ",
"###### "
],
"terrain": { "@": [ [ "t_rock", 4 ], [ "t_rock_floor", 1 ] ], "#": "t_rock", "<": "t_slope_up" },
"monsters": { " ": { "monster": "GROUP_SPIRAL", "chance": 1, "density": 0.001 } },
"nested": { "1": { "chunks": [ [ "spiral_cw", 50 ], [ "spiral_ccw", 50 ] ] } },
"items": { "!": { "item": "spiral", "chance": 60 } }
}
}
]
76 changes: 76 additions & 0 deletions data/json/mapgen/nested/mine_nested.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,76 @@
[
{
"type": "palette",
"id": "mine_palette",
"terrain": { "#": "t_rock", " ": "t_rock_floor", "$": "t_rock_floor" },
"furniture": { "$": "f_boulder_large" }
},
{
"type": "mapgen",
"method": "json",
"nested_mapgen_id": "spiral_cw",
"object": {
"palettes": [ "mine_palette" ],
"mapgensize": [ 6, 6 ],
"rows": [
"######",
" #",
"#### #",
"# # #",
"# #",
"######"
]
}
},
{
"type": "mapgen",
"method": "json",
"nested_mapgen_id": "spiral_ccw",
"object": {
"palettes": [ "mine_palette" ],
"mapgensize": [ 6, 6 ],
"rows": [
"######",
"# ",
"# ####",
"# # #",
"# #",
"######"
]
}
},
{
"type": "mapgen",
"method": "json",
"nested_mapgen_id": "spiral_boulder_cw",
"object": {
"palettes": [ "mine_palette" ],
"mapgensize": [ 6, 6 ],
"rows": [
"$$$$$$",
" $",
"$$$$ $",
"$ $ $",
"$ $",
"$$$$$$"
]
}
},
{
"type": "mapgen",
"method": "json",
"nested_mapgen_id": "spiral_boulder_ccw",
"object": {
"palettes": [ "mine_palette" ],
"mapgensize": [ 6, 6 ],
"rows": [
"$$$$$$",
"$ ",
"$ $$$$",
"$ $ $",
"$ $",
"$$$$$$"
]
}
}
]
Loading

0 comments on commit 6dfb0cf

Please sign in to comment.