Jump to content
  • 0

Intrebare World


RaulSTAR

Question

Deci am luat un GM pentru drift , si as dori sa fac ca atunci cand iti schimbi WORLDul la masina sa ii se schimbe automat , de exemplu spawnez o masina pe /world0 si cand dau /world1 sa ramana masina ci sa nu ma scoata din ea. sau daca sunt pe /world3 sa se spawneze masina pe /world3 !

Stie cineva cum as putea?

Comenzi world

if (strcmp(cmdtext, "/world1", true) == 0)

{

    SetPlayerVirtualWorld(playerid, 1);

    SendClientMessage(playerid, COLOR_YELLOW, "Virtual World Set!");

    return 1;

}

if (strcmp(cmdtext, "/world2", true) == 0)

{

    SetPlayerVirtualWorld(playerid, 2);

    SendClientMessage(playerid, COLOR_YELLOW, "Virtual World Set!");

    return 1;

Link to comment
Share on other sites

4 answers to this question

Recommended Posts

Faci asa:

[pawn]

if ( strcmp( cmdtext, "/world1", true ) == 0 )

{

    if ( IsPlayerInAnyVehicle( playerid ) )

    {

        SetVehicleVirtualWorld( GetPlayerVehicleID( playerid ), 1 );

        SendClientMessage( playerid, COLOR_YELLOW, "Virtual World + Vehicle Virtual World seted to 1! );

    }

    else

    {

        SetPlayerVirtualWorld( playerid, 1);

        SendClientMessage( playerid, COLOR_YELLOW, "Virtual World Set!" );

    }

    return 1;

}

[/pawn]

Fara reclama in semnatura!

Link to comment
Share on other sites

Faci asa:

[pawn]

if ( strcmp( cmdtext, "/world1", true ) == 0 )

{

    if ( IsPlayerInAnyVehicle( playerid ) )

    {

        SetVehicleVirtualWorld( GetPlayerVehicleID( playerid ), 1 );

        SendClientMessage( playerid, COLOR_YELLOW, "Virtual World + Vehicle Virtual World seted to 1! );

    }

    else

    {

        SetPlayerVirtualWorld( playerid, 1);

        SendClientMessage( playerid, COLOR_YELLOW, "Virtual World Set!" );

    }

    return 1;

}

[/pawn]

Aia va seta doar vehiculul in alt virtual world.

Uite cum vrei tu:

if( strcmp( cmdtext, "/world1", true ) == 0 )
{
    if( IsPlayerInAnyVehicle( playerid ) )
        SetVehicleVirtualWorld( GetPlayerVehicleID( playerid ), 1 );

    SetPlayerVirtualWorld( playerid, 1 );
    SendClientMessage( playerid, COLOR_YELLOW, "Virtual World Set !" );
    return 1;
}

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. For more details you can also review our Terms of Use and Privacy Policy.