1
0
mirror of https://github.com/JezuzLizard/BO2-Reimagined.git synced 2025-06-23 05:30:41 -05:00

Denizen: change player melee damage properly

This commit is contained in:
Jbleezy
2023-03-27 23:26:56 -07:00
parent 84eb491bc2
commit e7fe73e215
3 changed files with 47 additions and 15 deletions

View File

@ -10,6 +10,49 @@
#include maps\mp\zombies\_zm_audio;
#include maps\mp\zombies\_zm_stats;
screecher_melee_damage( player )
{
melee_score = 0;
if ( player hasweapon( "tazer_knuckles_zm" ) )
{
melee_score = 30;
}
else if ( player hasweapon( "bowie_knife_zm" ) )
{
melee_score = 15;
}
else
{
melee_score = 10;
}
if ( self.screecher_score > 0 )
{
if ( melee_score > self.screecher_score )
{
self.screecher_score = 0;
}
else
{
self.screecher_score -= melee_score;
}
}
if ( self.screecher_score <= 0 )
{
self.player_score += melee_score;
}
self playsound( "zmb_vocals_screecher_pain" );
if ( level.zombie_vars[player.team]["zombie_insta_kill"] )
self.player_score = 30;
else
player thread do_player_general_vox( "general", "screecher_cut" );
self screecher_check_score();
}
screecher_detach( player )
{
self endon( "death" );