Welcome!

Join our community of MMO enthusiasts and game developers! By registering, you'll gain access to discussions on the latest developments in MMO server files and collaborate with like-minded individuals. Join us today and unlock the potential of MMO 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;
 
Junior Spellweaver
Joined
Nov 18, 2007
Messages
173
Reaction score
5
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.
 
Newbie Spellweaver
Joined
Aug 13, 2012
Messages
31
Reaction score
0
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
Top