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

Reply
 
Thread Tools Display Modes
  #1  
Old 02-17-2011, 06:57 PM
sorvani
Dragon
 
Join Date: May 2010
Posts: 965
Default

Working on my test server. unified diff sent to gaeorn.

Code:
int Mob::CalcSpellEffectValue(int16 spell_id, int effect_id, int caster_level, Mob *caster, int ticsremaining)
{
	int formula, base, max, effect_value;

	if
	(
		!IsValidSpell(spell_id) ||
		effect_id < 0 ||
		effect_id >= EFFECT_COUNT
	)
		return 0;

	formula = spells[spell_id].formula[effect_id];
	base = spells[spell_id].base[effect_id];
	max = spells[spell_id].max[effect_id];

	if(IsBlankSpellEffect(spell_id, effect_id))
		return 0;

	effect_value = CalcSpellEffectValue_formula(formula, base, max, caster_level, spell_id, ticsremaining);

	if(caster && IsBardSong(spell_id) &&
	(spells[spell_id].effectid[effect_id] != SE_AttackSpeed) &&
	(spells[spell_id].effectid[effect_id] != SE_AttackSpeed2) &&
	(spells[spell_id].effectid[effect_id] != SE_AttackSpeed3) &&
	(spells[spell_id].effectid[effect_id] != SE_Lull) &&
	(spells[spell_id].effectid[effect_id] != SE_ChangeFrenzyRad) &&
	(spells[spell_id].effectid[effect_id] != SE_Harmony)) {
		int oval = effect_value;
		int mod = caster->GetInstrumentMod(spell_id);
		effect_value = effect_value * mod / 10;
		mlog(SPELLS__BARDS, "Effect value %d altered with bard modifier of %d to yeild %d", oval, mod, effect_value);
	}

	return(effect_value);
}
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 06:37 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