View Single Post
  #2  
Old 01-10-2018, 04:47 AM
The_Beast's Avatar
The_Beast
Discordant
 
Join Date: May 2016
Location: Under a rock
Posts: 290
Default

If you want to add a click effect to an item, create a script in quests/global/items folder. Whatever name you give the script,
that name has to go into the scriptfileid in the items table, for that item. Is this kind of along the lines of your goals ?
EXAMPLE: (This is from an actual halloween script called script_30068.pl)
Code:
sub EVENT_ITEM_CLICK {
	if($itemid == 54706){
		quest::playerrace(340);
		quest::playergender(1);
	} 
}
The item ID in the items table is 54706. The scriptfileid is 30068
Reply With Quote