mirror of
https://github.com/JezuzLizard/BO2-Reimagined.git
synced 2025-06-11 23:57:59 -05:00
Grief: limited weapons check saved weapons loadout
This commit is contained in:
@ -465,6 +465,7 @@
|
|||||||
* Added text when rounds are won/lost
|
* Added text when rounds are won/lost
|
||||||
* Added new audio when enemy players bleed out
|
* Added new audio when enemy players bleed out
|
||||||
* Round reset properly restores dual wield weapon left clip ammo, alternative weapon ammo, and equipment
|
* Round reset properly restores dual wield weapon left clip ammo, alternative weapon ammo, and equipment
|
||||||
|
* Limited weapons can no longer be obtained if another player had the weapon when they bled out
|
||||||
* Spawn points are assigned to a team
|
* Spawn points are assigned to a team
|
||||||
* Teams switch spawn points each round
|
* Teams switch spawn points each round
|
||||||
* Players respawn at initial spawn points
|
* Players respawn at initial spawn points
|
||||||
|
@ -52,6 +52,7 @@ init()
|
|||||||
setteamscore("allies", 0);
|
setteamscore("allies", 0);
|
||||||
|
|
||||||
player_spawn_override();
|
player_spawn_override();
|
||||||
|
maps/mp/zombies/_zm_weapons::add_custom_limited_weapon_check(::grief_loadout_limited_weapon_check);
|
||||||
|
|
||||||
level thread grief_score_hud();
|
level thread grief_score_hud();
|
||||||
level thread set_grief_vars();
|
level thread set_grief_vars();
|
||||||
@ -1698,6 +1699,8 @@ grief_laststand_weapons_return()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
self.grief_savedweapon_weapons = undefined;
|
||||||
|
|
||||||
primaries = self getweaponslistprimaries();
|
primaries = self getweaponslistprimaries();
|
||||||
foreach ( weapon in primaries )
|
foreach ( weapon in primaries )
|
||||||
{
|
{
|
||||||
@ -1801,6 +1804,32 @@ func_should_drop_meat()
|
|||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
grief_loadout_limited_weapon_check(weapon)
|
||||||
|
{
|
||||||
|
count = 0;
|
||||||
|
i = 0;
|
||||||
|
players = get_players();
|
||||||
|
|
||||||
|
while(i < players.size)
|
||||||
|
{
|
||||||
|
if(isDefined(players[i].grief_savedweapon_weapons))
|
||||||
|
{
|
||||||
|
foreach(grief_savedweapon in players[i].grief_savedweapon_weapons)
|
||||||
|
{
|
||||||
|
if(grief_savedweapon == weapon)
|
||||||
|
{
|
||||||
|
count++;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
i++;
|
||||||
|
}
|
||||||
|
|
||||||
|
return count;
|
||||||
|
}
|
||||||
|
|
||||||
remove_round_number()
|
remove_round_number()
|
||||||
{
|
{
|
||||||
level endon("end_game");
|
level endon("end_game");
|
||||||
|
Reference in New Issue
Block a user