Morague Beginner
Joined: 16 Dec 2000 Posts: 27
|
Posted: Sun Apr 01, 2001 2:36 am
Eq ID for Avatar MUD part1 |
Many thanks to Kjata for sharing his Eq script - it helped me immesnley in setting this one up.
You need to define your Database fields before you can use the Eq script - you'll need the following fields:Name, Type, Level, Weight, Value, HR, DR, AC, Base, High, Average, Low, HP, Mana, Moves, Str, Int, Wis, Con, Dex, SaveVersus, SpellLevel, Spell1, Spell, Spell3,Charges, Extra, Alignment & Comment.
Most of the Fields are self explanitory - but type needs Armor, Weapon, Pill, Potion, Scroll, Staff, Light, Container, Wand, Key, Treasure, Furniture, Trash, Ticket, Poison, Rogue Tools & Boat. You need to set up a view for each Type.
Duplicate items are not entered. You need to manually add an entry to each view before it will accept the auto entries. I just added weapon, armor, etc & then deleted these after I had other records in that view in the database.
Here's the script:
#ALIAS id {#T+ identify;#VARIABLE Item "";#VARIABLE ItemSpell "";#VARIABLE hr 0;#VARIABLE dr 0;#VARIABLE con 0;#VARIABLE wis 0;#VARIABLE int 0;#VARIABLE dex 0;#VARIABLE str 0;#VARIABLE svs 0;#VARIABLE ac 0;#VARIABLE hpdb 0;#VARIABLE manadb 0;#VARIABLE movedb 0;#VARIABLE type "";#VARIABLE Namedb "";c identify %1} "General"
#TRIGGER {^You can't concentrate enough.} {#T- Identify} "identify"
#TRIGGER {^You are not carrying} {#T- Identify} "identify"
#TRIGGER {^This room blocks your mind from spellcasting!} {#T- Identify} "identify"
#TRIGGER {^You can't do that in your sleep.} {#T- Identify} "identify"
#TRIGGER {^Object '&{Namedb}' type &{type}, extra flags (*).$} {#ADDKEY Item {Extra=%trim( %replace("%3", "charity", ""))}} "identify"
#TRIGGER {^Weight &%d{Item.Weight}, value &%d{Item.Value}, level &%d{Item.Level}.$} {} "identify"
#TRIGGER {^Armor class is &%d{Item.Base}.$} {} "identify"
#TRIGGER {^Damage is &%d{Item.Low} to &%d{Item.High} ~(average &%d{Item.Average}~).$} {} "identify"
#TRIGGER {^%d charges of: '&{Item.Spell1}'.$} {} "identify"
#TRIGGER {^%d charges of: '&{Item.Spell1}' '&{Item.Spell2}'.$} {} "identify"
#TRIGGER {^%d charges of: '&{Item.Spell1}' '&{Item.Spell2}' '&{Item.Spell3}'.$} {} "identify"
#TRIGGER {^Level (%d) spells of: '&{Item.Spell1}'.$} {#ADDKEY Item {Spell Level=%1}} "identify"
#TRIGGER {^Level (%d) spells of: '&{Item.Spell1}' '&{Item.Spell2}'.$} {#ADDKEY Item {Spell Level=%1|Spell1="%2"|Spell2="%3"}} "identify"
#TRIGGER {^Level (%d) spells of: '&{Item.Spell1}' '&{Item.Spell2}' '&{Item.Spell3}'.$} {#ADDKEY Item {Spell Level=%1|Spell1="%2"|Spell2="%3"|Spell3="%4"}} "identify"
#TRIGGER {^Has (%d)~(%d~) charges at level (%d) '&{Item.Spell1}'.$} {#ADDKEY Item {Charges=%1};#ADDKEY Item {SpellLevel=%2}} "identify"
#TRIGGER {Modifies hit roll by &{hrp} continuous.$} {#MATH HR @hr+@hrp} "identify"
#TRIGGER {Modifies damage roll by &{drp} continuous.$} {#MATH DR @dr+@drp} "identify"
#TRIGGER {Modifies intelligence by &{intp} continuous.$} {#MATH int @int+@intp} "identify"
#TRIGGER {Modifies strength by &{strp} continuous.$} {#MATH str @str+@strp} "identify"
#TRIGGER {Modifies wisdom by &{wisp} continuous.$} {#MATH wis @wis+@wisp} "identify" |
|