View Single Post
  #1  
Old 05-26-2003, 08:27 AM
loudent2
Sarnak
 
Join Date: Apr 2003
Posts: 95
Default Small bug fix with player corpses.(snippets)

I changed the behavior slightly with corpses. If a corpse had no plat or items it was never saved which means empty corpses that could be used for rez were disappearing. I changed it so that it only disappears when empty of items after being looted

RCS file: /cvsroot/eqemu/NightDumps/NightDumps/Source/zone/PlayerCorpse.cpp,v
retrieving revision 1.1.1.1
diff -w -r1.1.1.1 PlayerCorpse.cpp
Code:
456,458c456,457
< bool Corpse::IsEmpty() {
< 	if (copper != 0 || silver != 0 || gold != 0 || platinum != 0)
< 		return false;
---
> bool Corpse::IsEmpty(bool bIgnoreRezXP) {

	if (copper != 0 || silver != 0 || gold != 0 || platinum != 0)
> 		return false;

	if(false == bIgnoreRezXP)
	{
		if(0 != rezzexp) return false;
	}
Code:
849c848
< 	if (this->IsEmpty()) {
---
> 	if (this->IsEmpty(true)) {


Index: PlayerCorpse.h
================================================== =================
RCS file: /cvsroot/eqemu/NightDumps/NightDumps/Source/zone/PlayerCorpse.h,v
retrieving revision 1.1.1.1
diff -w -r1.1.1.1 PlayerCorpse.h
Code:
59c59
< 	bool	IsEmpty();
---
> 	bool	IsEmpty(bool bIgnoreRexXP = false);
Reply With Quote