CMD:setvw(playerid, params[]){new targetid, virtualid, name[MAX_PLAYER_NAME], name2[MAX_PLAYER_NAME], string[256];if(!IsPlayerAdmin(playerid)) return SendClientMessage(playerid, COLOR_GREEN, \"Nem vagy admin!\");if(!IsPlayerConnected(targetid)) return SendClientMessage(playerid, COLOR_GREEN, \"Nincs fent a jatekos!\");if(sscanf(params, \"dd\", targetid, virtualid)) return SendClientMessage(playerid, COLOR_GREEN, \"Használat: /setvw [playerid] [vwid]\");GetPlayerName(playerid, name, sizeof(name));GetPlayerName(playerid, name2, sizeof(name2));format(string, sizeof(string), \"%s atallitotta %s VirtualWordjet %d-re!\", name, name2, virtualid);SendClientMessageToAll(COLOR_GREEN, string);SetPlayerVirtualWorld(playerid, virtualid);return 1;}
GetPlayerName(playerid, name, sizeof(name));GetPlayerName(playerid, name2, sizeof(name2));[/quote]
@SheetNem gyanús hogy ugyanazt másolod be újra rosszul? GetPlayerName(playerid, name, sizeof(name));GetPlayerName(playerid, name2, sizeof(name2)); [/quote]Nem olvastam át az egész kódot csak az elejét.[pawn]CMD:setvw(playerid, params[]){new targetid, virtualid, name[MAX_PLAYER_NAME], name2[MAX_PLAYER_NAME], string[256];if(!IsPlayerAdmin(playerid)) return SendClientMessage(playerid, COLOR_GREEN, \"Nem vagy admin!\");if(sscanf(params, \"ud\", targetid, virtualid)) return SendClientMessage(playerid, COLOR_GREEN, \"Használat: /setvw [playerid] [vwid]\");if(!IsPlayerConnected(targetid)) return SendClientMessage(playerid, COLOR_GREEN, \"Nincs fent a jatekos!\");GetPlayerName(playerid, name, sizeof(name));GetPlayerName(targetid, name2, sizeof(name2));format(string, sizeof(string), \"%s atallitotta %s VirtualWordjet %d-re!\", name, name2, virtualid);SendClientMessageToAll(COLOR_GREEN, string);SetPlayerVirtualWorld(targetid, virtualid);return 1;}[/pawn]
GetPlayerName(playerid, name, sizeof(name));GetPlayerName(playerid, name2, sizeof(name2));