27.03.2017, 13:59
Thanks!
Improved, thanks. (Added to credits)
Thanks, this is fixed. (Added to credits)
Quote:
What is this bullshit?
Code:
if(issuerid != INVALID_PLAYER_ID && bodypart == WEAPON_BODY_PART_CHEST) { pInfo[issuerid][Chest] += 1; } if(issuerid != INVALID_PLAYER_ID && bodypart == WEAPON_BODY_PART_TORSO) { pInfo[issuerid][Torso] += 1; } if(issuerid != INVALID_PLAYER_ID && bodypart == WEAPON_BODY_PART_LEFT_ARM) { pInfo[issuerid][LeftArm] += 1; } if(issuerid != INVALID_PLAYER_ID && bodypart == WEAPON_BODY_PART_RIGHT_ARM) { pInfo[issuerid][RightArm] += 1; } if(issuerid != INVALID_PLAYER_ID && bodypart == WEAPON_BODY_PART_LEFT_LEG) { pInfo[issuerid][LeftLeg] += 1; } if(issuerid != INVALID_PLAYER_ID && bodypart == WEAPON_BODY_PART_RIGHT_LEG) { pInfo[issuerid][RightLeg] += 1; } if(issuerid != INVALID_PLAYER_ID && bodypart == WEAPON_BODY_PART_HEAD) { pInfo[issuerid][Head] += 1; } Code:
if(issuerid != INVALID_PLAYER_ID) { switch(bodypart) { case WEAPON_BODY_PART_CHEST: pInfo[issuerid][Chest] += 1; case WEAPON_BODY_PART_TORSO: pInfo[issuerid][Torso] += 1; case WEAPON_BODY_PART_LEFT_ARM: pInfo[issuerid][LeftArm] += 1; case WEAPON_BODY_PART_RIGHT_ARM: pInfo[issuerid][RightArm] += 1; case WEAPON_BODY_PART_LEFT_LEG: pInfo[issuerid][RightLeg] += 1; case WEAPON_BODY_PART_RIGHT_LEG: pInfo[issuerid][LeftLeg] += 1; case WEAPON_BODY_PART_HEAD: pInfo[issuerid][Head] += 1; } } |
Quote:
Don't upload the .pwn file directly from your PC to the GitHub repository, Follow these steps;
Open your repository -> Click 'Create new file' -> Name your file and at the end of the name put .pwn -> Copy your script and paste it in the new file you made. or simply, if you use Sublime Text 3, Open 'View' -> 'Line Endings' -> 'Unix' then save it and upload it to the repository. Though, I believe there are other simpler ways. OT: Simple, But there are few things you should note on, such as the string defines in the command and Pottus post. |