public OnPlayerCommandText(playerid, cmdtext[]) { //Blowjob if(strcmp(cmdtext, "/bj", true) == 0) { if(!strlen(cmdtext[4])) return SendClientMessage(playerid, red, "Usage: /bj [1-18]"); switch (cmdtext[4]) { case '1': ApplyAnimation(playerid, "BLOWJOBZ", "BJ_COUCH_START_W", 4.0, 1, 1, 1, 1, 0); case '2': ApplyAnimation(playerid, "BLOWJOBZ", "BJ_COUCH_START_P", 4.0, 1, 1, 1, 1, 0); case '3': ApplyAnimation(playerid, "BLOWJOBZ", "BJ_COUCH_LOOP_W", 4.0, 1, 1, 1, 1, 0); case '4': ApplyAnimation(playerid, "BLOWJOBZ", "BJ_COUCH_LOOP_P", 4.0, 1, 1, 1, 1, 0); case '5': ApplyAnimation(playerid, "BLOWJOBZ", "BJ_COUCH_END_W", 4.0, 1, 1, 1, 1, 0); case '6': ApplyAnimation(playerid, "BLOWJOBZ", "BJ_COUCH_END_P", 4.0, 1, 1, 1, 1, 0); case '7': ApplyAnimation(playerid, "BLOWJOBZ", "BJ_STAND_START_W", 4.0, 1, 1, 1, 1, 0); case '8': ApplyAnimation(playerid, "BLOWJOBZ", "BJ_STAND_START_P", 4.0, 1, 1, 1, 1, 0); case '9': ApplyAnimation(playerid, "BLOWJOBZ", "BJ_STAND_LOOP_W", 4.0, 1, 1, 1, 1, 0); case '10': ApplyAnimation(playerid, "BLOWJOBZ", "BJ_STAND_LOOP_P", 4.0, 1, 1, 1, 1, 0); case '11': ApplyAnimation(playerid, "BLOWJOBZ", "BJ_STAND_END_W", 4.0, 1, 1, 1, 1, 0); case '12': ApplyAnimation(playerid, "BLOWJOBZ", "BJ_STAND_END_P", 4.0, 1, 1, 1, 1, 0); case '13': ApplyAnimation(playerid, "BLOWJOBZ", "BJ_CAR_START_W", 4.0, 1, 1, 1, 1, 0); case '14': ApplyAnimation(playerid, "BLOWJOBZ", "BJ_CAR_START_P", 4.0, 1, 1, 1, 1, 0); case '15': ApplyAnimation(playerid, "BLOWJOBZ", "BJ_CAR_LOOP_W", 4.0, 1, 1, 1, 1, 0); case '16': ApplyAnimation(playerid, "BLOWJOBZ", "BJ_CAR_LOOP_P", 4.0, 1, 1, 1, 1, 0); case '17': ApplyAnimation(playerid, "BLOWJOBZ", "BJ_CAR_END_W", 4.0, 1, 1, 1, 1, 0); case '18': ApplyAnimation(playerid, "BLOWJOBZ", "BJ_CAR_END_P", 4.0, 1, 1, 1, 1, 0); default: SendClientMessage(playerid, red, "Usage: /bj [1-18]"); } return 1; } //Spank if(strcmp(cmdtext, "/spank", true) == 0) { if(!strlen(cmdtext[7])) return SendClientMessage(playerid, red, "Usage: /spank [1-8]"); switch (cmdtext[7]) { case '1': ApplyAnimation(playerid, "SNM", "SPANKING_IDLEW", 4.0, 1, 1, 1, 1, 0); case '2': ApplyAnimation(playerid, "SNM", "SPANKING_IDLEP", 4.0, 1, 1, 1, 1, 0); case '3': ApplyAnimation(playerid, "SNM", "SPANKINGW", 4.0, 1, 1, 1, 1, 0); case '4': ApplyAnimation(playerid, "SNM", "SPANKINGP", 4.0, 1, 1, 1, 1, 0); case '5': ApplyAnimation(playerid, "SNM", "SPANKEDW", 4.0, 1, 1, 1, 1, 0); case '6': ApplyAnimation(playerid, "SNM", "SPANKEDP", 4.0, 1, 1, 1, 1, 0); case '7': ApplyAnimation(playerid, "SNM", "SPANKING_ENDW", 4.0, 1, 1, 1, 1, 0); case '8': ApplyAnimation(playerid, "SNM", "SPANKING_ENDP", 4.0, 1, 1, 1, 1, 0); default: SendClientMessage(playerid, red, "Usage: /spank [1-8]"); } return 1; } //Sex if(strcmp(cmdtext, "/sex", true) == 0) { if(!strlen(cmdtext[5])) return SendClientMessage(playerid, red, "Usage: /sex [1-20]"); switch (cmdtext[5]) { case '1': ApplyAnimation(playerid, "SEX", "SEX_1_W", 4.0, 1, 1, 1, 1, 0); case '2': ApplyAnimation(playerid, "SEX", "SEX_1_P", 4.0, 1, 1, 1, 1, 0); case '3': ApplyAnimation(playerid, "SEX", "SEX_1_CUM_W", 4.0, 1, 1, 1, 1, 0); case '4': ApplyAnimation(playerid, "SEX", "SEX_1_CUM_P", 4.0, 1, 1, 1, 1, 0); case '5': ApplyAnimation(playerid, "SEX", "SEX_1_FAIL_W", 4.0, 1, 1, 1, 1, 0); case '6': ApplyAnimation(playerid, "SEX", "SEX_1_FAIL_P", 4.0, 1, 1, 1, 1, 0); case '7': ApplyAnimation(playerid, "SEX", "SEX_1TO2_P", 4.0, 1, 1, 1, 1, 0); case '8': ApplyAnimation(playerid, "SEX", "SEX_1TO2_W", 4.0, 1, 1, 1, 1, 0); case '9': ApplyAnimation(playerid, "SEX", "SEX_2_W", 4.0, 1, 1, 1, 1, 0); case '10': ApplyAnimation(playerid, "SEX", "SEX_2_P", 4.0, 1, 1, 1, 1, 0); case '11': ApplyAnimation(playerid, "SEX", "SEX_2_FAIL_W", 4.0, 1, 1, 1, 1, 0); case '12': ApplyAnimation(playerid, "SEX", "SEX_2_FAIL_P", 4.0, 1, 1, 1, 1, 0); case '13': ApplyAnimation(playerid, "SEX", "SEX_2TO3_P", 4.0, 1, 1, 1, 1, 0); case '14': ApplyAnimation(playerid, "SEX", "SEX_2TO3_W", 4.0, 1, 1, 1, 1, 0); case '15': ApplyAnimation(playerid, "SEX", "SEX_3_W", 4.0, 1, 1, 1, 1, 0); case '16': ApplyAnimation(playerid, "SEX", "SEX_3_P", 4.0, 1, 1, 1, 1, 0); case '17': ApplyAnimation(playerid, "SEX", "SEX_3_FAIL_W", 4.0, 1, 1, 1, 1, 0); case '18': ApplyAnimation(playerid, "SEX", "SEX_3_FAIL_P", 4.0, 1, 1, 1, 1, 0); case '19': ApplyAnimation(playerid, "SEX", "SEX_3TO1_W", 4.0, 1, 1, 1, 1, 0); case '20': ApplyAnimation(playerid, "SEX", "SEX_3TO1_P", 4.0, 1, 1, 1, 1, 0); default: SendClientMessage(playerid, red, "Usage: /sex [1-20]"); } return 1; } return 0; }
Originally Posted by ♂ Antonio_
cmdtext[number] might be off..
|
Originally Posted by Karlip
<edited, didn't understand you at first>
|
Originally Posted by ziomal432
It's because you're comparing one letter, not two. It would be better to use strval.
|
public OnPlayerCommandText(playerid, cmdtext[])
{
//Blowjob
if(strcmp(cmdtext, "/bj", true) == 0)
{
if(!strlen(cmdtext[4])) return SendClientMessage(playerid, red, "Usage: /bj [1-18]");
switch(strval(cmdtext[4]))
{
case 1: ApplyAnimation(playerid, "BLOWJOBZ", "BJ_COUCH_START_W", 4.0, 1, 1, 1, 1, 0);
case 2: ApplyAnimation(playerid, "BLOWJOBZ", "BJ_COUCH_START_P", 4.0, 1, 1, 1, 1, 0);
case 3: ApplyAnimation(playerid, "BLOWJOBZ", "BJ_COUCH_LOOP_W", 4.0, 1, 1, 1, 1, 0);
case 4: ApplyAnimation(playerid, "BLOWJOBZ", "BJ_COUCH_LOOP_P", 4.0, 1, 1, 1, 1, 0);
case 5: ApplyAnimation(playerid, "BLOWJOBZ", "BJ_COUCH_END_W", 4.0, 1, 1, 1, 1, 0);
case 6: ApplyAnimation(playerid, "BLOWJOBZ", "BJ_COUCH_END_P", 4.0, 1, 1, 1, 1, 0);
case 7: ApplyAnimation(playerid, "BLOWJOBZ", "BJ_STAND_START_W", 4.0, 1, 1, 1, 1, 0);
case 8: ApplyAnimation(playerid, "BLOWJOBZ", "BJ_STAND_START_P", 4.0, 1, 1, 1, 1, 0);
case 9: ApplyAnimation(playerid, "BLOWJOBZ", "BJ_STAND_LOOP_W", 4.0, 1, 1, 1, 1, 0);
case 10: ApplyAnimation(playerid, "BLOWJOBZ", "BJ_STAND_LOOP_P", 4.0, 1, 1, 1, 1, 0);
case 11: ApplyAnimation(playerid, "BLOWJOBZ", "BJ_STAND_END_W", 4.0, 1, 1, 1, 1, 0);
case 12: ApplyAnimation(playerid, "BLOWJOBZ", "BJ_STAND_END_P", 4.0, 1, 1, 1, 1, 0);
case 13: ApplyAnimation(playerid, "BLOWJOBZ", "BJ_CAR_START_W", 4.0, 1, 1, 1, 1, 0);
case 14: ApplyAnimation(playerid, "BLOWJOBZ", "BJ_CAR_START_P", 4.0, 1, 1, 1, 1, 0);
case 15: ApplyAnimation(playerid, "BLOWJOBZ", "BJ_CAR_LOOP_W", 4.0, 1, 1, 1, 1, 0);
case 16: ApplyAnimation(playerid, "BLOWJOBZ", "BJ_CAR_LOOP_P", 4.0, 1, 1, 1, 1, 0);
case 17: ApplyAnimation(playerid, "BLOWJOBZ", "BJ_CAR_END_W", 4.0, 1, 1, 1, 1, 0);
case 18: ApplyAnimation(playerid, "BLOWJOBZ", "BJ_CAR_END_P", 4.0, 1, 1, 1, 1, 0);
default: SendClientMessage(playerid, red, "Usage: /bj [1-18]");
}
return 1;
}
//Spank
if(strcmp(cmdtext, "/spank", true) == 0)
{
if(!strlen(cmdtext[7])) return SendClientMessage(playerid, red, "Usage: /spank [1-8]");
switch(strval(cmdtext[7]))
{
case 1: ApplyAnimation(playerid, "SNM", "SPANKING_IDLEW", 4.0, 1, 1, 1, 1, 0);
case 2: ApplyAnimation(playerid, "SNM", "SPANKING_IDLEP", 4.0, 1, 1, 1, 1, 0);
case 3: ApplyAnimation(playerid, "SNM", "SPANKINGW", 4.0, 1, 1, 1, 1, 0);
case 4: ApplyAnimation(playerid, "SNM", "SPANKINGP", 4.0, 1, 1, 1, 1, 0);
case 5: ApplyAnimation(playerid, "SNM", "SPANKEDW", 4.0, 1, 1, 1, 1, 0);
case 6: ApplyAnimation(playerid, "SNM", "SPANKEDP", 4.0, 1, 1, 1, 1, 0);
case 7: ApplyAnimation(playerid, "SNM", "SPANKING_ENDW", 4.0, 1, 1, 1, 1, 0);
case 8: ApplyAnimation(playerid, "SNM", "SPANKING_ENDP", 4.0, 1, 1, 1, 1, 0);
default: SendClientMessage(playerid, red, "Usage: /spank [1-8]");
}
return 1;
}
//Sex
if(strcmp(cmdtext, "/sex", true) == 0)
{
if(!strlen(cmdtext[5])) return SendClientMessage(playerid, red, "Usage: /sex [1-20]");
switch(strval(cmdtext[5]))
{
case 1: ApplyAnimation(playerid, "SEX", "SEX_1_W", 4.0, 1, 1, 1, 1, 0);
case 2: ApplyAnimation(playerid, "SEX", "SEX_1_P", 4.0, 1, 1, 1, 1, 0);
case 3: ApplyAnimation(playerid, "SEX", "SEX_1_CUM_W", 4.0, 1, 1, 1, 1, 0);
case 4: ApplyAnimation(playerid, "SEX", "SEX_1_CUM_P", 4.0, 1, 1, 1, 1, 0);
case 5: ApplyAnimation(playerid, "SEX", "SEX_1_FAIL_W", 4.0, 1, 1, 1, 1, 0);
case 6: ApplyAnimation(playerid, "SEX", "SEX_1_FAIL_P", 4.0, 1, 1, 1, 1, 0);
case 7: ApplyAnimation(playerid, "SEX", "SEX_1TO2_P", 4.0, 1, 1, 1, 1, 0);
case 8: ApplyAnimation(playerid, "SEX", "SEX_1TO2_W", 4.0, 1, 1, 1, 1, 0);
case 9: ApplyAnimation(playerid, "SEX", "SEX_2_W", 4.0, 1, 1, 1, 1, 0);
case 10: ApplyAnimation(playerid, "SEX", "SEX_2_P", 4.0, 1, 1, 1, 1, 0);
case 11: ApplyAnimation(playerid, "SEX", "SEX_2_FAIL_W", 4.0, 1, 1, 1, 1, 0);
case 12: ApplyAnimation(playerid, "SEX", "SEX_2_FAIL_P", 4.0, 1, 1, 1, 1, 0);
case 13: ApplyAnimation(playerid, "SEX", "SEX_2TO3_P", 4.0, 1, 1, 1, 1, 0);
case 14: ApplyAnimation(playerid, "SEX", "SEX_2TO3_W", 4.0, 1, 1, 1, 1, 0);
case 15: ApplyAnimation(playerid, "SEX", "SEX_3_W", 4.0, 1, 1, 1, 1, 0);
case 16: ApplyAnimation(playerid, "SEX", "SEX_3_P", 4.0, 1, 1, 1, 1, 0);
case 17: ApplyAnimation(playerid, "SEX", "SEX_3_FAIL_W", 4.0, 1, 1, 1, 1, 0);
case 18: ApplyAnimation(playerid, "SEX", "SEX_3_FAIL_P", 4.0, 1, 1, 1, 1, 0);
case 19: ApplyAnimation(playerid, "SEX", "SEX_3TO1_W", 4.0, 1, 1, 1, 1, 0);
case 20: ApplyAnimation(playerid, "SEX", "SEX_3TO1_P", 4.0, 1, 1, 1, 1, 0);
default: SendClientMessage(playerid, red, "Usage: /sex [1-20]");
}
return 1;
}
return 0;
}
Originally Posted by PotH3Ad
Try this:
pawn Code:
|