Elevator Moving
#2

Quote:
Originally Posted by [DJ]Boki
Посмотреть сообщение
Guys,i need help with this,when i join game and type /up there says unknown command

public OnPlayerCommandText(playerid, cmdtext[])
{
if(strcmp(cmd, "/up", true) == 0) {
MoveObject(elevator,2907.84814453,-1990.46643066,0.88099957,2.00); // Put your cords in here
SendClientMessage(playerid, COLOR_RED, "You are now going up, Please Wait."); // You dont alwas have to put this in, delete if wanted.
return 1;
}
if(strcmp(cmd, "/down", true) == 0) { // Same deal as before
MoveObject(elevator,2907.84814453,-1990.46643066,0.88099957,-2.00); // Same deal as before
SendClientMessage(playerid, COLOR_RED, "The Elevator is now comming, Please Wait."); // Same deal as before
return 1;
}
#endif[/code]
I think You havent closed On Player Command Text.

it should be Like this

pawn Код:
public OnPlayerCommandText(playerid, cmdtext[])
    {
        if(strcmp(cmd, "/up", true) == 0) {
MoveObject(elevator,2907.84814453,-1990.46643066,0.88099957,2.00); // Put your cords in here
SendClientMessage(playerid, COLOR_RED, "You are now going up, Please Wait."); // You dont alwas have to put this in, delete if wanted.
return 1;
}
if(strcmp(cmd, "/down", true) == 0) { // Same deal as before
MoveObject(elevator,2907.84814453,-1990.46643066,0.88099957,-2.00); // Same deal as before
SendClientMessage(playerid, COLOR_RED, "The Elevator is now comming, Please Wait."); // Same deal as before
return 1;
}
    return 0;

}
++

you missed
return 0;
over there.
Reply


Messages In This Thread
Elevator Moving - by [DJ]Boki - 14.04.2011, 16:31
Re: Elevator Moving - by Niko_boy - 14.04.2011, 16:39
Re: Elevator Moving - by [DJ]Boki - 14.04.2011, 16:44
Re: Elevator Moving - by VT - 14.04.2011, 16:46
Re: Elevator Moving - by Conroy - 14.04.2011, 16:58
Re: Elevator Moving - by Niko_boy - 14.04.2011, 17:52
Re: Elevator Moving - by [DJ]Boki - 14.04.2011, 17:57
Re: Elevator Moving - by IvancheBG - 14.04.2011, 18:03
Re: Elevator Moving - by [DJ]Boki - 14.04.2011, 18:31
Re: Elevator Moving - by Anastasia - 14.04.2011, 19:08

Forum Jump:


Users browsing this thread: 1 Guest(s)