Jump to content

announce the ban


Recommended Posts

Posted

hi all :P

i want to ask if there is a patch to see an announce like:

"GM: n00b has been banned by GMlol for 2m reason: hack"

anyone know?

cuz i saw this into a server where i played (2.4.3)

this server have also the mute announce

thx

Posted
i want to ask if there is a patch to see an announce like:

"GM: n00b has been banned by GMlol for 2m reason: hack"

anyone know?

I saw this in an italian shard that use ArcEmu, It may be useful to have this in MaNGOS

Posted

like this?

diff --git a/src/game/Language.h b/src/game/Language.h
index 5b64cf5..c3d1963 100644
--- a/src/game/Language.h
+++ b/src/game/Language.h
@@ -348,7 +348,7 @@ enum MangosStrings
    LANG_BAN_YOUBANNED                  = 408,
    LANG_BAN_YOUPERMBANNED              = 409,
    LANG_BAN_NOTFOUND                   = 410,
-
+    
    LANG_UNBAN_UNBANNED                 = 411,
    LANG_UNBAN_ERROR                    = 412,

@@ -766,7 +766,9 @@ enum MangosStrings
    LANG_RESET_PET_TALENTS_ONLINE       = 1127,
    LANG_TAXINODE_ENTRY_LIST_CHAT       = 1128,
    LANG_TAXINODE_ENTRY_LIST_CONSOLE    = 1129,
-    // Room for more level 3              1130-1199 not used
+    LANG_BAN_WORLD_ANNOUNCE                = 1130,
+    LANG_PERMBAN_WORLD_ANNOUNCE            = 1131,
+    // Room for more level 3              1132-1199 not used

    // Debug commands
    LANG_CINEMATIC_NOT_EXIST            = 1200,
diff --git a/src/game/Level3.cpp b/src/game/Level3.cpp
index 2da8326..0d6bb37 100644
--- a/src/game/Level3.cpp
+++ b/src/game/Level3.cpp
@@ -5383,9 +5383,15 @@ bool ChatHandler::HandleBanHelper(BanMode mode, const char* args)
    {
        case BAN_SUCCESS:
            if(atoi(duration)>0)
+            {
                PSendSysMessage(LANG_BAN_YOUBANNED,nameOrIP.c_str(),secsToTimeString(TimeStringToSecs(duration),true).c_str(),reason);
+                sWorld.SendWorldText(LANG_BAN_WORLD_ANNOUNCE,nameOrIP.c_str(),m_session ? m_session->GetPlayerName() : "",secsToTimeString(TimeStringToSecs(duration),true).c_str(),reason);
+            }
            else
+            {
                PSendSysMessage(LANG_BAN_YOUPERMBANNED,nameOrIP.c_str(),reason);
+                sWorld.SendWorldText(LANG_PERMBAN_WORLD_ANNOUNCE,nameOrIP.c_str(),m_session ? m_session->GetPlayerName() : "",reason);
+            }
            break;
        case BAN_SYNTAX_ERROR:
            return false;

delete from `mangos_string` where `entry`='1130';
insert into `mangos_string` (`entry`, `content_default`, `content_loc1`, `content_loc2`, `content_loc3`, `content_loc4`, `content_loc5`, `content_loc6`, `content_loc7`, `content_loc8`) values('1130','|cffff0000[GM]:|r %s was banned by %s for %s. Reason: %s.',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
delete from `mangos_string` where `entry`='1131';
insert into `mangos_string` (`entry`, `content_default`, `content_loc1`, `content_loc2`, `content_loc3`, `content_loc4`, `content_loc5`, `content_loc6`, `content_loc7`, `content_loc8`) values('1131','|cffff0000[GM]:|r %s was banned by %s for eternity. Reason: %s.',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);

Posted
I saw this in an italian shard that use ArcEmu, It may be useful to have this in MaNGOS

another player from wowis i see :D

i'm italian too :rolleyes:

×
×
  • 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. Privacy Policy Terms of Use