Need me /setworld command..
#1

Is explained in the title .. If you do not understand I want to change the world with a player command.
Reply
#2

pawn Код:
YCMD:setworld(playerid, o[], help)
{
    if(help) return SendClientMessage(playerid, -1, "Change a player world");
    new id, world, name[ MAX_PLAYER_NAME ], name2[ MAX_PLAYER_NAME ], string[ 128 ];
    if(sscanf(o,"ui", id, world)) return SendClientMessage(playerid, -1, "Syntax Error: /setworld [PlayerName/ID] [World]");
    if(id == INVALID_PLAYER_ID) return SendClientMessage(playerid, -1, "This player is offline"):
    GetPlayerName(playerid, name, MAX_PLAYER_NAME); GetPlayerName(id, name2, MAX_PLAYER_NAME);
    format(string, sizeof(string),"%s has changed %s virtual world to %d", name, name2, world);
    SendClientMessageToAll(-1, string);
    SetPlayerVirtualWorld(id, world);
    return 1;
}
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)