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 07-18-2016, 12:47 PM
Maceblade
Hill Giant
 
Join Date: Jun 2010
Posts: 231
Default item cast help

So basically I created an item where once clicked, it gives you an AA and poofs. Only problem is, item poofs just fine but grants no reward...

Code:
sub EVENT_ITEM_CLICK {
	if($itemid == 1813){


	quest::emote("You have Gained an AA!!");	
		$client->AddAAPoints(1);} 
}
Reply With Quote
  #2  
Old 07-18-2016, 02:19 PM
ghanja's Avatar
ghanja
Dragon
 
Join Date: Aug 2012
Location: Hershey, PA
Posts: 499
Default

What type of item? Food/drink? (Sounds like it may be, since there is nothing in your code nuking an item). Is the code you submitted the complete code? What is the scripts filename (is it in your /quests/global/items/ ?) Scriptfileid for the item match that of the script filename?

Last edited by ghanja; 07-18-2016 at 11:00 PM.. Reason: Nice catch c0ncrete
Reply With Quote
  #3  
Old 07-18-2016, 07:12 PM
Maceblade
Hill Giant
 
Join Date: Jun 2010
Posts: 231
Default

sorry, I copied the Halloween illusion script file and just altered it "script_13674.pl", also copied the halloween illusion item and just renamed it. The file name is script_8818.pl, the item number is 1813... I also created a "script_1813.pl" to see if that would work.

When I looked at the Halloween item, it did not look for a book or have any distinguishing remarks associated with its script path... im gonna check the food/drink thing now.
Reply With Quote
  #4  
Old 07-18-2016, 08:01 PM
ghanja's Avatar
ghanja
Dragon
 
Join Date: Aug 2012
Location: Hershey, PA
Posts: 499
Default

Quote:
Originally Posted by Maceblade View Post
sorry, I copied the Halloween illusion script file and just altered it "script_13674.pl", also copied the halloween illusion item and just renamed it. The file name is script_8818.pl, the item number is 1813... I also created a "script_1813.pl" to see if that would work.

When I looked at the Halloween item, it did not look for a book or have any distinguishing remarks associated with its script path... im gonna check the food/drink thing now.

Well no, don't jump the gun, those were just questions, not rhetoric.

You said:
Quote:
Only problem is, item poofs just fine but grants no reward
script_13674.pl is for the gauntlets/hammer of infusion, which has a NukeItem, and its an EVENT_ITEM_CLICK_CAST, rather than EVENT_ITEM_CLICK

So, I was curious, if the code you supplied, was the entire code you were using. And if the item you were basing the click event off of was a consumable (as I didnt see anything in the script to make a non-consumable "poof")
Reply With Quote
  #5  
Old 07-18-2016, 09:38 PM
c0ncrete's Avatar
c0ncrete
Dragon
 
Join Date: Dec 2009
Posts: 719
Default

are there other scripted items that work from that folder? i ask because i'm finding item scripts in /quests/global/items in a current install.
__________________
I muck about @ The Forge.
say(rand 99>49?'try '.('0x'.join '',map{unpack 'H*',chr rand 256}1..2):'incoherent nonsense')while our $Noport=1;
Reply With Quote
  #6  
Old 07-18-2016, 11:00 PM
ghanja's Avatar
ghanja
Dragon
 
Join Date: Aug 2012
Location: Hershey, PA
Posts: 499
Default

Quote:
Originally Posted by c0ncrete View Post
are there other scripted items that work from that folder? i ask because i'm finding item scripts in /quests/global/items in a current install.
Yeah it's /quests/global/spells and /quests/global/items, I misspoke, though awaiting answers to other questions in hope to help out.
Reply With Quote
  #7  
Old 07-19-2016, 10:57 AM
kimura
Hill Giant
 
Join Date: Oct 2011
Posts: 132
Default

make sure the item has the script file ID assigned to it

here is an example of one of mine

Code:
sub EVENT_ITEM_CLICK {
my $named = $client->GetName();
    if($itemid == 132496 && $ulevel == 1) {
        $client->NukeItem(132496);
		$client->Message(327, "You have been boosted!");
		quest::we(327, "$named has been boosted!!");
		quest::level(70);
		$client->Message(327, "Bam! Level 70!");
        $client->SetAAPoints(1000);
		$client->Message(327, "You now have 1000 AA points!");
         
    } else {
        $client->Message(315, "Nice try, you're too powerful to use this");
    }
}
the script is script_7150.pl, so the item 132496 has to have the scriptfileid column in the items table = 7150

hope this helps
Reply With Quote
  #8  
Old 07-24-2016, 09:40 AM
Maceblade
Hill Giant
 
Join Date: Jun 2010
Posts: 231
Default

Thanks Kim, I didn't realize the scriptidfile was a column until I looked at it through an old edit version. Thanks Man works flawless.
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 02:36 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