Teleport [HELP]
#1

I Make A Teleport 1st I Do /save and i copy save position from document files

but it Give"s A warning

Код:
}
    if (strcmp(cmdtext, "/test", true) == 0){
    SetPlayerInterior(playerid, 1);
    SetPlayerFacingAngle(playerid, 0);
    SetPlayerPos(playerid, -1505.6221,769.2800,7.1853,190.2585);
    SendClientMessage(playerid, 0xFFFF00AA, "test");
return 1;}
Reply
#2

WHat's the warning?
Reply
#3

What warning it is saying?
Reply
#4

THIS

Quote:

C:\Documents and Settings\XPPRESP3\Desktop\samp03csvr_R5_win32\samp 03csvr_R5_win32\samp03csvr_R5_win32\gamemodes\lvdm .pwn(526 : warning 202: number of arguments does not match definition
Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase

Header size: 5748 bytes
Code size: 2795360 bytes
Data size: 417148 bytes
Stack/heap size: 16384 bytes; estimated max. usage=7131 cells (28524 bytes)
Total requirements: 3234640 bytes

1 Warning.

Reply
#5

pawn Код:
SetPlayerPos(playerid, -1505.6221,769.2800,7.1853/*,190.2585*/);//remove the 4th float
the 4th float is the player angle and setplayerpos does not set the player angle, to do that you must use SetPlayerFacingAngle.
Reply
#6

Quote:
Originally Posted by Pharrel
Посмотреть сообщение
pawn Код:
SetPlayerPos(playerid, -1505.6221,769.2800,7.1853/*,190.2585*/);//remove the 4th float
the 4th float is the player angle and setplayerpos does not set the player angle, to do that you must use SetPlayerFacingAngle.
That's the perfect answer,you took it from my mouth..i mean hand
Reply
#7

this should be float
pawn Код:
SetPlayerFacingAngle(playerid, 0);
edit: and you should delete the 4th float from SetPlayerPos, as stated above.
Reply
#8

pawn Код:
if(!strcmp(cmdtext, "/test", true)){
   if(!IsPlayerInAnyVehicle(playerid)){
       SetPlayerPos(playerid, 1505.6221, 769.2800, 7.1853);
       SetPlayerFacingAngle(playerid, 0.0);
       SetPlayerInterior(playerid, 1);
       SetPlayerVirtualWorld(playerid, 0);
   }
   else{
       new veh = GetPlayerVehicleID(playerid);
       SetVehiclePos(veh, 1505.6221, 769.2800, 7.1853);
       SetVehicleZAngle(veh, 0.0);
       LinkVehicleToInterior(veh, 1);
       SetVehicleVirtualWorld(veh, 0);
       PutPlayerInVehicle(playerid, veh, 0);
   }
   return 1;
}
it will teleport the car also if your in any car and if your not it will make one :P

[pawn]
pawn Код:
if(!strcmp(cmdtext, "/test", true)){
   SetPlayerPos(playerid, 1505.6221, 769.2800, 7.1853);
   SetPlayerFacingAngle(playerid, 0.0);
   SetPlayerInterior(playerid, 1);
   SetPlayerVirtualWorld(playerid, 0);
   return 1;
}
this one is simple
Reply
#9

Done Its Working Repu AddedTo Pharrel !!!
Reply
#10

Quote:
Originally Posted by Salsa
Посмотреть сообщение
Done Its Working Repu AddedTo Pharrel !!!
Mr_Scripter's reply is better,you can TP yourself with your car(if you're in one).
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)