Thread: Dragon Slayer Quest (Nice)

Page 1 of 2 12 LastLast
Results 1 to 10 of 12
  1. #1 Dragon Slayer Quest (Nice) 
    Banned

    Join Date
    Jan 2007
    Posts
    260
    Thanks given
    3
    Thanks received
    5
    Rep Power
    0
    What this does is add's a Quest Handler, I take no credit for the Handler.

    NOTE: Obviously there doesn't HAVE to be a handler, but it sure helps out alot, and it keeps alot of stuff out of the process boolean.

    So, Here is a link to implement the Handler: [Only registered and activated users can see links. ]

    Now, once that's implemented you can create Quest's very easily, which is very nice.

    So here is a quest made by me.

    It is a pretty decent version of Dragon Slayer:

    Purpose: Add Dragon Slayer.

    Serve Base: Deltascape, but it will work on any source.

    Add this code in your Questhandler:

    Code:
    public static void dragonSlayer(client c) {
            if (c.qStage[3] == 1) {
                c.qStage[3] = 2;
                npcDiag(c, "Guild Master","So "+c.playerName+", you think you are a brave warrior?","Then boy do I have a challenge for you!","If you think you can handle the challenge,","then find Oziach, in level 1 Edgeville Wild.",198);
        }else if (c.qStage[3] == 0) {
                    npcDiag(c, "Guild Master","I see that you have finished my task!","I feel that I should give you some type of reward.","Ah, I have an idea! I will let you have access to the Champions Guild!","Talk to me whenever you want to go there!",198);
                    c.toX = 2896;
                    c.toY = 3511;
                    c.savegame(true);
        }
    }
    
        public static void dragonSlayer2(client c) {
            long now = System.currentTimeMillis();
            if (c.qStage[3] == 2) {
                c.qStage[3] = 3;
                npcDiag(c, "Oziach","So "+c.playerName+", you still think you are a brave warrior?","If you are up to it, use this key on on the one of the","doors in the Fortress of level 15 Edgeville wilderness","I need you to find a piece of a map for me.",747);
                c.addItem(1543,1); //Gives 2 keys incase one is lost
                c.savegame(true);
        }else if (c.qStage[3] == 3) {
                if (c.HasItemAmount(4274,1)) {
                    c.qStage[3] = 4;
                    npcDiag(c, "Oziach","Good job brave warrior. I'll take","that piece of map from you, now you only have 2 more","pieces of map to find. The next piece","can be found by killing a demon near some Iron Dragons",747);
                    c.deleteItem(4274,1);
                    c.savegame(true);
                }else if (!c.HasItemAmount(1543,1)) {
                    npcDiag(c, "Oziach",""+c.playerName+", get on your way, I need ","that map piece as soon","as possible! Here is an extra key,","because I noticed you are missing yours.",747);
                    c.addItem(1543,1);
            }
        }else if (c.qStage[3] == 4) {
                if (c.HasItemAmount(4275,1)) {
                    c.qStage[3] = 5;
                    npcDiag(c, "Oziach","Good job brave warrior. I'll take","that piece of map from you, now you only have 1 more","piece of map to find. The next piece","can be found by killing the KBD, found east of the Iron Dragons.",747);
                    c.deleteItem(4275,1);
                    c.savegame(true);
                }else{
                    npcDiag(c, "Oziach",""+c.playerName+", get on your way, I need ","that map piece as soon","as possible!","",747);
            }
        }else if (c.qStage[3] == 5) {
                if (c.HasItemAmount(4276,1)) {
                    c.qStage[3] = 6;
                    npcDiag(c, "Oziach","Good job brave warrior. I'll take","that piece of map from you, now we have","the entire map!","Now talk to Ned the Fisherman, found in Draynor!",747);
                    c.deleteItem(4276,1);
                    c.addItem(4277,1);
                    c.savegame(true);
                }else{
                    npcDiag(c, "Oziach",""+c.playerName+", get on your way, I need ","that map piece as soon","as possible!","",747);
                }
        }else if (c.qStage[3] == 6) {
                if (c.HasItemAmount(3709,1)) {
                    c.qStage[3] = 7;
                    npcDiag(c, "Oziach","You truely are amazing "+c.playerName+"!","I congratulate you on a task well done! Take these items","as a reward for accomplishing that which I thought was impossible!","Talk to me again for the rest of your reward!",747);
                    c.deleteItem(3709,10);
                    c.addItem(3140,1);
                    c.savegame(true);
                }else{
                    npcDiag(c, "Oziach",""+c.playerName+", get on your way, The beastly","dragon needs to be slain","as soon as possible!","",747);
                }
        }else if (c.qStage[3] == 7) {
                    if (c.HasItemAmount(3140,1)) {
                    c.addItem(1048,1); //Give 1 White Phat
                    c.addItem(995,5000000); //Give 5 Million Gold
                    c.addSkillXP(50000, c.playerStrength); //Give 50,000 Magic Expierence
                    c.qStage[3] = 0;
                    rewardMenu(c, 1,"The rare white Party hat!","5 Million gold pieces","250,000 Strength Experience","");
                    c.savegame(true);
                }else{
                    npcDiag(c, "Oziach",""+c.playerName+", I wish you luck on all of","your future tasks may God be with","throughout your time here on Runeore!","",747);
                }
        }else if (c.qStage[3] == 0) {
                    npcDiag(c, "Oziach",""+c.playerName+", I wish you luck on all of","your future tasks may God be with","throughout your time here on Runeore!","",747);    
            }
        }
    
            public static void dragonSlayer3(client c) {
            if (c.qStage[3] == 6) {
                if (c.HasItemAmount(995,10000) && (c.HasItemAmount(4277,1))) {
                    c.deleteItem(995,10000);
                    npcDiag(c, "Ned The Fisherman","So "+c.playerName+", you need a ride to Crandor?","That will cost you 10,000 gold!","Now then, let me see that map","so we can get on our way!",308);
                    c.toX = 2851;
                    c.toY = 3238;
                    c.sM("You arrive on Crandor, but your boat has crashed into the shore!");
                }else{
                    npcDiag(c, "Ned The Fisherman",""+c.playerName+", seem's to me that either you can't ","afford the ride to Crandor or you have forgotten your map.","Please bring back 10,000 Gold and your map to get a ride.","",308);
            }
        }
    }

    Obviously you can change the
    Code:
    c.qStage[3]
    to whatever quest # it is for you.

    Now to implement the NPC talking we need to open up client.java and search for Case 155: First click NPC.

    Then add the following code:
    Code:
    if (NPCID == 198) { // Guild Master
        server.qHandler.dragonSlayer(this);
    }
    if (NPCID == 747) { // Oziach
        server.qHandler.dragonSlayer2(this);
    }
    if (NPCID == 308) { // Fisherman
        server.qHandler.dragonSlayer3(this);
    }
    So now your NPC's talk when clicked etc, etc. You get the point.

    We also need all the correct objects and what not to work, so open up client.java and add the following code underneath of
    Code:
    case 192
    Code:
    /*Dragon Slayer*/
    if(UsedOnObjectID == 14749 && ItemID == 3458){ //
    toX = 3033;
    toY = 3632;
    sM("You are teleported to the other side of the door!");
    }
    if(UsedOnObjectID == 14749 && ItemID == 3457){ //
    toX = 3035;
    toY = 3627;
    sM("You are teleported to the other side of the door!");
    }
    if(UsedOnObjectID == 14749 && ItemID == 3456){ //
    toX = 3034;
    toY = 3626;
    sM("You are teleported to the other side of the door!");
    }
    if(UsedOnObjectID == 14749 && ItemID == 3455){ //
    toX = 3023;
    toY = 3627;
    sM("You are teleported to the other side of the door!");
    }
    if(UsedOnObjectID == 14749 && ItemID == 3459){ //
    toX = 3025;
    toY = 3626;
    sM("You are teleported to the other side of the door!");
    }
    /*End Dragon Slayer*/
    Add these to your Autospawn CFG.

    Code:
    //DRAGON SLAYER QUEST
    spawn = 198		2729	3473	0	2729	3473	2729	3473	1	//Dragon Slayer Quest Start
    spawn = 747		3074	3517	0	3074	3517	3074	3517	1	//2nd Part of Dragon Slayer Oziach
    spawn = 941		2840	9608	0	2840	9608	2840	9608	1	//Dragon
    spawn = 308		2124	4913	0	2124	4913	2124	4913	1	//Fisherman to Crandor
    spawn = 78		3023	3630	0	3023	3630	3023	3630	1	//Flying Bat
    spawn = 78		3023	3632	0	3023	3632	3023	3632	1	//Flying Bat
    spawn = 86		3023	3630	0	3023	3630	3023	3630	1	//Giant Rat
    spawn = 86		3023	3626	0	3023	3626	3023	3626	1	//Giant Rat
    spawn = 103		3027	3626	0	3027	3626	3027	3626	1	//Ghost
    spawn = 103		3029	3626	0	3029	3626	3029	3626	1	//Ghost
    spawn = 90		3035	3625	0	3035	3625	3035	3625	1	//Skeleton
    spawn = 90		3035	3624	0	3035	3624	3035	3624	1	//Skeleton
    spawn = 73		3035	3630	0	3035	3630	3035	3630	1	//Zombie
    spawn = 73		3035	3632	0	3035	3632	3035	3632	1	//Zombie
    spawn = 753		3029	3632	0	3029	3632	3029	3632	1	//Melzar the Mad
    spawn = 83		2699	3709	0	2699	3709	2699	3709	1	//Greater Demon
    To finish the quest off just add the following drops to your npcdrops.CFG file.

    Code:
    //DRAGON SLAYER
    npcdrop = 941	3709	1	100	//Dragon Slayer Final Stage
    npcdrop = 86	3459	1	100
    npcdrop = 103	3456	1	50
    npcdrop = 90	3457	1	50
    npcdrop = 73	3458	1	50
    npcdrop = 78	3454	1	50
    npcdrop = 753	4274	1	100
    npcdrop = 83	4275	1	100	//Demon 1/3 Page
    npcdrop = 50	4276	1	100	//KBD 1/3 Page
    //END DRAGON SLAYER
    There ya go, that is FULL Dragon slayer, almost the same as Runescape's.

    Credits:
    tj007razor *** for making the handler
    newty (me) %70 for grinding out that longass code leep:

    This is based on a deltascape source, but because of the handler it can be easily modified to any source with hardly any work.
    Reply With Quote  
     

  2. #2  
    Donator

    tj007razor's Avatar
    Join Date
    Feb 2007
    Posts
    895
    Thanks given
    2
    Thanks received
    9
    Rep Power
    210
    Glad to see someone finally make something good from it. Most people have no idea how to go about using it so nice job.

    repped.
    Last edited by tj007razor; 03-01-2009 at 06:35 PM. Reason: grammar fail >_>

    [Only registered and activated users can see links. ]

    [Only registered and activated users can see links. ] | [Only registered and activated users can see links. ] | [Only registered and activated users can see links. ]
    Reply With Quote  
     

  3. #3  
    Banned

    Join Date
    Jan 2007
    Posts
    260
    Thanks given
    3
    Thanks received
    5
    Rep Power
    0
    Quote Originally Posted by tj007razor View Post
    Glad to see someone finally make something good use of it. Most people have no idea how to go about using it so nice job.

    repped.
    Yeah, I've been using it for a few weeks now. It is a perfect Quest base, seriously great job on it.

    I've made like 4 or 5 quests with it
    Reply With Quote  
     

  4. #4  
    Sate
    Guest
    No offense but why would you add quests on a p server? I can't believe anyone would really like to do quests on a p server lol.. I can see some certain tasks but not quest..
    Reply With Quote  
     

  5. #5  
    Registered Member
    Core's Avatar
    Join Date
    Sep 2007
    Posts
    4,194
    Thanks given
    11
    Thanks received
    393
    Rep Power
    1985
    Wth, all of the best p servers have quests.
    Reply With Quote  
     

  6. #6  
    Sate
    Guest
    Quote Originally Posted by Core View Post
    Wth, all of the best p servers have quests.
    Mine doesn't... Not quest just like RS.. I mean make up your own quests. Be unique
    Reply With Quote  
     

  7. #7  
    Registered Member
    Core's Avatar
    Join Date
    Sep 2007
    Posts
    4,194
    Thanks given
    11
    Thanks received
    393
    Rep Power
    1985
    Quote Originally Posted by Satesql View Post
    Mine doesn't... Not quest just like RS.. I mean make up your own quests. Be unique
    And what is your famous project.
    Reply With Quote  
     

  8. #8  
    Warmly
    Guest
    Great quest, I will be sure to use this!
    Reply With Quote  
     

  9. #9  
    Ivo
    Ivo is offline
    Coding coding coding...

    Ivo's Avatar
    Join Date
    Mar 2008
    Age
    30
    Posts
    1,426
    Thanks given
    30
    Thanks received
    147
    Rep Power
    2017
    Very basic, maybe too basic... sometimes if im bored im coding stuff like that, but that gave me good idea to make all perfect f2p quests. thanks for idea, and gl in future...

    [Only registered and activated users can see links. ]
    Reply With Quote  
     

  10. #10  
    Banned

    Join Date
    Jan 2007
    Posts
    260
    Thanks given
    3
    Thanks received
    5
    Rep Power
    0
    Thanks for the feedback guys
    Reply With Quote  
     

Page 1 of 2 12 LastLast

Thread Information
Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)


User Tag List

Posting Permissions
  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •