24.04.2018, 11:33
Yes, you can like Sithis said. Here's an example:
[!] To do this for the entire map, you have to add to the end of all objects from
that map the world ID, with or without the tag (.worldid).
[!] Also, you must know that if you are using static objects like "CreateObject" you have a limit of 1000 objects total. If you exceed that limit your objects will not be shown on your server. So, it's more than okay if you'll use "CreateDynamicObject" instead the "CreateObject", because the dynamic objects don't have limits.
PHP код:
After you set your map, and your coords at that map you must put that
map objects in the virtual world that you choose for your map in that command, here '/entermap'.
So if you have some objects like (examples):
CreateDynamicObject( 1697, -984.5000000, -659.2000100, 260.0, 31.7670000, 0.0, 0.0, .worldid = 10 );
CreateDynamicObject( 1697, -988.9660000, -659.2000100, 260.0, 31.7610000, 0.0, 0.0, .worldid = 10 );
CreateDynamicObject( 1697, -980.0332000, -659.1992200, 260.0, 31.7610000, 0.0, 0.0, .worldid = 10 );
CreateDynamicObject( 1697, -975.5673800, -659.1992200, 260.0, 31.7610000, 0.0, 0.0, .worldid = 10 );
CreateDynamicObject( 1697, -971.1015600, -659.1992200, 260.0, 31.7610000, 0.0, 0.0, .worldid = 10 );
that .worldid is the tag of the world ID from the "CreateDynamicObject" function, you just have to
add to your end of the object the world like you see in the code above, or you can simply put the
world without the tag ".worldid". Ex: CreateDynamicObject( 1697, -984.5000000, -659.2000100, 260.0, 31.7670000, 0.0, 0.0, 10 );
CMD:entermap( playerid, params[ ] ) // you must make a command from your map, like you want (this is an example).
{
SetPlayerVirtualWorld( playerid, 10 ) // you must set the world ID, it not requires the interior ID if you don't set it in the object code, but if you set the interior ID different from the original value you must set it in the comand with "SetPlayerInterior( playerid, Int ID );"
SetPlayerPos( playerid, x, y, z ); // x, y, z = your spawn coords at that map.
return 1;
}
that map the world ID, with or without the tag (.worldid).
[!] Also, you must know that if you are using static objects like "CreateObject" you have a limit of 1000 objects total. If you exceed that limit your objects will not be shown on your server. So, it's more than okay if you'll use "CreateDynamicObject" instead the "CreateObject", because the dynamic objects don't have limits.