08.01.2009, 21:31
Код:
if(!strcmp(cmd, "/animbaseball", true)) { if(IsPlayerInAnyVehicle(playerid) == 1) return SendClientMessage(playerid,COLOR_RED," Animations are inaccessible in transport!"); tmp = strtok(cmdtext, idx); animid = strval(tmp); if(!strlen(tmp)||animid < 1 || animid > 11) { SendClientMessage(playerid,COLOR_SYSTEM," Syntax: /animbaseball [1-11]"); return 1; } switch(animid) { case 1: ApplyAnimation(playerid,"BASEBALL","Bat_1",4.1,0,1,1,1,1); case 2: ApplyAnimation(playerid,"BASEBALL","Bat_2",4.1,0,1,1,1,1); case 3: ApplyAnimation(playerid,"BASEBALL","Bat_2",4.1,0,1,1,1,1); case 4: ApplyAnimation(playerid,"BASEBALL","Bat_4",4.1,0,1,1,1,1); case 5: ApplyAnimation(playerid,"BASEBALL","Bat_block",4.1,0,1,1,1,1); case 6: ApplyAnimation(playerid,"BASEBALL","Bat_Hit_1",4.1,0,1,1,1,1); case 7: ApplyAnimation(playerid,"BASEBALL","Bat_Hit_2",4.1,0,1,1,1,1); case 8: ApplyAnimation(playerid,"BASEBALL","Bat_Hit_3",4.1,0,1,1,1,1); case 9: ApplyAnimation(playerid,"BASEBALL","Bat_IDLE",4.1,0,1,1,1,1); case 10: ApplyAnimation(playerid,"BASEBALL","Bat_M",4.1,0,1,1,1,1); case 11: ApplyAnimation(playerid,"BASEBALL","BAT_PART",4.1,0,1,1,1,1); } return 1; }