Posts: 47
Threads: 7
Joined: Jul 2008
Reputation:
0
Hi guys bit stuck here, i want to add a tele /tankdm i have the pos it is AddPlayerClass(105,2320.4558,568.2838,7.7802,6.660 4,0,0,0,0,0,0); //
how can i add this to my script
thanks
Posts: 3,262
Threads: 30
Joined: Aug 2008
Reputation:
0
Put this in OnPlayerCommandText. It's a command, not a class.
Posts: 47
Threads: 7
Joined: Jul 2008
Reputation:
0
how can i change this to one below with /tankdm ive tried one above wont work so i copy paste wot looks like in script AddPlayerClass(105,2320.4558,568.2838,7.7802,6.660 4,0,0,0,0,0,0); //
if (!strcmp("/bigjump", cmdtext, true))
{
SetPlayerPosWithVehicle(playerid, -645.1850, 2311.9236, 135.0301, 6.2667, cmdtext);
return 1;
Posts: 180
Threads: 7
Joined: Jun 2008
Reputation:
0
Just search for a teleport generator, then you use, see the result, and learn
Posts: 47
Threads: 7
Joined: Jul 2008
Reputation:
0
thirs no teleport generator
Posts: 74
Threads: 23
Joined: Aug 2009
Reputation:
0
OnPlayerCommandText(playerid,cmdtext[])
{
if(!strcmp("/tankdm",cmdtext,true))
{
SetPlayerPos(playerid,2320.4558,568.2838,7.7802)
return 1;
}
}
SetPlayerPos is a function that like this:
SetPlayerPos(#idofplayer#,x,y,z);
And, AddPlayerClass is like this:
AddPlayerClass(#skinid#,x,y,z,#theangle(where the player look to)#,weapon1,ammo_of_weapon1,weapon2,ammo_of_weapo n2,weapon3,ammo_of_weapon3);
And, to help u easier to tele, i am going to give u an example.
U have a script like this:
AddPlayerClass(2,10.5423,20.3847,11.203948,0,32,999,0,0,0,0);
Now, we have to copy the underlined texts, and put it into this:
SetPlayerPos(playerid,10.5423,20.3847,11.203948);
Sooooo simple, isn't it?
Hopez helped u!