Thread: [PI] NPC dialogue help

Page 1 of 2 12 LastLast
Results 1 to 10 of 15
  1. #1 [PI] NPC dialogue help 
    Registered Member
    Join Date
    Jul 2011
    Posts
    537
    Thanks given
    25
    Thanks received
    35
    Rep Power
    0
    So i saw a thread about a guy wanting it so when you Talk to an NPC a dialogue comes up saying "master" or "pure" and when you click one of them you get the levels for that option.

    I tried doing this but when i click the NPC nothing happens, here's my code:

    dialoguehandler.java
    Code:
    case 640:
    sendOptions2("pure", "master");
    dialogueAction = 13;
    break;
    clickingbuttons.java
    Code:
    } else if (c.dialogueAction == 13) {
    c.getPA().addSkillXP(13500000,6);
    c.sendMessage("You are now a Main.");
    c.getPA().addSkillXP(13500000,4);
    c.sendMessage("You are now a Pure.");

    Help?
    I support Eliminate.


    [Today 06:28 PM] Scu11: Mans gotta spread his wings, to do his tings
    Reply With Quote  
     

  2. #2  
    Registered Member Pakku's Avatar
    Join Date
    Mar 2010
    Posts
    1,234
    Thanks given
    127
    Thanks received
    111
    Rep Power
    47
    You need to put something in ActionHandler
    Code:
    case NPCID:
    Do whatever here
    break;


    Reply With Quote  
     

  3. #3  
    Donator

    Arithium's Avatar
    Join Date
    May 2010
    Age
    31
    Posts
    4,721
    Thanks given
    199
    Thanks received
    1,256
    Rep Power
    1114
    what pakku said. you need to do

    case npcid: <-- watever the id
    c.getDH().sendDialogues(640, npcType);
    break;

    and in case 9157: in clickingbuttons.java

    Code:
    if (c.dialogueAction == 13) {
    c.getPA().addSkillXP(13500000,0);
    c.getPA().addSkillXP(13500000,1);
    c.getPA().addSkillXP(13500000,2);
    c.getPA().addSkillXP(13500000,3);
    c.getPA().addSkillXP(13500000,4);
    c.getPA().addSkillXP(13500000,5);
    c.getPA().addSkillXP(13500000,6);
    c.sendMessage("You are now a master.");
    }
    and in case 9158: in clickingbuttons.java add
    Code:
    if (c.dialogueAction == 13)  {
    c.getPA().addSkillXP(13500000,0);
    c.getPA().addSkillXP(13500000,2);
    c.getPA().addSkillXP(13500000,3);
    c.getPA().addSkillXP(13500000,4);
    c.getPA().addSkillXP(13500000,6);
    c.sendMessage("You are now a pure.");
    }
    Reply With Quote  
     

  4. #4  
    Registered Member
    Join Date
    Jul 2011
    Posts
    537
    Thanks given
    25
    Thanks received
    35
    Rep Power
    0
    Quote Originally Posted by Pakku View Post
    You need to put something in ActionHandler
    Code:
    case NPCID:
    Do whatever here
    break;
    Sorry but what would i put where it says "do whatever here"
    I support Eliminate.


    [Today 06:28 PM] Scu11: Mans gotta spread his wings, to do his tings
    Reply With Quote  
     

  5. #5  
    Donator

    Arithium's Avatar
    Join Date
    May 2010
    Age
    31
    Posts
    4,721
    Thanks given
    199
    Thanks received
    1,256
    Rep Power
    1114
    Quote Originally Posted by Sulfur View Post
    Sorry but what would i put where it says "do whatever here"
    firstclicknpc in actionhandler.java under the switch
    Reply With Quote  
     

  6. #6  
    Registered Member Pakku's Avatar
    Join Date
    Mar 2010
    Posts
    1,234
    Thanks given
    127
    Thanks received
    111
    Rep Power
    47
    Put what animeking1120 said.


    Reply With Quote  
     

  7. #7  
    Registered Member
    Join Date
    Jul 2011
    Posts
    537
    Thanks given
    25
    Thanks received
    35
    Rep Power
    0
    Ffs not working =/ i've followed that you guys have said but when i click him nothing happens..
    I support Eliminate.


    [Today 06:28 PM] Scu11: Mans gotta spread his wings, to do his tings
    Reply With Quote  
     

  8. #8  
    Donator

    Arithium's Avatar
    Join Date
    May 2010
    Age
    31
    Posts
    4,721
    Thanks given
    199
    Thanks received
    1,256
    Rep Power
    1114
    Quote Originally Posted by Sulfur View Post
    Ffs not working =/ i've followed that you guys have said but when i click him nothing happens..
    did u get the dialogue to show up at all?
    Reply With Quote  
     

  9. #9  
    Registered Member
    Join Date
    Jul 2011
    Posts
    537
    Thanks given
    25
    Thanks received
    35
    Rep Power
    0
    Quote Originally Posted by animeking1120 View Post
    did u get the dialogue to show up at all?
    Nope
    I support Eliminate.


    [Today 06:28 PM] Scu11: Mans gotta spread his wings, to do his tings
    Reply With Quote  
     

  10. #10  
    Registered Member
    Join Date
    Jul 2011
    Posts
    537
    Thanks given
    25
    Thanks received
    35
    Rep Power
    0
    Anyone could help? i think it might be ActionHandler.java since when i click the NPC the dialogue doesn't come up?
    I support Eliminate.


    [Today 06:28 PM] Scu11: Mans gotta spread his wings, to do his tings
    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

Similar Threads

  1. 508 Dialogue
    By Marayso in forum Help
    Replies: 2
    Last Post: 04-24-2011, 11:22 PM
  2. Replies: 17
    Last Post: 01-01-2010, 08:02 PM
  3. NPC Dialogue
    By Full Metalst in forum Tutorials
    Replies: 2
    Last Post: 01-18-2009, 06:53 AM
  4. Replies: 1
    Last Post: 03-05-2008, 12:47 AM
Posting Permissions
  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •