|
Post by playa on Jul 4, 2014 11:20:27 GMT
#include <a_samp>
#if defined MAX_PLAYERS
#undef MAX_PLAYERS
#endif
#define MAX_PLAYERS 32
new playerPrevWorld[MAX_PLAYERS],
maxPlayers;
public OnFilterScriptInit()
maxPlayers = GetMaxPlayers();
public OnEnterExitModShop(playerid, enterexit, interiorid)
{
new vehicleid = GetPlayerVehicleID(playerid);
if(vehicleid)
{
if(enterexit) // Enter
{
playerPrevWorld[playerid] = GetPlayerVirtualWorld(playerid);
SetVehicleVirtualWorld(vehicleid, playerid);
for(new veh_playerid = 0; veh_playerid < maxPlayers; veh_playerid ++)
{
if(IsPlayerConnected(veh_playerid) && GetPlayerVehicleID(veh_playerid) == vehicleid)
SetPlayerVirtualWorld(veh_playerid, playerid);
}
}
else // Exit
{
SetVehicleVirtualWorld(vehicleid, playerPrevWorld[playerid]);
for(new veh_playerid = 0; veh_playerid < maxPlayers; veh_playerid ++)
{
if(IsPlayerConnected(veh_playerid) && GetPlayerVehicleID(veh_playerid) == vehicleid)
SetPlayerVirtualWorld(veh_playerid, playerPrevWorld[playerid]);
}
}
}
}
When 2 players enter transfender or any mod shop there car collide with each other or (damage) so i made about 32 virtual world to prevent them collide i just made them and hope you add them to the server and Spartan, please test it And me and dodo made it
|
|
Dodo0
Demoted Admin
I love this server <3
Posts: 155
|
Post by Dodo0 on Jul 4, 2014 11:28:10 GMT
You froget to put my name i made it with you -_-
|
|