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-20-2008, 04:39 PM
ChaosSlayer
Demi-God
 
Join Date: May 2007
Posts: 1,032
Default Question on npc spell casting lists in DB?

I am looking over npc spell lists and trying to figure few thigns out:

what makes a diffirence bewten npc castign a spell by choice vs having it as random mana free proc?

whats recast deay -1?
whats mana cost -1?
mana cost -2?

i see another list which has "attack_proc" and "proc_chance"
but not sure how they apply to ENTIRE list of spells of a given npc?

attack_proc values do not make any sence at all

thanks =)
Reply With Quote
  #2  
Old 09-20-2008, 05:24 PM
Congdar
Developer
 
Join Date: Jul 2007
Location: my own little world
Posts: 751
Default

mana cost -1 means get the correct mana cost from the spell file, probably means the same for recast delay
mana cost -2 means no mana cost for this spell and it also means that cast time is 0 instant

attack_proc is the spell id of the proc -1 means no proc
proc_chance is the % chance the proc will trigger on a hit

An npc spell entry in the database consists of an id in the table npc_spells which has the above two entries and the actual spell in the table npc_spells_entries. It has an id and then the npc_spells_entry that points back to the entry in the npc_spells table. The spell entry then has the spell id the type of spell it is (detailed below) and the level range the spell is usable. The mana cost and recast delay I covered above, and there's the priority field for the npc ai to use as to which spell is more important to cast with 0 being higher piority than 1.

Spell Types are:
Nuke=1;
Heal=2;
Root=4;
Buff=8;
Escape=16;
Pet=32;
Lifetap=64;
Snare=128;
DOT=256;
Dispel=512;
Reply With Quote
  #3  
Old 09-20-2008, 05:32 PM
Congdar
Developer
 
Join Date: Jul 2007
Location: my own little world
Posts: 751
Default

Additionally, the npc has the npc_spells id in its npc_spells_id entry in the npc_types table which when the npc spawns it will load that entry and the appropriate spells for the npc's level from the spell id entries in npc_spells_entries.

The npc will have those spells, plus the possible proc spell plus any possible other parent list of spells available to it to load at spawn time up to 16 total spells max.
Reply With Quote
  #4  
Old 09-20-2008, 06:07 PM
ChaosSlayer
Demi-God
 
Join Date: May 2007
Posts: 1,032
Default

thank you for answering.

few more questions:

from what I understand an npc only has ONE spell it can proc as random?

I am looking at for exmaple at list 44 (Snake and Spider). it has
attack_proc 1001 (i presume its number of spell) and proc_chance 3

so it can proc spell 1001 at 3% chance?

BUt it also has: a spell list which has spell 765 Inject Poison with manacost -2 and recast_delay -1

so.. still confused.. it can proc 1001 at 3% chance but it can also chain cast 765 at no mana cost?

also- coudl you giuve more details how/from where parent list is coming from?

thanks
Reply With Quote
  #5  
Old 09-20-2008, 06:40 PM
Congdar
Developer
 
Join Date: Jul 2007
Location: my own little world
Posts: 751
Default

spell 1001 from spells_us.txt is weak poison and they can proc weak poison with 3% chance per hit and also cast 765 Injected Poison I as often as the ai allows.

This appears to be usded primarily for the strathbone spiders in kaesora as they are the only caster class that has this spell. It appears several other spiders and snakes have this as thier spell entry but are marked as warriors and would not see the spell casting code.

The parent list points to the same npc_spells entries. If you change the parent_list to point to 2 'Default Wizard List' then the spiders would also get the entire list from npc_spells_id 2 in npc_spells_entries.
Reply With Quote
  #6  
Old 09-20-2008, 06:52 PM
So_1337
Dragon
 
Join Date: May 2006
Location: Cincinnati, OH
Posts: 689
Default

I believe that even being warriors, so long as they have the spell list assigned to them, they should be able to proc.
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 07:59 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