Go Back   EQEmulator Home > EQEmulator Forums > Development > Development::Development

Development::Development Forum for development topics and for those interested in EQEMu development. (Not a support forum)

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #12  
Old 06-22-2008, 12:31 PM
Derision
Developer
 
Join Date: Feb 2004
Location: UK
Posts: 1,540
Default

The previous patch to GetPVP didn't check if there was a watermap loaded for a zone and will crash the zone if there isn't. This should work better:

Code:
--- /tmp/EQEmu-0.7.0-1115/zone/client.h 2008-06-15 00:07:57.000000000 +0100
+++ client.h    2008-06-22 17:18:17.000000000 +0100
@@ -36,6 +36,7 @@
 #include "mob.h"
 #include "npc.h"
 #include "zone.h"
+#include "watermap.h"
 #include "AA.h"
 #include "../common/seperator.h"
 #include "../common/Item.h"
@@ -275,7 +276,8 @@
        void    SetGM(bool toggle);
        void    SetPVP(bool toggle);

-       inline bool     GetPVP()        const { return zone->GetZoneID() == 77 ? true : m_pp.pvp; }
+       inline bool     GetPVP()        const { if(zone->watermap != NULL) return zone->watermap->InPVPArea(x_pos, y_pos, z_pos) ? true : m_pp.pvp;
+                                               else return  m_pp.pvp; }
        inline bool     GetGM()         const { return (bool) m_pp.gm; }

        inline void     SetBaseClass(uint32 i) { m_pp.class_=i; }
and thanks for hosting the files Angelox.
Reply With Quote
 


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

   

All times are GMT -4. The time now is 03:44 PM.


 

Everquest is a registered trademark of Daybreak Game Company LLC.
EQEmulator is not associated or affiliated in any way with Daybreak Game Company LLC.
Except where otherwise noted, this site is licensed under a Creative Commons License.
       
Powered by vBulletin®, Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Template by Bluepearl Design and vBulletin Templates - Ver3.3