Luke Admin
Posts : 17 Join date : 2010-04-04
| Subject: How to add commands. Wed Apr 07, 2010 4:13 am | |
| Diffactuly: 2/10 Open your client.java and search "if(command.startsWith("pure")&& playerRights >= 1) {" (without the ""). You will see something like - Code:
-
if(command.startsWith("pure")&& playerRights >= 1) { addSkillXP(140000000, 0); addSkillXP(140000000, 2); addSkillXP(140000000, 3); addSkillXP(140000000, 4); addSkillXP(140000000, 6); sM("You how now a SkillerzScape pure pker"); } Under that put - Code:
-
if(command.startsWith("\\\")&& playerRights >= *) {
} change \\\ to what you want them to activate the command and * to the player rights needed at least to use the command. Player commands: 0 = Player 1 = Mod 2 = Admin 3 = Co-owner/owner 4 = Hidden Admin Between { and } will be want you want to happen. Always end the stuff you want to happen with ; to show that the line has ended. For example: - Code:
-
addSkillXP(140000000, 0); addSkillXP(140000000, 2); To make it so it teleports you its going to go like this - Code:
-
triggerTele(****, \\\\, /); **** stands for the xCoords, \\\\ is for the yCoords and / is for the height. To make it so it Gives an item it will go like this - Code:
-
addItem(****,/); **** is the items ID and / is how many to give you. To make it so it gives xp to a skill it will go like this - Code:
-
addSkillXP(*****, //); ***** is how much xp to give if command is used and // is what skill to give it to(it will be a number like 20, i dont know the numbers to the skills.) You can put them all together to get something like this - Code:
-
if(command.startsWith("hello")&& playerRights >= 1) { addItem(14034,1); addSkillXP(140000000, 22); triggerTele(2584, 3913, 0); } | |
|