PDA

View Full Version : [377] Chatbox interfaces & infodia.



Fire cape
July 10th, 2010, 20:58
Description: Adding a packet that makes an interface appear over the chatbox.
Assumed Knowledge: How to read.
Tested Server: Rs377d
Files/Classes modified: ActionSender.
Files/Classes added: N/A

This is what your adding:
Only the registered members can see the link.

Open your source, and follow this package.

org.rs377d.net.util

Open up ActionSender and add theese in.


/**
* Sends an interface over the chatbox.
* @param interfaceId the chatbox interface id.
* @return the action sender instance for chaining.
*/
public ActionSender chatBoxInterface(int interfaceId) {
Rs2PacketBuilder packet = new Rs2PacketBuilder(109);
packet.putShort(interfaceId);
player.getSession().write(packet.toPacket());
return this;
}


/**
* Sends text onto an interface.
* @param text the first line of text.
* @param text2 the second line of text.
* @param text3 the third line of text.
* @param text4 the fourth line of text.
* @param title the title of the text.
* @return the action sender instance for chanining.
*/
public ActionSender infodia(String text, String text2, String text3, String text4, String title){
sendString(title, 6180);
sendString(text, 6181);
sendString(text2, 6182);
sendString(text3, 6183);
sendString(text4, 6184);
chatBoxInterface(6179);
return this;
}

Jesse
July 10th, 2010, 21:05
nice dialouge i get no credits i did all of this for u -,- :p

Fire cape
July 10th, 2010, 21:05
nice dialouge i get no credits i did all of this for u -,- :p

Lol @ your comments :D.

Emily
July 10th, 2010, 21:05
Looks nice, good job

h1 sk1ller
July 12th, 2010, 09:44
Nice :)