Index: /trunk/src/game/Player.cpp
===================================================================
--- /trunk/src/game/Player.cpp (revision 88)
+++ /trunk/src/game/Player.cpp (revision 95)
@@ -13627,9 +13627,6 @@
 uint32 Player::GetUInt32ValueFromDB(uint16 index, uint64 guid)
 {
-    //rognar optimization
-    //must be improved!! "if" and "switch" - it's very not aesthetically :)))
-    //but we should know whith data is cached
-    //PLAYER_FIELD_ARENA_TEAM_INFO* very is often using with pvp&arena patch :)
-    if(       index == PLAYER_FIELD_ARENA_TEAM_INFO_1_1 + 0 * 6 + 5
+    // todo: cleanup in this, move to a separate function.
+    if(    index == PLAYER_FIELD_ARENA_TEAM_INFO_1_1 + 0 * 6 + 5
         || index == PLAYER_FIELD_ARENA_TEAM_INFO_1_1 + 1 * 6 + 5
         || index == PLAYER_FIELD_ARENA_TEAM_INFO_1_1 + 2 * 6 + 5
Index: /trunk/src/game/ObjectMgr.cpp
===================================================================
--- /trunk/src/game/ObjectMgr.cpp (revision 94)
+++ /trunk/src/game/ObjectMgr.cpp (revision 95)
@@ -186,5 +186,5 @@
     if(!result)
     {
-        sLog.outError( "ROGNAR LoadPlayerCache");
+        sLog.outError( "Loading Player Cache failed.");
         return;
     }
@@ -204,15 +204,15 @@
         tdata.clear();
         tdata = StrSplit(fields[2].GetCppString(), " ");
-        
-        pPPlayerInfo->unLevel = (uint32)atoi(tdata[UNIT_FIELD_LEVEL].c_str());
-        pPPlayerInfo->unfield = (uint32)atoi(tdata[UNIT_FIELD_BYTES_0].c_str());
-
-        pPPlayerInfo->unArenaInfoId0 = (uint32)atoi(tdata[PLAYER_FIELD_ARENA_TEAM_INFO_1_1 + (0 * 6)].c_str());
-        pPPlayerInfo->unArenaInfoId1 = (uint32)atoi(tdata[PLAYER_FIELD_ARENA_TEAM_INFO_1_1 + (1 * 6)].c_str());
-        pPPlayerInfo->unArenaInfoId2 = (uint32)atoi(tdata[PLAYER_FIELD_ARENA_TEAM_INFO_1_1 + (2 * 6)].c_str());
-
-        pPPlayerInfo->unArenaInfoSlot0 = (uint32)atoi(tdata[PLAYER_FIELD_ARENA_TEAM_INFO_1_1 + 0 * 6 + 5].c_str());
-        pPPlayerInfo->unArenaInfoSlot1 = (uint32)atoi(tdata[PLAYER_FIELD_ARENA_TEAM_INFO_1_1 + 1 * 6 + 5].c_str());
-        pPPlayerInfo->unArenaInfoSlot2 = (uint32)atoi(tdata[PLAYER_FIELD_ARENA_TEAM_INFO_1_1 + 2 * 6 + 5].c_str());
+
+        pPPlayerInfo->unLevel = Player::GetUInt32ValueFromArray(tdata,UNIT_FIELD_LEVEL);
+        pPPlayerInfo->unfield = Player::GetUInt32ValueFromArray(tdata,UNIT_FIELD_BYTES_0);
+
+        pPPlayerInfo->unArenaInfoId0 = Player::GetUInt32ValueFromArray(tdata,PLAYER_FIELD_ARENA_TEAM_INFO_1_1 + 0 * 6);
+        pPPlayerInfo->unArenaInfoId1 = Player::GetUInt32ValueFromArray(tdata,PLAYER_FIELD_ARENA_TEAM_INFO_1_1 + 1 * 6);
+        pPPlayerInfo->unArenaInfoId2 = Player::GetUInt32ValueFromArray(tdata,PLAYER_FIELD_ARENA_TEAM_INFO_1_1 + 2 * 6);
+
+        pPPlayerInfo->unArenaInfoSlot0 = Player::GetUInt32ValueFromArray(tdata,PLAYER_FIELD_ARENA_TEAM_INFO_1_1 + 0 * 6 + 5);
+        pPPlayerInfo->unArenaInfoSlot1 = Player::GetUInt32ValueFromArray(tdata,PLAYER_FIELD_ARENA_TEAM_INFO_1_1 + 1 * 6 + 5);
+        pPPlayerInfo->unArenaInfoSlot2 = Player::GetUInt32ValueFromArray(tdata,PLAYER_FIELD_ARENA_TEAM_INFO_1_1 + 2 * 6 + 5);
     
         pPPlayerInfo->unClass = (uint32)fields[3].GetUInt32();
