Go Back   EQEmulator Home > EQEmulator Forums > Support > Spell Support

Spell Support Broken Spells? Want them Fixed? Request it here.

Reply
 
Thread Tools Display Modes
  #1  
Old 09-22-2019, 12:57 PM
strugglegenerator's Avatar
strugglegenerator
Hill Giant
 
Join Date: May 2012
Location: Minnesota
Posts: 231
Question Boon of the Clear Mind

I can cast the single target version of Clarity on players in my group. Great!

However, I cannot cast the group version of Clarity (Boon of the Clear Mind) on my group because I get the error: "Your spell is too powerful for your intended target."

Why am I not allowed to cast Boon of the Clear Mind on my group? It only casts on myself (the enchanter).

I cannot find anywhere in the database to fix this. I even compared Clarity to Boon of the Clear Mind, but they have identical settings other than 1 spell being a group buff and the other being a single target.
Reply With Quote
  #2  
Old 09-22-2019, 02:11 PM
chrsschb's Avatar
chrsschb
Dragon
 
Join Date: Nov 2008
Location: GA
Posts: 904
Default

In rules_values table:
Code:
Spells:BuffLevelRestrictions  True
Set to false.
__________________
Clumsy's World: Resurgence [2019-Present]
Clumsy's World 2.0 [2014-2016]
Clumsy's World [2006-2012]
Reply With Quote
  #3  
Old 09-22-2019, 02:26 PM
strugglegenerator's Avatar
strugglegenerator
Hill Giant
 
Join Date: May 2012
Location: Minnesota
Posts: 231
Default

Thank you. So this is server wide? I cannot control it on a spell by spell basis?
Reply With Quote
  #4  
Old 09-22-2019, 03:54 PM
chrsschb's Avatar
chrsschb
Dragon
 
Join Date: Nov 2008
Location: GA
Posts: 904
Default

Quote:
Originally Posted by strugglegenerator View Post
Thank you. So this is server wide? I cannot control it on a spell by spell basis?
Correct. The level restrictions are in the source and based on what live uses.

Lines 573-581 in spells.cpp
Code:
if (RuleB(Spells, BuffLevelRestrictions)) {
		// casting_spell_targetid is guaranteed to be what we went, check for ST_Self for now should work though
		if (spell_target && spells[spell_id].targettype != ST_Self && !spell_target->CheckSpellLevelRestriction(spell_id)) {
			LogSpells("Spell [{}] failed: recipient did not meet the level restrictions", spell_id);
			if (!IsBardSong(spell_id))
				MessageString(Chat::SpellFailure, SPELL_TOO_POWERFUL);
			return false;
		}
	}
And lines 3110-3139 in spells.cpp
Code:
// Check Spell Level Restrictions
// returns true if they meet the restrictions, false otherwise
// derived from http://samanna.net/eq.general/buffs.shtml
// spells 1-50: no restrictons
// 51-65: SpellLevel/2+15
// 66+ Group Spells 62, Single Target 61
bool Mob::CheckSpellLevelRestriction(uint16 spell_id)
{
	return true;
}

bool Client::CheckSpellLevelRestriction(uint16 spell_id)
{
	int SpellLevel = GetMinLevel(spell_id);

	// Only check for beneficial buffs
	if (IsBuffSpell(spell_id) && IsBeneficialSpell(spell_id)) {
		if (SpellLevel > 65) {
			if (IsGroupSpell(spell_id) && GetLevel() < 62)
				return false;
			else if (GetLevel() < 61)
				return false;
		} else if (SpellLevel > 50) { // 51-65
			if (GetLevel() < (SpellLevel / 2 + 15))
				return false;
		}
	}

	return true;
}}
__________________
Clumsy's World: Resurgence [2019-Present]
Clumsy's World 2.0 [2014-2016]
Clumsy's World [2006-2012]
Reply With Quote
  #5  
Old 09-22-2019, 05:57 PM
strugglegenerator's Avatar
strugglegenerator
Hill Giant
 
Join Date: May 2012
Location: Minnesota
Posts: 231
Default

Wow thank you for the detailed information.

I am so intimidated by code and I really want to be able to mess with things like that, but I am not confident in my ability to even get a custom server up and running from scratch, which is why I used the Akka repak.

I appreciate the info!
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:32 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