Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replace random lab turrets with lab security #40063

Merged
merged 1 commit into from
May 4, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 8 additions & 16 deletions data/json/mapgen/lab/lab_floorplan_cross.json
Original file line number Diff line number Diff line change
Expand Up @@ -659,8 +659,7 @@
" ",
" "
],
"palettes": [ "lab_palette", "lab_loot_bionic_vault" ],
"place_monster": [ { "monster": "mon_turret_rifle", "x": [ 11, 12 ], "y": [ 2, 5 ], "chance": 25 } ]
"palettes": [ "lab_palette", "lab_loot_bionic_vault" ]
}
},
{
Expand Down Expand Up @@ -695,8 +694,7 @@
" ",
" "
],
"palettes": [ "lab_palette", "lab_loot_serum_vault" ],
"place_monster": [ { "monster": "mon_turret_rifle", "x": [ 11, 12 ], "y": [ 2, 5 ], "chance": 10 } ]
"palettes": [ "lab_palette", "lab_loot_serum_vault" ]
}
},
{
Expand Down Expand Up @@ -731,8 +729,7 @@
" ",
" "
],
"palettes": [ "lab_palette", "lab_loot_bionic_vault" ],
"place_monster": [ { "monster": "mon_turret_rifle", "x": [ 2, 5 ], "y": [ 11, 12 ], "chance": 25 } ]
"palettes": [ "lab_palette", "lab_loot_bionic_vault" ]
}
},
{
Expand Down Expand Up @@ -767,8 +764,7 @@
" ",
" "
],
"palettes": [ "lab_palette", "lab_loot_serum_vault" ],
"place_monster": [ { "monster": "mon_turret_rifle", "x": [ 2, 5 ], "y": [ 11, 12 ], "chance": 10 } ]
"palettes": [ "lab_palette", "lab_loot_serum_vault" ]
}
},
{
Expand Down Expand Up @@ -803,8 +799,7 @@
" ------ ",
"####################### "
],
"palettes": [ "lab_palette", "lab_loot_bionic_vault" ],
"place_monster": [ { "monster": "mon_turret_rifle", "x": [ 11, 12 ], "y": [ 18, 21 ], "chance": 25 } ]
"palettes": [ "lab_palette", "lab_loot_bionic_vault" ]
}
},
{
Expand Down Expand Up @@ -839,8 +834,7 @@
" ------ ",
"####################### "
],
"palettes": [ "lab_palette", "lab_loot_serum_vault" ],
"place_monster": [ { "monster": "mon_turret_rifle", "x": [ 11, 12 ], "y": [ 18, 21 ], "chance": 10 } ]
"palettes": [ "lab_palette", "lab_loot_serum_vault" ]
}
},
{
Expand Down Expand Up @@ -875,8 +869,7 @@
" #",
" "
],
"palettes": [ "lab_palette", "lab_loot_bionic_vault" ],
"place_monster": [ { "monster": "mon_turret_rifle", "x": [ 18, 21 ], "y": [ 11, 12 ], "chance": 25 } ]
"palettes": [ "lab_palette", "lab_loot_bionic_vault" ]
}
},
{
Expand Down Expand Up @@ -911,8 +904,7 @@
" #",
" "
],
"palettes": [ "lab_palette", "lab_loot_serum_vault" ],
"place_monster": [ { "monster": "mon_turret_rifle", "x": [ 18, 21 ], "y": [ 11, 12 ], "chance": 10 } ]
"palettes": [ "lab_palette", "lab_loot_serum_vault" ]
}
}
]
2 changes: 1 addition & 1 deletion data/json/mapgen/lab/lab_floorplans.json
Original file line number Diff line number Diff line change
Expand Up @@ -488,7 +488,7 @@
"r": { "items": [ { "item": "mine_equipment", "chance": 30 } ] },
"c": { "items": [ { "item": "chem_lab", "chance": 30 }, { "item": "tools_science", "chance": 30 } ] }
},
"place_monster": [ { "monster": "mon_turret_rifle", "x": 11, "y": 9, "chance": 20 } ],
"place_monsters": [ { "monster": "GROUP_LAB_SECURITY", "x": [ 0, 11 ], "y": [ 8, 9 ], "chance": 20, "repeat": 7 } ],
"place_nested": [
{ "chunks": [ "lab_spawn_9x9_crossdoors" ], "x": 6, "y": 11 },
{ "chunks": [ "lab_spawn_7x7_wall_nw" ], "x": 12, "y": 2 },
Expand Down
4 changes: 2 additions & 2 deletions data/json/mapgen/lab/lab_rooms.json
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@
],
"palettes": [ "lab_palette", "lab_palette_map_computer" ],
"terrain": { "c": [ "t_thconc_floor" ] },
"place_monster": [ { "monster": "mon_turret_rifle", "x": [ 2, 3 ], "y": [ 3, 3 ] } ]
"place_monsters": [ { "monster": "GROUP_LAB_SECURITY", "x": [ 0, 6 ], "y": [ 0, 6 ], "repeat": [ 1, 6 ], "chance": 3 } ]
}
},
{
Expand All @@ -154,7 +154,7 @@
],
"palettes": [ "lab_palette", "lab_palette_map_computer" ],
"terrain": { "c": [ "t_thconc_floor" ] },
"place_monster": [ { "monster": "mon_turret_rifle", "x": [ 4, 4 ], "y": [ 1, 4 ] } ]
"place_monsters": [ { "monster": "GROUP_LAB_SECURITY", "x": [ 0, 6 ], "y": [ 0, 6 ], "repeat": [ 1, 6 ], "chance": 3 } ]
}
},
{
Expand Down
10 changes: 4 additions & 6 deletions data/json/mapgen/lab/lab_rooms_wall.json
Original file line number Diff line number Diff line change
Expand Up @@ -189,8 +189,7 @@
"|-------"
],
"palettes": [ "lab_palette", "lab_loot_bionic_vault" ],
"terrain": { "M": "t_wall_metal" },
"place_monster": [ { "monster": "mon_turret_rifle", "x": 5, "y": 3, "chance": 25 } ]
"terrain": { "M": "t_wall_metal" }
}
},
{
Expand All @@ -211,8 +210,7 @@
"|#######"
],
"palettes": [ "lab_palette", "lab_loot_serum_vault" ],
"terrain": { "M": "t_wall_metal" },
"place_monster": [ { "monster": "mon_turret_rifle", "x": 5, "y": 3, "chance": 10 } ]
"terrain": { "M": "t_wall_metal" }
}
},
{
Expand Down Expand Up @@ -435,14 +433,14 @@
"g,,,,,,,,,",
"|,,,,,,,,,",
"g,,,,,,,,,",
"|x,,,7,,,x",
"|x,,,,,,,x",
"g,,,,,,,,,",
"|,,,,,,,,,",
"g,,,,,,,,,",
"|x,,,x,,,x"
],
"palettes": [ "lab_palette" ],
"monster": { "7": { "monster": "mon_turret_rifle" } },
"place_monsters": [ { "monster": "GROUP_LAB_SECURITY", "x": [ 1, 9 ], "y": [ 1, 9 ] } ],
"terrain": { "g": "t_wall_glass", "G": "t_door_glass_lab_c", "7": "t_thconc_floor" }
}
},
Expand Down
1 change: 0 additions & 1 deletion data/json/monstergroups/lab.json
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,6 @@
{ "monster": "mon_skitterbot", "freq": 85, "cost_multiplier": 0 },
{ "monster": "mon_skitterbot", "freq": 85, "cost_multiplier": 0, "pack_size": [ 2, 3 ] },
{ "monster": "mon_skitterbot", "freq": 1, "cost_multiplier": 0, "pack_size": [ 8, 12 ] },
{ "monster": "mon_turret_rifle", "freq": 85, "cost_multiplier": 0 },
{ "monster": "mon_secubot", "freq": 1, "cost_multiplier": 10 },
{ "monster": "mon_talon_m202a1", "freq": 1, "cost_multiplier": 15 },
{ "monster": "mon_zombie_bio_op", "freq": 50, "cost_multiplier": 5 },
Expand Down
5 changes: 3 additions & 2 deletions src/mapgen.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,7 @@ static const mongroup_id GROUP_FUNGI_FUNGALOID( "GROUP_FUNGI_FUNGALOID" );
static const mongroup_id GROUP_HAZMATBOT( "GROUP_HAZMATBOT" );
static const mongroup_id GROUP_LAB( "GROUP_LAB" );
static const mongroup_id GROUP_LAB_CYBORG( "GROUP_LAB_CYBORG" );
static const mongroup_id GROUP_LAB_SECURITY( "GROUP_LAB_SECURITY" );
static const mongroup_id GROUP_NETHER( "GROUP_NETHER" );
static const mongroup_id GROUP_PLAIN( "GROUP_PLAIN" );
static const mongroup_id GROUP_ROBOT_SECUBOT( "GROUP_ROBOT_SECUBOT" );
Expand Down Expand Up @@ -6207,7 +6208,7 @@ void science_room( map *m, const point &p1, const point &p2, int z, int rotate )
tmpcomp->add_failure( COMPFAIL_SHUTDOWN );
tmpcomp->add_failure( COMPFAIL_ALARM );
tmpcomp->add_failure( COMPFAIL_DAMAGE );
m->place_spawns( GROUP_TURRET, 1,
m->place_spawns( GROUP_LAB_SECURITY, 1,
point( static_cast<int>( ( p1.x + p2.x ) / 2 ), desk ),
point( static_cast<int>( ( p1.x + p2.x ) / 2 ), desk ), 1, true );
} else {
Expand All @@ -6223,7 +6224,7 @@ void science_room( map *m, const point &p1, const point &p2, int z, int rotate )
tmpcomp->add_failure( COMPFAIL_SHUTDOWN );
tmpcomp->add_failure( COMPFAIL_ALARM );
tmpcomp->add_failure( COMPFAIL_DAMAGE );
m->place_spawns( GROUP_TURRET, 1,
m->place_spawns( GROUP_LAB_SECURITY, 1,
point( desk, static_cast<int>( ( p1.y + p2.y ) / 2 ) ),
point( desk, static_cast<int>( ( p1.y + p2.y ) / 2 ) ), 1, true );
}
Expand Down