Advertisement
itsDevi

BOLD

Nov 1st, 2021
1,338
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Pawn 0.81 KB | None | 0 0
  1. if(IsBulletWeapon(weapon))
  2.         {
  3.             new givedamage = 0, _d_bodypart = bodypart;
  4.  
  5.             if(_d_bodypart == BODY_PART_LEFT_LEG)
  6.                 _d_bodypart = BODY_PART_RIGHT_LEG;
  7.  
  8.             if(_d_bodypart == BODY_PART_LEFT_ARM)
  9.                 _d_bodypart = BODY_PART_RIGHT_ARM;
  10.  
  11.             givedamage = weaponDamageData[weapon][_d_bodypart][wddDmgOther];
  12.             if(IsPlayerInRangeOfPlayer(issuerid, playerid, 60.0)) {
  13.                 givedamage = weaponDamageData[weapon][_d_bodypart][wddDmg60];
  14.             } if(IsPlayerInRangeOfPlayer(issuerid, playerid, 20.0)) {
  15.                 givedamage = weaponDamageData[weapon][_d_bodypart][wddDmg20];
  16.             }
  17.             if(_d_bodypart == BODY_PART_HEAD) {
  18.                 amount = float(givedamage);
  19.             } else {
  20.                 amount = float(givedamage);
  21.             }
  22.             printf("[CustomDamage]: %s - bodypart: %d - damage: %d", GetPlayerNameEx(playerid), _d_bodypart, givedamage);
  23.         }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement