Go Back   EQEmulator Home > EQEmulator Forums > Quests > Quests::Q&A

Quests::Q&A This is the quest support section

Reply
 
Thread Tools Display Modes
  #1  
Old 10-11-2013, 09:09 AM
NatedogEZ's Avatar
NatedogEZ
Developer
 
Join Date: Dec 2012
Posts: 515
Default

Quote:
Originally Posted by trevius View Post
I am not sure what you mean by the slot restrictions or by it only being useable by 1 item.
Create a script called... "Script_1.pl" ...

Now add it to a Helm / Chest / Bracer / ect / ect...

Add a debug line of some sort like so...

Code:
$DEBUG = 1;

sub EVENT_ITEM_CLICK {
	
	if($DEBUG == 1) { 	$client->Message(335, "CLICKED item!"); }

}
It seems I could get 2 of the same EXACT bracer to both work on the same script... but if it was a Bracer and a Helm the script would not work for both.. only worked for one... hmm


I was testing the Charmfile on 2 of the same weapns as well which is why I thought it worked for Charmfile... when I used 2 different weapons.. only of the of scripts would work and the other did not. (when using the same charmfile on both)
Reply With Quote
  #2  
Old 10-11-2013, 08:08 PM
KLS
Administrator
 
Join Date: Sep 2006
Posts: 1,348
Default

The way item scripts have changed a bit in the past few months Trev, it no longer really works like that and any item event can be triggered by any script.

This is from the Lua documentation but it should work the same for Perl with pl instead of lua extension:

Code:
Item Scripts are quest scripts attached to Items. Items will load a script on the first event that triggers them and will load one and only one from the following location. Which ever it finds first in the following order:

./quests/zone/items/item_script.lua
./quests/global/items/item_script.lua
./quests/zone/items/default.lua
./quests/global/items/default.lua
The format of the item_script is as follows:

If ScriptFileID != 0
	item_script = "script_" + ScriptFileID
Else If CharmFile != ""
	item_script = CharmFile
Else
	item_script = item_id
Items will only load one script but all events will get pushed to that based on that precedence order. If it doesn't work like this for both Lua and Perl then there's a bug that needs to be fixed.

Though I suspect you may be tripping over the precedence + item_script format unintentionally.
Reply With Quote
Reply

Thread Tools
Display Modes

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 05:04 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