Go Back   EQEmulator Home > EQEmulator Forums > Development > Development::Server Code Submissions

Reply
 
Thread Tools Display Modes
  #1  
Old 05-18-2011, 02:50 PM
Sikkun
Sarnak
 
Join Date: Apr 2011
Posts: 30
Default Mounted Out of Combated Regeration (Complete)

Zone
client_packet.cpp
void Client::Handle_OP_ClientUpdate(const EQApplicationPacket *app) method
Insert code after // Break Hide if moving without sneaking and set rewind timer if moved
code block.

Code:
//allow player to have OOC regeneration on a mount
	if(ppu->y_pos == y_pos || ppu->x_pos == x_pos)
	{
		if(GetHorseId() != 0)
		{
			playeraction = 1;
		}
	}
	else if(ppu->y_pos != y_pos || ppu->x_pos != x_pos)
	{
		if(GetHorseId() != 0)
		{
			playeraction = 0;
		}
	}
Zone
client_packet.cpp
void Client::Handle_OP_AAAction(const EQApplicationPacket *app) method
insert code before mlog(AA__IN, "Received OP_AAAction");

Code:
//check if you are on a mount
	if (GetHorseId() != 0)
	{
		playeraction = 0;
	}
Zone
horse.cpp
void Client::SetHorseId(int16 horseid_in) method

Code:
void Client::SetHorseId(int16 horseid_in) {
	//if its the same, do nothing
	if(horseId == horseid_in)
		return;
	
	//otherwise it changed.
	//if we have a horse, get rid of it no matter what.
	if(horseId) {
		Mob *horse = entity_list.GetMob(horseId);
		if(horse != NULL)
		{
			horse->Depop();
			//set player to standing
			playeraction = 0;
		}
	}
	
	//now we take whatever they gave us.
	horseId = horseid_in;
}
Reply With Quote
Reply


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 12:33 AM.


 

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 - 2024, Jelsoft Enterprises Ltd.
Template by Bluepearl Design and vBulletin Templates - Ver3.3