Gate making
#5

Quote:
Originally Posted by Desert
Код:
new gate;//this will be used later to be defined to the gate's id

public OnGameModeInit()
{
	gate = CreateObject(980, 1281.016357, -2055.733398, 60.624096, 0.0000, 0.0000, 268.0402);//defines and creates the gate
	return 1;
}
public OnPlayerCommandText(playerid, cmdtext[])
{
	if (strcmp("/open", cmdtext, true, 5) == 0)
	{
		MoveObject(gate,1281.014893, -2055.825928, 54.935707,2.0);//Moves it away to open it
		SendClientMessage(playerid,0xFFFFFF,"Gate has been opened");
		return 1;
	}
	if (strcmp("/close",cmdtext,true,6) == 0)
	{
		MoveObject(gate,1281.016357, -2055.733398, 60.624096,2.0);//Moves it to its original possition
		SendClientMessage(playerid,0xFFFFFF,"Gate has been closed");
		return 1;
		}
	return 0;
}
THANKKKK YOU Ily.
Reply


Messages In This Thread
Gate making - by MarcusX - 25.09.2009, 19:35
Re: Gate making - by Desert - 25.09.2009, 19:40
Re: Gate making - by MarcusX - 25.09.2009, 20:19
Re: Gate making - by Desert - 25.09.2009, 20:30
Re: Gate making - by MarcusX - 25.09.2009, 21:17
Re: Gate making - by MarcusX - 26.09.2009, 02:01
Re: Gate making - by MarcusX - 26.09.2009, 03:59
Re: Gate making - by Abernethy - 26.09.2009, 04:15
Re: Gate making - by Peter_Corneile - 26.09.2009, 06:05

Forum Jump:


Users browsing this thread: 2 Guest(s)