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

Archive::Development Archive area for Development's posts that were moved here after an inactivity period of 90 days.

Reply
 
Thread Tools Display Modes
  #1  
Old 06-09-2004, 10:09 AM
mlan
Fire Beetle
 
Join Date: Jun 2004
Posts: 9
Default Jr Dev Code

i haven't tested this code but i think it should work. i'll test it later tonight, think i got files to revert back and use 5.7DR3 since DR4 seems kinda borked for me.

not sure if theres some sort of skill cap at 252 or not but i went ahead and put in a little extra code to make sure the skill didn't go up forever

maxskill.h

mob monk dw - ln567

OLD
Code:
				case MONK: case MONKGM:{
				// 1 252 252
					r_value = level*7;  // This can't be right can it?
					break
;
				}
NEW
Code:
				case MONK: case MONKGM:{
				// 1 252 252
					r_value = level*7;  // This can't be right can it?
					if (r_value > 252)
						r_value = 252;
					break;
				}
same with this one in another file

maxskill.cpp

dw for monk - ln641

OLD
Code:
				case MONK: case MONKGM:{
				// 1 252 252
					r_value = level*7;  // This can't be right can it?
					break;
NEW
Code:
				case MONK: case MONKGM:{
				// 1 252 252
					r_value = level*7;  // This can't be right can it?
					if (r_value > 252)
						r_value = 252;
					break;
tried to work planar durability into the hp calc formula and took the hp from buffs out of the equation until after the aa calcs since they aren't added in on live servers.

client.cpp

PD AA hp - ln1504

OLD
Code:
sint32 Client::CalcMaxHP() {
	max_hp = (CalcBaseHP() + itembonuses->HP + spellbonuses->HP);
	if (GetAA(28) != 0) {
		if (GetAA(28) == 1)
			max_hp += (uint32)((float)max_hp/100.0f) * ((GetAA(120)!=0) ? 4.0f:2.0f);
		if (GetAA(28) == 2)
			max_hp += (uint32)((float)max_hp/100.0f) * ((GetAA(120)!=0) ? 7.0f:5.0f);
		if (GetAA(28) == 3)
			max_hp += (uint32)((float)max_hp/100.0f) * ((GetAA(120)!=0) ? 12.0f:10.0f);
	}
/*
	if (GetAA(120) != 0) {
		LogFile->write(EQEMuLog::Debug, "Physical Enhancement: MaxHP=%i", max_hp);
		max_hp += (uint32)((float)max_hp/100.0f) * 2.3f;
		LogFile->write(EQEMuLog::Debug, "Physical Enhancement: MaxHP=%i", max_hp);
	}
*/
	if (cur_hp > max_hp)
		cur_hp = max_hp;
	return max_hp;
}
NEW
Code:
sint32 Client::CalcMaxHP() {
	max_hp = CalcBaseHP() + itembonuses->HP;
	if ((GetAA(28) != 0) || (GetAA(143) != 0) || (GetAA(120) != 0)) {
		float hp_bonus = 0.0f;
		if (GetAA(28) == 1)
			hp_bonus += 2.0f;
		if (GetAA(28) == 2)
			hp_bonus += 5.0f;
		if (GetAA(28) == 3)
			hp_bonus += 10.0f;
		if (GetAA(120) == 1)
			hp_bonus += 2.0f;
		if (GetAA(143) != 0)
			hp_bonus += GetAA(143) * 1.5f;			
		max_hp += (uint32)((float)max_hp/100.0f) * hp_bonus;
	}
/*
	if (GetAA(120) != 0) {
		LogFile->write(EQEMuLog::Debug, "Physical Enhancement: MaxHP=%i", max_hp);
		max_hp += (uint32)((float)max_hp/100.0f) * 2.3f;
		LogFile->write(EQEMuLog::Debug, "Physical Enhancement: MaxHP=%i", max_hp);
	}
*/
	max_hp += spellbonuses->HP;
	if (cur_hp > max_hp)
		cur_hp = max_hp;
	return max_hp;
}
added in planar power into the stat cap code

client.cpp

statAA - ln270

OLD
Code:
// Return max stat value for level
sint16 Client::GetMaxStat() {
	int level = GetLevel();
	
	if (level < 61) {
		return 255;
	}
	else if (level < 66) {
		return 255 + 5 * (level - 60);
	}
	else {
		return 280;
	}	
}
NEW
Code:
// Return max stat value for level
sint16 Client::GetMaxStat() {
	int level = GetLevel();
	
	if (level < 61) {
		return 255;
	}
	else if (level < 66) {
		return 255 + 5 * ((level - 60) + GetAA(142));
	}
	else {
		return 280 + 5 * GetAA(142);
	}	
}
*edit* pasted the same code twice and didn't notice. repasted proper code.

*edit2* fixed a few compile errors that i overlooked
Reply With Quote
  #2  
Old 06-09-2004, 10:10 AM
mlan
Fire Beetle
 
Join Date: Jun 2004
Posts: 9
Default

will go through some more code later tonight and look at getting more AA abilities working
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 02:35 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 - 2024, Jelsoft Enterprises Ltd.
Template by Bluepearl Design and vBulletin Templates - Ver3.3