Quote:
Originally Posted by ViruZZzZ_ChiLLL
pawn Код:
new door;
public OnGameModeInit() { door = CreateObject(....) return 1; }
public OnPlayerCcommandText(playerid, cmdtext[]) { if(!strcmp(cmdtext, "/opendoor", true) == 0) { MoveObject(door, ....) return 1; }
return 0; }
|
I already have this, but how do I make it so if I type /door and the door is ALREADY OPEN, it will CLOSE. and then if it's ALREADY CLOSED, it will OPEN. Get what I'm saying? I think it will involve:
new DoorOpen = 1;
new DoorOpen = 0;
but I'm not sure how I will use it to put it all together.