Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // QUest Engine 0.01 example script by VUlt-r
- // script shows how to initialize and begin the quest
- Main
- {
- questname "Rare Berries"
- version 1
- }
- state Begin
- {
- desc "Talk to old farmer Greg."
- action AddNpcText( 38 , "Its hard find young motivated people for picking berries." );
- action AddNpcText( 38 , "Are you maybe interested in a job?" );
- action AddNpcInput( 38 , 1 , "No thanks");
- action AddNpcInput( 38 , 2 , "Yes i take the job!");
- action AddNpcInput( 38 , 3 , "Where do i find berries?");
- rule InputNpc( 1 ) goto Reset
- rule InputNpc( 2 ) goto Begin2
- rule InputNpc( 3 ) goto Begin3
- }
- state Begin2
- {
- desc "Collect 10 rare berries"
- action ShowHint("Quest reward : 1500 EXP and 500 gold (REP)")
- action AddNpcText( 38 , "I pay 500 gold for 20 rare berries.");
- action AddNpcText( 38 , "Working in the fields will ofcourse give you a lot experience as well!");
- action AddNpcInput( 38 , 1 , "I give up");
- action AddNpcInput( 38 , 2 , "Im working on it!");
- rule InputNpc( 1 ) goto Reset
- rule GotItems( 486 , 20 ) goto Talk2
- }
- state Begin3
- {
- desc "Talk to old farmer Greg."
- action AddNpcText( 38 , "The berries are growing in the patches of farmlands around me. There are 5 in total.");
- action AddNpcText( 38 , "I think that the plants spawn berries randomly but they don't always spawn them.");
- action AddNpcText( 38 , "Sometimes they spawn useless leaves, sadly i cannot pay you for that.");
- action AddNpcText( 38 , "You should remove the useless leaves, it prevents berries from growing.");
- rule TalkedToNpc( 38 ) goto Begin2 // requires to talk
- }
- state Talk2
- {
- desc "Talk to the farmer Greg."
- action ShowHint("You succesfully collected 10 rare berries")
- action AddNpcChat( 38 , "Great job!" );
- action AddNpcText( 38 , "10 excellent berries! Thanks for your business." );
- rule TalkedToNpc( 38 ) goto GetReward // requires to talk
- rule LostItems( 486 , 20 ) goto Begin2
- }
- state GetReward
- {
- action ShowHint("You gained 1500 EXP and 500 gold (REP)");
- action PlaySound(17);
- action RemoveItem( 486 , 20 )
- action GiveItem( 1 , 500)
- action GiveExp(1500)
- action End()
- }
- state Reset
- {
- action ShowHint("Rare Berries quest aborted..")
- action Reset() // reset and abort quest
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement