04.04.2013, 21:10
I have gotten through all my other problems in this system and look to hopefully finish this by tonight.
I have came across an issue where I can only enter and exit a dynamic door when I create it. Once the server restarted I would have to create the door again to be able to use it. I checked to see if everything was saving and it is. I also checked to see if the interior choords are there ( the location where the door will teleport you to) and they are there:
Now what could possibly be the issue?
Here is my enter and exit command:
I have came across an issue where I can only enter and exit a dynamic door when I create it. Once the server restarted I would have to create the door again to be able to use it. I checked to see if everything was saving and it is. I also checked to see if the interior choords are there ( the location where the door will teleport you to) and they are there:
Now what could possibly be the issue?
Here is my enter and exit command:
pawn Код:
CMD:enter(playerid,params[])
{
new inter = GetPlayerInterior(playerid);
new vir = GetPlayerVirtualWorld(playerid);
foreach(Doors, i)
{
if(PlayerToPoint(2.0, playerid, DoorData[i][dExteriorX], DoorData[i][dExteriorY], DoorData[i][dExteriorZ]) && inter == DoorData[i][dExteriorInt] && vir == DoorData[i][dExteriorVW])
{
SetPlayerInterior(playerid, DoorData[i][dInteriorInt]);
SetPlayerPos(playerid, DoorData[i][dInteriorX], DoorData[i][dInteriorY], DoorData[i][dInteriorZ]);
SetPlayerVirtualWorld(playerid, DoorData[i][dInteriorVW]);
}
else
{
SendClientMessage(playerid,COLOR_GREY,"No door in range.");
}
}
return 1;
}
CMD:exit(playerid,params[])
{
new inter = GetPlayerInterior(playerid);
new vir = GetPlayerVirtualWorld(playerid);
foreach(Doors, i)
{
if(PlayerToPoint(2.0, playerid, DoorData[i][dInteriorX], DoorData[i][dInteriorY], DoorData[i][dInteriorZ]) && inter == DoorData[i][dInteriorInt] && vir == DoorData[i][dInteriorVW])
{
SetPlayerPos(playerid, DoorData[i][dExteriorX], DoorData[i][dExteriorY], DoorData[i][dExteriorZ]);
SetPlayerInterior(playerid, DoorData[i][dExteriorInt]);
SetPlayerVirtualWorld(playerid, DoorData[i][dExteriorVW]);
}
else
{
}
}
return 1;
}