dcmd_oaccban(playerid,params[]) {
if(PlayerInfo[playerid][pAdmin] == 0) return SystemMsg(playerid, "You must be a admin to use this command!");
if(!strlen(params)) return SystemMsg(playerid, "/oaccban [playername]");
if(IsNumeric(params)) return SystemMsg(playerid, "That player is not connected!");
new player2[128]; format(player2, sizeof(player2), params);
if(!udb_Exists(player2)) {
SystemMsg(playerid, "Account does not exist");
}
else {
new file[128];format(file,sizeof(file),"%s.dudb.sav",udb_encode(player2));
dini_IntSet(file, "pBanned", 1);
SystemMsg(playerid, "The selected user has been banned");
new str2[MAX_STRING], second, minute, hour, day, month, year;
gettime(hour, minute, second);
getdate(year, month, day);
format(str2, sizeof(str2), "ADMIN %s offline account banned %s on %d/%d/%d at %d:%d:%d.)", PlayerName(playerid), PlayerName(player2), month, day, year, hour, minute, second);
ServerLog(str2);
return 1;
}
return 1;
}
format(str2, sizeof(str2), "ADMIN %s offline account banned %s on %d/%d/%d at %d:%d:%d.)", PlayerName(playerid), PlayerName(player2), month, day, year, hour, minute, second);
format(str2, sizeof(str2), "ADMIN %s offline account banned %s on %d/%d/%d at %d:%d:%d.)", PlayerName(playerid), PlayerName(player2), month, day, year, hour, minute, second);
PlayerName(player2),
player2,
stock PlayerName(playerid) {
new playerName[MAX_PLAYER_NAME];
GetPlayerName(playerid, playerName, MAX_PLAYER_NAME);
return playerName;
}
|
Originally Posted by MisterTickle
Don't believe this is the problem, This is used in every other log and they work fine.
|