Thread: Interface Help

Page 1 of 2 12 LastLast
Results 1 to 10 of 11
  1. #1 Interface Help 
    Registered Member
    Join Date
    Mar 2013
    Posts
    191
    Thanks given
    13
    Thanks received
    12
    Rep Power
    26
    How can I make it so there is dialogue under the interface that I can use to switch pages.

    Reply With Quote  
     

  2. #2  
    Donator


    Join Date
    Jul 2014
    Posts
    509
    Thanks given
    90
    Thanks received
    87
    Rep Power
    503
    Write a dialogue and have whatever you use to open the interface also open the dialogue?
    Reply With Quote  
     

  3. #3  
    Registered Member
    Join Date
    Jul 2013
    Posts
    181
    Thanks given
    3
    Thanks received
    12
    Rep Power
    12
    Do exactly as Curry said....just make a new dialogue, have it open with whatever you're using to open the interface, whether it be command, NPC, object, and give the dialogue options to open another edition of that interface. So if you plan to have 2 of that same interface, you'll need to make 2 separate instances of it in InterfaceManager.java
    Reply With Quote  
     

  4. #4  
    Registered Member
    Join Date
    Mar 2013
    Posts
    191
    Thanks given
    13
    Thanks received
    12
    Rep Power
    26
    Quote Originally Posted by Curry View Post
    Write a dialogue and have whatever you use to open the interface also open the dialogue?
    I used this, but it didn't work.
    Code:
    	if (cmd[0].equals("bosslog")) {
    			player.getDialogueManager().startDialogue("BossLogInterface");
    			BossLog.sendBossLog(player);
    			return true;
    		}
    Reply With Quote  
     

  5. #5  
    Registered Member
    Join Date
    Jul 2013
    Posts
    181
    Thanks given
    3
    Thanks received
    12
    Rep Power
    12
    Quote Originally Posted by Nika View Post
    I used this, but it didn't work.
    Code:
    	if (cmd[0].equals("bosslog")) {
    			player.getDialogueManager().startDialogue("BossLogInterface");
    			BossLog.sendBossLog(player);
    			return true;
    		}
    Did you make the actual dialogue? Did you define it in DialogueHandler.java?
    Reply With Quote  
     

  6. #6  
    Donator


    Join Date
    Jul 2014
    Posts
    509
    Thanks given
    90
    Thanks received
    87
    Rep Power
    503
    Quote Originally Posted by Nika View Post
    I used this, but it didn't work.
    Code:
    	if (cmd[0].equals("bosslog")) {
    			player.getDialogueManager().startDialogue("BossLogInterface");
    			BossLog.sendBossLog(player);
    			return true;
    		}
    Mate. Write a dialogue and have it open it in the command. I don't even know what BossLog.sendBossLog(player); is. Lol.
    Reply With Quote  
     

  7. #7  
    Registered Member
    Join Date
    Mar 2013
    Posts
    191
    Thanks given
    13
    Thanks received
    12
    Rep Power
    26
    Quote Originally Posted by lilquickguy View Post
    Did you make the actual dialogue? Did you define it in DialogueHandler.java?
    I did make the dialogue. Why would I put it in DialogueHandler? I have it as a command.


    Code:
    package com.rs.game.player.dialogues;
    
    import com.rs.game.player.dialogues.Dialogue;
    import com.rs.game.player.content.interfaces.BossLog;
    
    public class BossLogInterface extends Dialogue {
    	
    	@Override
    	public void start() {
    		sendDialogue(SEND_2_OPTIONS, "Which would you like to view?", 
    				"Next Page.", 
    				"Previous Page.");
    		stage = 1;
    	}
    
    @Override
    public void run(int interfaceId, int componentId) {
    	if (interfaceId == SEND_2_OPTIONS && componentId == 1) {
    			BossLog.sendBossLog2(player);
    			end();
    			
    		} else if (interfaceId == SEND_2_OPTIONS && componentId == 2) {
    			BossLog.sendBossLog(player);
    			end();
    			
    		}
    	}
    	
    @Override
    public void finish() {
    	// TODO Auto-generated method stub
    			
    		}
    
    	}
    Reply With Quote  
     

  8. #8  
    Registered Member
    Join Date
    Mar 2013
    Posts
    191
    Thanks given
    13
    Thanks received
    12
    Rep Power
    26
    Quote Originally Posted by Curry View Post
    Mate. Write a dialogue and have it open it in the command. I don't even know what BossLog.sendBossLog(player); is. Lol.
    BossLog.sendBossLog(player) opens the interface
    Reply With Quote  
     

  9. #9  
    Registered Member
    Join Date
    Jul 2013
    Posts
    181
    Thanks given
    3
    Thanks received
    12
    Rep Power
    12
    Quote Originally Posted by Nika View Post
    I did make the dialogue. Why would I put it in DialogueHandler? I have it as a command.


    Code:
    package com.rs.game.player.dialogues;
    
    import com.rs.game.player.dialogues.Dialogue;
    import com.rs.game.player.content.interfaces.BossLog;
    
    public class BossLogInterface extends Dialogue {
    	
    	@Override
    	public void start() {
    		sendDialogue(SEND_2_OPTIONS, "Which would you like to view?", 
    				"Next Page.", 
    				"Previous Page.");
    		stage = 1;
    	}
    
    @Override
    public void run(int interfaceId, int componentId) {
    	if (interfaceId == SEND_2_OPTIONS && componentId == 1) {
    			BossLog.sendBossLog2(player);
    			end();
    			
    		} else if (interfaceId == SEND_2_OPTIONS && componentId == 2) {
    			BossLog.sendBossLog(player);
    			end();
    			
    		}
    	}
    	
    @Override
    public void finish() {
    	// TODO Auto-generated method stub
    			
    		}
    
    	}
    You have to....that's how it works...You need to define it in DialogueHandler. Without defining it, it isn't a proper working dialogue and the game will not recognize it...
    Reply With Quote  
     

  10. Thankful user:


  11. #10  
    Registered Member
    Join Date
    Mar 2013
    Posts
    191
    Thanks given
    13
    Thanks received
    12
    Rep Power
    26
    Quote Originally Posted by lilquickguy View Post
    You have to....that's how it works...You need to define it in DialogueHandler. Without defining it, it isn't a proper working dialogue and the game will not recognize it...
    Wow derp my bad. Got it thanks.
    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. Quest Open Interface help...
    By 0v3rc0m3 in forum Help
    Replies: 11
    Last Post: 02-01-2009, 11:54 PM
  2. teleport interface help
    By Bmxican in forum Help
    Replies: 2
    Last Post: 01-09-2009, 02:03 AM
  3. New interface help
    By Magers in forum Help
    Replies: 0
    Last Post: 12-01-2008, 12:46 AM
  4. item in interface help plz
    By garaa447 in forum Help
    Replies: 0
    Last Post: 11-25-2008, 02:51 AM
  5. [508] item on interfaces help
    By tinosk in forum Requests
    Replies: 7
    Last Post: 10-31-2008, 06:17 PM
Posting Permissions
  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •