Skip to content

Commit

Permalink
added winger code and updated caber throw
Browse files Browse the repository at this point in the history
  • Loading branch information
higps committed Feb 7, 2024
1 parent e614c6e commit fa3f9da
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 1 deletion.
21 changes: 21 additions & 0 deletions berobot_dmg_handler.sp
Original file line number Diff line number Diff line change
Expand Up @@ -1498,6 +1498,13 @@ public Action Event_post_inventory_application(Event event, const char[] name, b
{
Format(chat_display, sizeof(chat_display), "%s\n{teamcolor}Crit-a-Cola: {orange}Applies %0.f second crits when used",chat_display, g_crit_a_cola_duration);
}
if (IsWinger(Weapon2))
{

stat1 = 1.50;
TF2Attrib_SetByName(Weapon2, "increased jump height", stat1);
Format(chat_display, sizeof(chat_display), "%s\n{teamcolor}Winger: {orange}+%0.f%%%% additional passive jump height bonus",chat_display, MoreIsMore(stat1));
}

}

Expand Down Expand Up @@ -2674,6 +2681,20 @@ bool IsCritACola(int weapon){
return false;
}

bool IsWinger(int weapon){
if(weapon == -1 && weapon <= MaxClients) return false;

switch(GetEntProp(weapon, Prop_Send, "m_iItemDefinitionIndex"))
{
//If other allclass are added, add here
case 449:
{
return true;
}
}
return false;
}

bool IsShotGun(int weapon){
if(weapon == -1 && weapon <= MaxClients) return false;

Expand Down
2 changes: 1 addition & 1 deletion mm_attribute_caber_throw.sp
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ bool HasStat(int weapon, FCaber caber)
caber.Damage = ReadFloatVar(stat_buffer, "caber_blast_damage", 100.0);
caber.Radius = ReadFloatVar(stat_buffer, "caber_blast_radius", 176.0);
caber.DetOnImpact = view_as<bool>(ReadIntVar(stat_buffer, "caber_det_impact", 0));
caber.RegenDuration = ;ReadFloatVar(stat_buffer, "caber_regen_time", 20.0);
caber.RegenDuration = ReadFloatVar(stat_buffer, "caber_regen_time", 20.0);
caber.Speed = ReadFloatVar(stat_buffer, "caber_grenade_speed", 1600.0);

return true;
Expand Down

0 comments on commit fa3f9da

Please sign in to comment.