Can't see vehicles after changing virtualworld -
Lirbo - 24.02.2018
after changing virtual world and coming back to the previous one I can't see any vehicle for some reason although I'm changing back to virtualworld 0 which is the vehicle virtual world as well. I'm using 0.3.DL is that a known issue?
Re: Can't see vehicles after changing virtualworld -
DeMoo - 24.02.2018
PHP код:
SetVehicleVirtualWorld(GetPlayerVehicleID(playerid), virtualid);
Re: Can't see vehicles after changing virtualworld -
PepsiCola23 - 24.02.2018
make a debug for the car virtual world with GetVehicleVirtualWorld and see if it matches yours
Re: Can't see vehicles after changing virtualworld -
Lirbo - 24.02.2018
Quote:
Originally Posted by PepsiCola23
make a debug for the car virtual world with GetVehicleVirtualWorld and see if it matches yours
|
I did it, still nothing.
All I do is using /setvirtualworld [world] command and when I'm back the vehicles are gone but not the rest of the things such as pickups and 3dlabels.
PHP код:
CreateVehicle(411, 2600, -2200, 14, 0, 1, 1, -1);
AddStaticVehicle(520, 2603, -2195, 14, 0, 0, 1); // hydra
nothing is wrong with my command though, when I use virtualworld change on playerspawn it won't show as well
PHP код:
CMD:setvirtualworld(playerid, params[])
{
if(sscanf(params, "d", I[0])) return Message(playerid, TYPE_USAGE, "/virtualworld [virtualworld]");
SetPlayerVirtualWorld(playerid, I[0]);
return 1;
}
before changing vw:
after changing vw:
after changing back to vw 0:
the screenshots are not edited, the hp loss is due to hunger and dehydration
Also it won't show vehicles that were created after changing the interior:
PHP код:
CMD:adminvehicle(playerid, params[])
{
new string[64];
if(DB[playerid][Admin] < 3) return Message(playerid, TYPE_ERROR, "You're not allowed to use this command.");
if(sscanf(params, "d", I[0])) return Message(playerid, TYPE_USAGE, "/adminvehicle [model id]");
DestroyVehicle(AVehicle[playerid]);
GetPlayerPos(playerid, F[0], F[1], F[2]);
GetPlayerFacingAngle(playerid, F[3]);
AVehicle[playerid] = CreateVehicle(I[0], F[0], F[1], F[2], F[3], 1, 1, -1);
SetVehicleVirtualWorld(AVehicle[playerid], GetPlayerVirtualWorld(playerid));
LinkVehicleToInterior(AVehicle[playerid], GetPlayerInterior(playerid));
SetVehicleNumberPlate(AVehicle[playerid], "{FFFFFF}Admin");
//PutPlayerInVehicle(playerid, AVehicle[playerid], 0);
format(string, sizeof(string), "Spawned an OOC Admin vehicle (%d).", GetVehicleModel(AVehicle[playerid]));
Message(playerid, TYPE_ADMIN, string);
return 1;
}
Re: Can't see vehicles after changing virtualworld -
PepsiCola23 - 24.02.2018
maybe you set another vw other than 0 when a player connects?
Re: Can't see vehicles after changing virtualworld -
Lirbo - 24.02.2018
Quote:
Originally Posted by PepsiCola23
maybe you set another vw other than 0 when a player connects?
|
It's not related, the player can see the vehicles when they spawn, however after changing interior they can't see it when they come back to the virtual work of the vehicle
Re: Can't see vehicles after changing virtualworld -
PepsiCola23 - 24.02.2018
can you use this when you login,after you use cmd,and after you use cmd back again,and do the same thing for the car`s virtual world?
PHP код:
YCMD:vw(playerid, params[], help)
{
new string[32];
format(string, sizeof(string), "vw %d", GetPlayerVirtualWorld(playerid));
SendClientMessage(playerid, 0xFFFFFFFF, string);
return 1;
}
Re: Can't see vehicles after changing virtualworld -
Lirbo - 24.02.2018
Quote:
Originally Posted by PepsiCola23
can you use this when you login,after you use cmd,and after you use cmd back again,and do the same thing for the car`s virtual world?
PHP код:
YCMD:vw(playerid, params[], help)
{
new string[32];
format(string, sizeof(string), "vw %d", GetPlayerVirtualWorld(playerid));
SendClientMessage(playerid, 0xFFFFFFFF, string);
return 1;
}
|
https://imgur.com/a/Yfsi0
Re: Can't see vehicles after changing virtualworld -
PepsiCola23 - 24.02.2018
try this
PHP код:
YCMD:setvw(playerid, params[], help)
{
new id,intid;
if(sscanf(params, "ui", id, intid)) return SendUsage(playerid,"/setvw <Name/Playerid> <vw>");
SetPlayerVirtualWorld(id, intid);
}
Re: Can't see vehicles after changing virtualworld -
Lirbo - 24.02.2018
Quote:
Originally Posted by PepsiCola23
try this
PHP код:
YCMD:setvw(playerid, params[], help)
{
new id,intid;
if(sscanf(params, "ui", id, intid)) return SendUsage(playerid,"/setvw <Name/Playerid> <vw>");
SetPlayerVirtualWorld(id, intid);
}
|
it's working the same as my command, dude it doesn't work