[SOLVED]/maketpexit - doesn't save the VirtualWorld of the player
#2

I suggest you to debug it, then you can see if the player's position isn't correct, or the Saving part isn't correct.
pawn Код:
if(!strcmp(cmd,"/maketpexit",true)||!strcmp(cmd,"/mtpex",true))
{
  if(IsPlayerInAnyVehicle(playerid)) return SendClientMessage(playerid,COLOR_GRAD1,"You can't use this while being in a car");
  if(PlayerInfo[playerid][pAdmin]<4) return error(playerid);
  tmp = strtok(cmdtext, idx);
  if(!strlen(tmp)) return SendClientMessage(playerid,COLOR_GRAD1,"[USAGE:] (/mtpex)/maketpexit [TPID]");
  new tpid = strval(tmp);
  new tpstring[128];
  new Float:mteX,Float:mteY,Float:mteZ,Float:mteA;
  GetPlayerPos(playerid,mteX,mteY,mteZ);
  GetPlayerFacingAngle(playerid,mteA);
  Teleport[tpid][tpexX]=mteX;
  Teleport[tpid][tpexY]=mteY;
  Teleport[tpid][tpexZ]=mteZ;
  Teleport[tpid][tpexA]=mteA;
  Teleport[tpid][tpexInterior]=GetPlayerInterior(playerid);
  Teleport[tpid][tpexWorld]=GetPlayerVirtualWorld(playerid);
  printf("Virtual World: %d.",Teleport[tpid][tpexWorld]);
  SaveTeleports();
  format(tpstring,sizeof(tpstring),"Dynamic Teleport %d Exit Location Set",tpid);
  SendClientMessage(playerid,COLOR_ADMINCMD,tpstring);
  return 1;
}
Reply


Messages In This Thread
[SOLVED]/maketpexit - doesn't save the VirtualWorld of the player - by Castle - 31.05.2009, 07:17
Re: /maketpexit - doesn't save the VirtualWorld of the player - by MenaceX^ - 31.05.2009, 07:23
Re: /maketpexit - doesn't save the VirtualWorld of the player - by Castle - 31.05.2009, 07:30

Forum Jump:


Users browsing this thread: 1 Guest(s)