Adding Cure to Light Elemental
-
- Posts: 129
- Joined: Wed May 27, 2015 4:23 pm
Adding Cure to Light Elemental
I tried to change the light elemental casting regen to cure by changing the spellID in the core from 108 to 2, however, the game crashes when the elemental begins casting (it never finishes)
Is there any reason why it crashes?
Is there any reason why it crashes?
Re: Adding Cure to Light Elemental
have you tried reading the message from visual studio when it crashes?
-
- Posts: 129
- Joined: Wed May 27, 2015 4:23 pm
Re: Adding Cure to Light Elemental
I'll post the error in a bit. Basically I was able to get past the first bit which was an issue with cure enmity not extending to the light spirit. There was a one line of code battle utils that called for a debug break if the user wasn't a player so I commented that out but now the crash happens due to something with a tree in the connect server so I'll post that.
-
- Posts: 129
- Joined: Wed May 27, 2015 4:23 pm
Re: Adding Cure to Light Elemental
When I debug, I get an Unhandled exception in Visual Studio
The failure points to xtree
The last line is where it failed
The failure points to xtree
Code: Select all
_Nodeptr& _Lmost() const
{ // return leftmost node in nonmutable tree
return (this->_Left(this->_Myhead));
Re: Adding Cure to Light Elemental
you'd want to check the call stack for a line that's actually in dsp's source instead of the STL, since it's more likely a fault of DSP's code than microsofts
also which exception is useful information as well
also which exception is useful information as well
-
- Posts: 129
- Joined: Wed May 27, 2015 4:23 pm
Re: Adding Cure to Light Elemental
This is what I got on my last attempt:
The thread 0x1574 has exited with code 0 (0x0).
Unhandled exception at 0x012F51E6 in DSGame-server.exe: 0xC0000005: Access violation reading location 0x28BA5F70.
This was in the call stack
DSGame-server.exe!battleutils::GenerateCureEnmity(CBattleEntity * PSource, CBattleEntity * PTarget, unsigned short amount) Line 3554 C++
DSGame-server.exe!CLuaBaseEntity::updateEnmityFromCure(lua_State * L) Line 6159 C++
DSGame-server.exe!Lunar<CLuaBaseEntity>::thunk(lua_State * L) Line 173 C++
lua51.dll!6740266f() Unknown
[Frames below may be incorrect and/or missing, no symbols loaded for lua51.dll]
DSGame-server.exe!CMagicState::FinishSpell() Line 668 C++
DSGame-server.exe!CAIPetDummy::ActionMagicFinish() Line 1062 C++
DSGame-server.exe!CAIPetDummy::ActionMagicCasting() Line 1052 C++
DSGame-server.exe!CAIPetDummy::CheckCurrentAction(unsigned int tick) Line 106 C++
DSGame-server.exe!CZoneEntities::ZoneServer(unsigned int tick) Line 940 C++
DSGame-server.exe!CZone::ZoneServer(unsigned int tick) Line 791 C++
DSGame-server.exe!zone_server(unsigned int tick, CTaskMgr::CTask * PTask) Line 81 C++
DSGame-server.exe!CTaskMgr::DoTimer(unsigned int tick) Line 71 C++
DSGame-server.exe!main(int argc, char * * argv) Line 251 C++
The thread 0x1574 has exited with code 0 (0x0).
Unhandled exception at 0x012F51E6 in DSGame-server.exe: 0xC0000005: Access violation reading location 0x28BA5F70.
This was in the call stack
DSGame-server.exe!battleutils::GenerateCureEnmity(CBattleEntity * PSource, CBattleEntity * PTarget, unsigned short amount) Line 3554 C++
DSGame-server.exe!CLuaBaseEntity::updateEnmityFromCure(lua_State * L) Line 6159 C++
DSGame-server.exe!Lunar<CLuaBaseEntity>::thunk(lua_State * L) Line 173 C++
lua51.dll!6740266f() Unknown
[Frames below may be incorrect and/or missing, no symbols loaded for lua51.dll]
DSGame-server.exe!CMagicState::FinishSpell() Line 668 C++
DSGame-server.exe!CAIPetDummy::ActionMagicFinish() Line 1062 C++
DSGame-server.exe!CAIPetDummy::ActionMagicCasting() Line 1052 C++
DSGame-server.exe!CAIPetDummy::CheckCurrentAction(unsigned int tick) Line 106 C++
DSGame-server.exe!CZoneEntities::ZoneServer(unsigned int tick) Line 940 C++
DSGame-server.exe!CZone::ZoneServer(unsigned int tick) Line 791 C++
DSGame-server.exe!zone_server(unsigned int tick, CTaskMgr::CTask * PTask) Line 81 C++
DSGame-server.exe!CTaskMgr::DoTimer(unsigned int tick) Line 71 C++
DSGame-server.exe!main(int argc, char * * argv) Line 251 C++
Re: Adding Cure to Light Elemental
ah, that's why they don't cast cure then right now, because updateEnmityFromCure only processes if the *target* is a PC (instead of the caster, which it should be). So the pet goes into a function that expects a character, and pretty bad things happen. Interesting though, that also means that a player healing a pet generates zero enmity.
I'll change it in a bit, see what happens
I'll change it in a bit, see what happens
-
- Posts: 129
- Joined: Wed May 27, 2015 4:23 pm
Re: Adding Cure to Light Elemental
Awesome! Thanks
-
- Posts: 129
- Joined: Wed May 27, 2015 4:23 pm
Re: Adding Cure to Light Elemental
Thanks worked like a charm. Now I can attempt to mess around with puppetmaster AI