Correction, I fixed the error messages by adding ( ,plr) and ( ,killer) to the arguments, and that removed the error, but it may or may not work.
Update: tested with experience gain left out of the compilation, server still crashes due to money code.
error log:
Revision: * * SITML-Dev 8541 *
Date 11:10:2009. Time 12:39
//=====================================================
*** Hardware ***
Processor: Intel(R) Pentium(R) D CPU 3.00GHz
Number Of Processors: 2
Physical Memory: 2095124 KB (Available: 519136 KB)
Commit Charge Limit: 4033388 KB
*** Operation System ***
Microsoft Windows XP Home Edition Service Pack 3 (Version 5.1, Build 2600)
//=====================================================
Exception code: C0000005 ACCESS_VIOLATION
Fault address: 00401457 01:00000457 C:\\Documents and Settings\\Owner\\Desktop\\Mangos322a\\mangosd.exe
Registers:
EAX:00000035
EBX:1AC6BD18
ECX:00000000
EDX:00000000
ESI:00000000
EDI:0084D320
CS:EIP:001B:00401457
SS:ESP:0023:053E3104 EBP:053E4118
DS:0023 ES:0023 FS:003B GS:0000
Flags:00010282
Call stack:
Address Frame Function SourceFile
00401457 00000000 Object::GetUInt32Value+27
00709D0E 00000000 BattleGround::HandleKillPlayer+4E
007DFFDE 00000000 BattleGroundWS::HandleKillPlayer+3E
0045584D 00000000 Unit::DealDamage+116D
00456EB3 00000000 Unit::DealSpellDamage+173
00691B08 00000000 Spell::DoAllEffectOnTarget+438
00697D85 00000000 Spell::handle_delayed+C5
006A404B 00000000 SpellEvent::Execute+15B
00884B2C 00000000 EventProcessor::Update+EC
0045341B 00000000 Unit::Update+3B
004BDA8C 00000000 Player::Update+EC
00497276 00000000 Map::Update+D6
007D8E7E 00000000 MapInstanced::Update+DE
006008F8 00000000 MapManager::Update+128
005E562B 00000000 World::Update+77B
0042F81E 00000000 WorldRunnable::run+8E
0084D339 00000000 ACE_Based::Thread::ThreadTask+19
00A614D4 00000000 __WSAFDIsSet+FFFFFFFFFFFCC45C
78543433 00000000 _endthreadex+44
785434C7 00000000 _endthreadex+D8
7C80B729 00000000 GetModuleFileNameA+1BA
Call stack:
Address Frame Function SourceFile
7C90E514 00000000 KiFastSystemCallRet+0
7C802542 00000000 WaitForSingleObject+12
00A19C64 00000000 __WSAFDIsSet+FFFFFFFFFFF84BEC
00A864DA 00000000 __WSAFDIsSet+FFFFFFFFFFFF1462
00A8269F 00000000 __WSAFDIsSet+FFFFFFFFFFFED627
005FD63A 00000000 WorldSocketMgr::Wait+4A
1AA4EA54 00000000 0000:00000000
1AA4EA54 00000000 0000:00000000
6C696146 00000000
crash log when XP was used but money was not:
Revision: * * SITML-Dev 8541 *
Date 11:10:2009. Time 13:5
//=====================================================
*** Hardware ***
Processor: Intel(R) Pentium(R) D CPU 3.00GHz
Number Of Processors: 2
Physical Memory: 2095124 KB (Available: 295132 KB)
Commit Charge Limit: 4033388 KB
*** Operation System ***
Microsoft Windows XP Home Edition Service Pack 3 (Version 5.1, Build 2600)
//=====================================================
Exception code: C0000005 ACCESS_VIOLATION
Fault address: 00401457 01:00000457 C:\\Documents and Settings\\Owner\\Desktop\\Mangos322a\\mangosd.exe
Registers:
EAX:00000035
EBX:1AC47F98
ECX:00000000
EDX:00000000
ESI:053FF7E4
EDI:0084D330
CS:EIP:001B:00401457
SS:ESP:0023:053E9E84 EBP:053EAE98
DS:0023 ES:0023 FS:003B GS:0000
Flags:00010206
Call stack:
Address Frame Function SourceFile
00401457 00000000 Object::GetUInt32Value+27
00709D0E 00000000 BattleGround::HandleKillPlayer+4E
007DFFEE 00000000 BattleGroundWS::HandleKillPlayer+3E
0045584D 00000000 Unit::DealDamage+116D
00786613 00000000 ChatHandler::HandleDieCommand+103
0053A2D4 00000000 ChatHandler::ExecuteCommandInTable+284
0053AAEF 00000000 ChatHandler::ParseCommands+19F
00827E0F 00000000 WorldSession::HandleMessagechatOpcode+56F
005C5082 00000000 WorldSession::Update+192
005E697E 00000000 World::UpdateSessions+CE
005E5215 00000000 World::Update+365
0042F81E 00000000 WorldRunnable::run+8E
0084D349 00000000 ACE_Based::Thread::ThreadTask+19
00A614D4 00000000 __WSAFDIsSet+FFFFFFFFFFFCC45C
78543433 00000000 _endthreadex+44
785434C7 00000000 _endthreadex+D8
7C80B729 00000000 GetModuleFileNameA+1BA
Call stack:
Address Frame Function SourceFile
7C90E514 00000000 KiFastSystemCallRet+0
7C802542 00000000 WaitForSingleObject+12
00A19C64 00000000 __WSAFDIsSet+FFFFFFFFFFF84BEC
00A864DA 00000000 __WSAFDIsSet+FFFFFFFFFFFF1462
00A8269F 00000000 __WSAFDIsSet+FFFFFFFFFFFED627
005FD63A 00000000 WorldSocketMgr::Wait+4A
1AA5102C 00000000 0000:00000000
1AA5102C 00000000 0000:00000000
6C696146 00000000
Code used for exp only:
void BattleGround::HandleKillPlayer( Player *player, Player *killer )
{
//keep in mind that for arena this will have to be changed a bit
// add +1 deaths
UpdatePlayerScore(player, SCORE_DEATHS, 1);
// add +1 kills to group and +1 killing_blows to killer
if (killer)
{
Unit *pVictim = killer->getVictim();
uint32 v_level1 = (pVictim->getLevel());
uint32 loot1 = (1000*v_level1);
uint32 loot3 = (100*v_level1);
killer->GiveXP((int32)loot3, killer);
UpdatePlayerScore(killer, SCORE_HONORABLE_KILLS, 1);
UpdatePlayerScore(killer, SCORE_KILLING_BLOWS, 1);
for(BattleGroundPlayerMap::const_iterator itr = m_Players.begin(); itr != m_Players.end(); ++itr)
{
Player *plr = objmgr.GetPlayer(itr->first);
if (!plr || plr == killer)
continue;
if (plr->GetTeam() == killer->GetTeam() && plr->IsAtGroupRewardDistance(player))
Unit *pVictim = killer->getVictim();
uint32 v_level2 = (pVictim->getLevel());
uint32 loot2 = (1000*v_level2);
uint32 loot4 = (100*v_level2);
plr->GiveXP((int32)loot4, plr);
UpdatePlayerScore(plr, SCORE_HONORABLE_KILLS, 1);
}