Gate help!
#2

Hi candyboy,

It's really easy code really.

This is how I would of tried it.

Код:
//Top of script

new gate;//making the global variable for later use.

//On GameModeInit

gate = CreateObject(987, 315.5947265625, -1172.8193359375, 79.9140625, 0.000000, 0.000000, 224.30236816406); //Assigning a value to the global variable we previously made

//OnPlayerCommandText

if(strcmp(cmd,"/open",true) == 0)
{
  if(IsPlayerInRangeOfPoint(playerid,10.0,315.5947265625, -1172.8193359375, 79.9140625))
  {
    MoveObject(gate,NEWX,NEWY,NEWZ,SPEED);//We are then moving the object, now known as GATE to its new position.
  }
  return 1;
}
Pretty simple stuff. Give it a try.

Cheers,

TJ
Reply


Messages In This Thread
Gate help! - by candyboy - 04.06.2010, 07:05
Re: Gate help! - by TTJJ - 04.06.2010, 12:25
Re: Gate help! - by candyboy - 04.06.2010, 17:46
Re: Gate help! - by Jay. - 04.06.2010, 17:49
Re: Gate help! - by candyboy - 04.06.2010, 18:11
Re: Gate help! - by Jay. - 04.06.2010, 18:15
Re: Gate help! - by candyboy - 04.06.2010, 18:26
Re: Gate help! - by Jay. - 04.06.2010, 18:27
Re: Gate help! - by Flashy - 04.06.2010, 18:29
Re: Gate help! - by candyboy - 04.06.2010, 18:32

Forum Jump:


Users browsing this thread: 1 Guest(s)