View Single Post
  #4  
Old 04-21-2009, 07:34 PM
realityincarnate
Developer
 
Join Date: Dec 2007
Posts: 122
Default for real this time...

Ok, I think I've got the problems nailed down. The reason it only worked on my end is that I somehow missed a file in the diff the first time around. But I tinkered some more and it seems to be retaining the correct settings, and there's no sign of any twisted faces. Sorry about the sloppiness, I hope it didn't cause any real inconvenience.

Here's a fresh diff
Code:
Index: common/eq_constants.h
===================================================================
--- common/eq_constants.h	(revision 438)
+++ common/eq_constants.h	(working copy)
@@ -148,6 +148,7 @@
 #define AT_Split			28	// 0 = normal, 1 = autosplit on
 #define AT_Size				29	// spawn's size
 #define AT_NPCName		31	// change PC's name's color to NPC color 0 = normal, 1 = npc name
+#define AT_ShowHelm	43	// 0 = do not show helmet graphic, 1 = show graphic
 //#define AT_Trader			300  // Bazzar Trader Mode
 
 // solar: animations for AT_Anim
Index: common/eq_packet_structs.h
===================================================================
--- common/eq_packet_structs.h	(revision 438)
+++ common/eq_packet_structs.h	(working copy)
@@ -876,7 +876,7 @@
 /*7080*/	sint32				ldon_points_available;
 /*7084*/	uint8				unknown5940[112];
 /*7196*/	uint32				tribute_time_remaining;	//in miliseconds
-/*7200*/	uint32				unknown6048;
+/*7200*/	uint32				showhelm;
 /*7204*/	uint32				career_tribute_points;
 /*7208*/	uint32				unknown6056;
 /*7212*/	uint32				tribute_points;
Index: common/patches/SoF.cpp
===================================================================
--- common/patches/SoF.cpp	(revision 438)
+++ common/patches/SoF.cpp	(working copy)
@@ -586,8 +586,7 @@
 	OUT(raidAutoconsent);
 	OUT(guildAutoconsent);
 //	OUT(unknown19575[5]);
-//	OUT(showhelm);
-	eq->showhelm = 1;
+	eq->showhelm = emu->showhelm;
 	OUT(RestTimer);
 //	OUT(unknown19584[4]);
 //	OUT(unknown19588);
Index: common/patches/Titanium.cpp
===================================================================
--- common/patches/Titanium.cpp	(revision 438)
+++ common/patches/Titanium.cpp	(working copy)
@@ -382,8 +382,7 @@
 	OUT(raidAutoconsent);
 	OUT(guildAutoconsent);
 //	OUT(unknown19575[5]);
-//	OUT(showhelm);
-	eq->showhelm = 1;
+	eq->showhelm = emu->showhelm;
 //	OUT(unknown19584[4]);
 //	OUT(unknown19588);
 
@@ -470,7 +469,7 @@
 //		eq->padding0070 = emu->padding0070;
 		eq->eyecolor1 = emu->eyecolor1;
 //		eq->unknown0115[24] = emu->unknown0115[24];
-		eq->showhelm = true;
+		eq->showhelm = emu->showhelm;
 //		eq->unknown0140[4] = emu->unknown0140[4];
 		eq->is_npc = emu->is_npc;
 		eq->hairstyle = emu->hairstyle;
Index: zone/client.cpp
===================================================================
--- zone/client.cpp	(revision 438)
+++ zone/client.cpp	(working copy)
@@ -1579,6 +1579,7 @@
 	}
 	ns->spawn.size			= 0; // Changing size works, but then movement stops! (wth?)
 	ns->spawn.runspeed		= (gmspeed == 0) ? runspeed : 3.125f;
+	if (!m_pp.showhelm) ns->spawn.showhelm = 0;
 
 	// @merth: pp also hold this info; should we pull from there or inventory?
 	// (update: i think pp should do it, as this holds LoY dye - plus, this is ugly code with Inventory!)
Index: zone/client_packet.cpp
===================================================================
--- zone/client_packet.cpp	(revision 438)
+++ zone/client_packet.cpp	(working copy)
@@ -2083,6 +2083,10 @@
 		// don't do anything with this, we tell the client when it's
 		// levitating, not the other way around
 	}
+	else if (sa->type == AT_ShowHelm) 
+	{
+		m_pp.showhelm = (sa->parameter == 1);
+	}
 	else {
 		cout << "Unknown SpawnAppearance type: 0x" << hex << setw(4) << setfill('0') << sa->type << dec
 			<< " value: 0x" << hex << setw(8) << setfill('0') << sa->parameter << dec << endl;
Index: zone/mob.cpp
===================================================================
--- zone/mob.cpp	(revision 438)
+++ zone/mob.cpp	(working copy)
@@ -713,8 +713,8 @@
 	ns->spawn.findable	= findable?1:0;
 // vesuvias - appearence fix
 	ns->spawn.light		= light;
+	ns->spawn.showhelm = 1;	
 
-
 	ns->spawn.invis		= (invisible || hidden) ? 1 : 0;	// TODO: load this before spawning players
 	ns->spawn.NPC		= IsClient() ? 0 : 1;
 	ns->spawn.petOwnerId	= ownerid;
Reply With Quote