Jump to content

[10245][Cosmetic Patch] Arena Rating and Personal Rating in mangos.conf


Guest fdb_

Recommended Posts

Hello,

Here is a little cosmetic patch to set the default arena rating and the default arena personal rating inside the mangos.conf.

diff --git a/src/game/ArenaTeam.cpp b/src/game/ArenaTeam.cpp
index ed4ce5b..db5de09 100644
--- a/src/game/ArenaTeam.cpp
+++ b/src/game/ArenaTeam.cpp
@@ -36,10 +36,13 @@ ArenaTeam::ArenaTeam()
    m_stats.games_week    = 0;
    m_stats.games_season  = 0;
    m_stats.rank          = 0;
+/*  
    if (sWorld.getConfig(CONFIG_UINT32_ARENA_SEASON_ID) >= 6)
        m_stats.rating    = 0;
    else
        m_stats.rating    = 1500;
+*/
+    m_stats.rating        = sWorld.getConfig(CONFIG_UINT32_ARENA_STARTRATING);
    m_stats.wins_week     = 0;
    m_stats.wins_season   = 0;
}
@@ -136,10 +139,13 @@ bool ArenaTeam::AddMember(const uint64& PlayerGuid)
    newmember.wins_week         = 0;
    if (sWorld.getConfig(CONFIG_UINT32_ARENA_SEASON_ID) >= 6)
    {
+/*
        if (m_stats.rating < 1000)
            newmember.personal_rating = 0;
        else
            newmember.personal_rating = 1000;
+*/
+        newmember.personal_rating = sWorld.getConfig(CONFIG_UINT32_ARENA_STARTPERSONALRATING);
    }
    else
    {
diff --git a/src/game/World.cpp b/src/game/World.cpp
index b1605d5..c20924c 100644
--- a/src/game/World.cpp
+++ b/src/game/World.cpp
@@ -721,6 +721,8 @@ void World::LoadConfigSettings(bool reload)
    setConfig(CONFIG_BOOL_ARENA_QUEUE_ANNOUNCER_JOIN,                  "Arena.QueueAnnouncer.Join", false);
    setConfig(CONFIG_BOOL_ARENA_QUEUE_ANNOUNCER_EXIT,                  "Arena.QueueAnnouncer.Exit", false);
    setConfig(CONFIG_UINT32_ARENA_SEASON_ID,                           "Arena.ArenaSeason.ID", 1);
+    setConfig(CONFIG_UINT32_ARENA_STARTRATING,                         "Arena.StartRating", 1500);
+    setConfig(CONFIG_UINT32_ARENA_STARTPERSONALRATING,                 "Arena.StartPersonalRating", 1500);
    setConfig(CONFIG_BOOL_ARENA_SEASON_IN_PROGRESS,                    "Arena.ArenaSeason.InProgress", true);

    setConfig(CONFIG_BOOL_OFFHAND_CHECK_AT_TALENTS_RESET, "OffhandCheckAtTalentsReset", false);
diff --git a/src/game/World.h b/src/game/World.h
index 6711ff6..d28f168 100644
--- a/src/game/World.h
+++ b/src/game/World.h
@@ -173,6 +173,8 @@ enum eConfigUint32Values
    CONFIG_UINT32_TIMERBAR_BREATH_MAX,
    CONFIG_UINT32_TIMERBAR_FIRE_GMLEVEL,
    CONFIG_UINT32_TIMERBAR_FIRE_MAX,
+    CONFIG_UINT32_ARENA_STARTRATING,
+    CONFIG_UINT32_ARENA_STARTPERSONALRATING,
    CONFIG_UINT32_VALUE_COUNT
};

diff --git a/src/mangosd/mangosd.conf.dist.in b/src/mangosd/mangosd.conf.dist.in
index c52602b..2671542 100644
--- a/src/mangosd/mangosd.conf.dist.in
+++ b/src/mangosd/mangosd.conf.dist.in
@@ -1317,6 +1317,14 @@ BattleGround.PremadeGroupWaitForMatch = 1800000
#        Default: 1 (active)
#                 0 (finished)
#
+#    Arena.StartRating
+#        Default Rating at team creation
+#        Default: 1500
+#
+#    Arena.StartPersonalRating
+#        Default Personal Rating at team creation (Arena.ArenaSeason.ID should be >= 6 to use this parameter)
+#        Default: 1500
+#
###################################################################################################################

Arena.MaxRatingDifference = 150
@@ -1327,6 +1335,8 @@ Arena.QueueAnnouncer.Join = 0
Arena.QueueAnnouncer.Exit = 0
Arena.ArenaSeason.ID = 1
Arena.ArenaSeason.InProgress = 1
+Arena.StartRating = 600
+Arena.StartPersonalRating = 600

###################################################################################################################
# NETWORK CONFIG

Dunno if it can be included in git coz it is not very blizz like.

Have fun.

Link to comment
Share on other sites

It may not be considered to be "retail" but it's certainly useful. In MaNGOS there are GM commands that allow you to modify arena points. What I like about this is it permits you to set these values globally. I'd love to see many more settings added to mangosd.conf because, blizz-like or not, it allows administrators greater flexibility in choosing how they wish to set the environment they wish to offer to players, giving each server it's own personality which allows you to be somewhat unique instead of just another server.

Link to comment
Share on other sites

  • 3 weeks later...
  • 3 months later...
×
×
  • 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