Welcome!

Join our community of MMORPG enthusiasts and private server developers! By registering, you'll gain access to in-depth discussions on source codes, binaries, and the latest developments in MMORPG server files. Collaborate with like-minded individuals, explore tutorials, and share insights on building and optimizing private servers. Join us today and unlock the full potential of MMORPG server development!

Join Today!

Mutliple Bones On Altar

Initiate Mage
Joined
Oct 28, 2010
Messages
3
Reaction score
0
Cloudkane - Mutliple Bones On Altar - RaGEZONE Forums

Client.Java
~~~~~~~~~~~~~~~~~~~

Locate(ctrl+f)
Code:
private int somejunk;

Under it add

Code:
public int boneID;

UseItem.java
~~~~~~~~~~~~~~~~~~~~

Code:
case 409://alter id
	if (c.getPrayer().isBone(itemId))
	c.getDH().sendDialogues(594, 594);//ichose these #'s. you can chose w/e you want.
	c.boneID = itemId;
break;

If you already have something for case 409 then remove it and add this.

DialogueHandler.java
~~~~~~~~~~~~~~~~~~~~~~

Code:
case 594://must be the same # you selected in useitem
			sendOption3("Sacrifice Bone","Sacrifice 10 Bones", "Sacrifice All Bones");
			c.dialogueAction = 595;//I chose this.. chose w/e number you want that isnt already used.
		break;


ClickingButtons.java
~~~~~~~~~~~~~~~~~~~~~~~~

Code:
ClickingButtons.java
~~~~~~~~~~~~~~~~~~~~~~~

	case 9167:
		if(c.dialogueAction == 595) {//same number used in dialogue handler
			if (c.getItems().playerHasItem(c.boneID,1)) {
			c.getPrayer().bonesOnAltar(c.boneID);
			c.getPA().closeAllWindows();
			c.sendMessage("@red@The God's are pleased with your sacrifice.");
		}
	}
		break;
	case 9168:
		if(c.dialogueAction == 595) {//same number used in dialogue handler
			for (int i = 0; i < 10; i++) {
				if (c.getItems().playerHasItem(c.boneID,1)) {
				c.getPrayer().bonesOnAltar(c.boneID);
				c.getPA().closeAllWindows();
				c.sendMessage("@red@The God's are pleased with your sacrifice.");
			}
		}
	}
		break;
	case 9169:
		if(c.dialogueAction == 595) {//same number used in dialogue handler
			for (int i = 0; i < 28; i++) {
				if (c.getItems().playerHasItem(c.boneID,1)) {
				c.getPrayer().bonesOnAltar(c.boneID);
				c.getPA().closeAllWindows();
				c.sendMessage("@red@The God's are pleased with your sacrifice.");
			}
		}
	}
		break;

These cases may already be used and it's up to you to figure out how to add onto the used cases.. or you can just clear w/e you got and add this.

An example of adding onto the cases..

Code:
case 9167:
			if(c.dialogueAction == 13) {//same number used in dialogue handler
				if (c.getItems().playerHasItem(c.boneID,1)) {
				c.getPrayer().bonesOnAltar(c.boneID);
				c.getPA().closeAllWindows();
		}
	}
			if (c.dialogueAction == 14) { //MB
					c.getPA().startTeleport(2541, 4714, 0, "modern");
				}//THIS WHOLE PART WAS HERE BEFORE I ADDED THE PART FOR BONES.
			break;
 
For what base? what revision? ......

Obviously 317. Because 508 and any other version above that do not use client.java to edit the server source. 508's and above use files which are split into different sections like Server.java, Engine.java, Player.java e.d.
 
When I get in game and try to click the option "Sacrifice all bones" it won't let me click it O_O. I'm positive I inserted everything right though.
 
Back