Go Back   EQEmulator Home > EQEmulator Forums > Quests > Quests::Custom

Quests::Custom Custom Quests here

Reply
 
Thread Tools Display Modes
  #1  
Old 06-18-2021, 06:04 PM
NatedogEZ's Avatar
NatedogEZ
Developer
 
Join Date: Dec 2012
Posts: 515
Default Some useful scripts for Devs out there.

Test script for basic soulbinding that removes the cost and items directly from the player so you can make extremely complex turnins or very simple turnins. Players will no longer have to hand items to NPCS so all NPCs can just return items!

Code:
plugin::collect_quest($client, 1001 => 5, 1002 => 2, "platinum" => 1, "gold" => 5, "silver" => 5, "copper" => 5); #can have a 20 item turn in if you wish
plugin::DiaWind2(); #Added button responses look at original diawind for other options
plugin::summon_into_inventory($client, 1001, 10); #Example summon 10 items of ID 1001 directly into the players inventory
Code:
sub EVENT_SAY {
	if ($text=~/hail/i) {
		plugin::DiaWind2("Would you like to donate one {orange}Stone of Binding~ and {orange}10 platinum~ to have your soul bound to this area? popupid:69 popupid:70 wintype:1", "Donate", "No thanks");
	}
}

sub EVENT_POPUPRESPONSE {
	if ($popupid == 69) {
		if (plugin::collect_quest($client, 1001 => 1, "platinum" => 10)) { #Takes 1 item and 10 platinum directly from player no turn in required
			plugin::DiaWind("Thank you for the donation! Have some fresh water!");
			$client->SetBindPoint($zoneid, 0, -49, 513, 2); $client->Message(15, "You are now bound to this plane.");
			plugin::summon_into_inventory($client,1028,20); #20 waters.. (custom item)
		} else {
			#Failed turnin missing items or money
			plugin::DiaWind2("You seem to be missing the requirements for me to cast this spell.");
		}
	} elsif($popupid == 70) {
		plugin::DiaWind("Farewell, maybe next time sir!");
	}
}


sub EVENT_ITEM {
	plugin::return_items(\%itemcount);
}


If you are looking for more examples I can post more later on how its used, or just message me on the EQEMU discord.



Required plugins for this to work.. is a modified DiaWind... just added DiaWind2 to make it have multiple options for popupid.

Summon Into Inventory
https://pastebin.com/VRun4NX1

Collect Quest
https://pastebin.com/jLyLkTtg

DiaWind2

Last edited by NatedogEZ; 10-12-2021 at 03:32 PM..
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 11:59 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