Jump to content

Search the Community

Showing results for tags 'class'.



More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • RuneLocus
    • News & Announcements
    • Information Booth
    • Website Support
    • Introductions
    • Chat
    • Forum Games
  • RuneScape Development
    • RSPS General
    • RuneScape Private Server (RS2)
    • RuneScape Private Server (503+)
    • RuneScape Private Server (EoC 742+)
  • Other
    • Digital Art
    • Gaming
    • Webdevelopment
    • Computers
  • Marketplace
    • RuneScape Market
    • RSPS Market
    • Others Market
    • Freelance Middleman Services
  • Super Secret Club's Topics

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Found 69 results

  1. No matter what revision or client I have tried, all of them can never find the main class Jframe/client/Loader If anyone can teamviewer me or skype me, that would be greatly appreciated, thanks in advance! -~Nemonax~-
  2. I am using DecietfulPk source,client, and cache. I don't know why but with this source it seems not want to be working when I jar it like all my other 317's that work flawlessly.. Anyone know the answer? [ATTACH=CONFIG]10928[/ATTACH] If you need more information to help me fix it please let me know. I have been working on this source editing it and don't want all my time to go to waste.
  3. NEED Someone TO HELP ME LAUNCH MY SERVER BUT CANT SEEM TO FIX STUPID PROBLEMS HELP AND U WILL BE PAID ETC. please.
  4. MikeMike1997

    Slayer Class

    My slayer is not making a class file. Not really sure why, this is preventing myself from updating slayer... SlayerMaster code [code] package com.rs.game.player.dialogues.impl; import com.rs.game.player.dialogues.Dialogue; public class SlayerMaster extends Dialogue { [MENTION=15855]Over[/MENTION]ride public void start() { sendEntityDialogue(IS_NPC, "Kuradal", 9085, 9827, "Hello warrior, What can i do for you? (Test for Mike)"); stage = 1; } [MENTION=15855]Over[/MENTION]ride public void run(int interfaceId, int componentId) { if (stage == 1) { sendOptionsDialogue("Slayer Options", "I would like a new Slayer Task", "Reset my slayer task (Cost: 500k)", "Tell me my current task", "I have completed my current task", "Show me the Rewards Shop"); stage = 2; } else if (stage == 2) { if (componentId == OPTION_1) { if (player.getTask().isComplete()) { sendEntityDialogue(IS_NPC, "Kuradal", 9085, 9827, "Turn in your previous task before getting a new one!"); stage = 1; return; } if (player.getTask().getTaskAmount() > 0){ sendEntityDialogue(IS_NPC, "Kuradal", 9085, 9827, "Please reset or finsh your ", "task if you want another!"); stage = 1; return; } player.getTask().getNewTask(); int amount = player.getTask().getTaskAmount(); sendEntityDialogue(IS_NPC, "Kuradal", 9085, 9827, "Your new task is to kill:", "x"+amount+" "+player.getTask().getName()+""); stage = 1; } else if (componentId == OPTION_2) { if (player.getInventory().containsItem(995, 500000)) { player.getTask().getNewTask(); int amount = player.getTask().getTaskAmount(); player.getInventory().deleteItem(995, 500000); sendEntityDialogue(IS_NPC, "Kuradal", 9085, 9827, "Your new task is to kill:", "x"+amount+" "+player.getTask().getName()+""); } else { sendEntityDialogue(IS_NPC, "Kuradal", 9085, 9827, "Please come back when you", "have atleast 500k on you."); stage = 1; } } else if (componentId == OPTION_3) { int amount = player.getTask().getTaskAmount(); if (player.getTask().getTaskAmount() == -2) { sendEntityDialogue(IS_NPC, "Kuradal", 9085, 9827, "You do not have a task."); } else { sendEntityDialogue(IS_NPC, "Kuradal", 9085, 9827, "Your current task is to kill:", "x"+amount+" "+player.getTask().getName()+""); } stage = 1; } else if (componentId == OPTION_4) { if (player.getTask().getCurrentTask() > 0) { sendEntityDialogue(IS_NPC, "Kuradal", 9085, 9827, "You still have remaining:", "x"+player.getTask().getTaskAmount()+" "+player.getTask().getName()+""); stage = 1; } else { if (player.getTask().getCurrentTask() < 1) { sendEntityDialogue(IS_NPC, "Kuradal", 9085, 9827, "Very good! Have some slayer points!", "You can now set a new task."); boolean hasSlayerRing = player.getEquipment().getRingId() == 13281; player.setSlayerPoints(player.getSlayerPoints() + (hasSlayerRing == true ? 40 : 20)); player.getTask().resetTask(); stage = 1; } else { sendEntityDialogue(IS_NPC, "Kuradal", 9085, 9827, "You do not currently have a task."); stage = 1; } } } else if (componentId == OPTION_5) { end(); player.getInterfaceManager().sendInterface(164); player.getPackets().sendIComponentText(164, 20, ""+player.getSlayerPoints()+""); } } } [MENTION=15855]Over[/MENTION]ride public void finish() { // TODO Auto-generated method stub } } [/code]
  5. black dora

    Help with .class

    Hello, everyones probably going to call me stupid, but i have no idea where to add a new .class file. For example, if i wanted to code in a working Dwarf Mulit Cannon, where do i put the new class or java files for them. Do i need to make both a class and java file? Also how do import these new files into another java file i want them to be implemented in. Everytime i try this the compiler gives errors saying it cannot find the files, even though they are given a clearly stated path to where the .class file/ .java file is located. Im using a 317 [PI] Aggroth Base, once again i may be stupid for not knowing how to do this, but i really want to know so i can start adding major things to my server. Thanks for anyone who can help! :)
  6. Another contribrution for me to the project insanity. This is a proper Equipment class. Client.java [code] private Equipment equipment = new Equipment(this); [/code] Add this too with the other getters at Client.java [CODE]public Equipment getEquipment() { return equipment; }[/CODE] Equipment.java [CODE]package server.model.players; import server.Config; import server.Server; import server.model.items.Item; import server.model.items.ItemAssistant; import server.model.players.Client; import server.model.players.PlayerSave; /** * @author Fuzen Seth * [MENTION=98951]infor[/MENTION]mation Represents a proper equipment class. * [MENTION=3199]Sin[/MENTION]ce 23.7.2014 */ public class Equipment { private Client c; public Equipment(Client c) { this.c = c; } /** * slot shield */ public static final String[] SHIELDS = {"spirit shield", "defender", "farseer"}; /** * slot weapon */ public static final String[] WEAPONS = {"rapier", "maul", "staff", "longsword"}; /** * Gets the bonus' of an item. */ public void writeBonus() { int offset = 0; String send = ""; for (int i = 0; i < c.playerBonus.length; i++) { if (c.playerBonus[i] >= 0) { send = BONUS_NAMES[i]+": +"+c.playerBonus[i]; } else { send = BONUS_NAMES[i]+": -"+java.lang.Math.abs(c.playerBonus[i]); } if (i == 10) { offset = 1; } c.getPA().sendFrame126(send, (1675+i+offset)); } } /** * Gets the item name from the item.cfg */ public static String getItemName(int ItemID) { for (int i = 0; i < Config.ITEM_LIMIT; i++) { if (Server.itemHandler.ItemList[i] != null) { if (Server.itemHandler.ItemList[i].itemId == ItemID) { return Server.itemHandler.ItemList[i].itemName; } } } return "Unarmed"; } /** * Gets the item type. */ public String itemType(int item) { for (int i = 0; i < Item.capes.length; i++) { if (item == Item.capes[i]) return "cape"; } for (int i = 0; i < Item.hats.length; i++) { if (item == Item.hats[i]) return "hat"; } for (int i = 0; i < Item.boots.length; i++) { if (item == Item.boots[i]) return "boots"; } for (int i = 0; i < Item.gloves.length; i++) { if (item == Item.gloves[i]) return "gloves"; } for (int i = 0; i < Item.shields.length; i++) { if (item == Item.shields[i]) return "shield"; } for (int i = 0; i < Item.amulets.length; i++) { if (item == Item.amulets[i]) return "amulet"; } for (int i = 0; i < Item.arrows.length; i++) { if (item == Item.arrows[i]) return "arrows"; } for (int i = 0; i < Item.rings.length; i++) { if (item == Item.rings[i]) return "ring"; } for (int i = 0; i < Item.body.length; i++) { if (item == Item.body[i]) return "body"; } for (int i = 0; i < Item.legs.length; i++) { if (item == Item.legs[i]) return "legs"; } return "weapon"; } /** * Item bonuses. **/ public final String[] BONUS_NAMES = { "Stab", "Slash", "Crush", "Magic", "Range", "Stab", "Slash", "Crush", "Magic", "Range", "Strength", "Prayer" }; /** * Resets item bonuses. */ public void resetBonus() { for (int i = 0; i < c.playerBonus.length; i++) { c.playerBonus[i] = 0; } } /** * Weapon requirements. **/ public void getRequirements(String itemName, int itemId) { c.attackLevelReq = c.defenceLevelReq = c.strengthLevelReq = c.rangeLevelReq = c.magicLevelReq = 0; if (itemName.contains("mystic") || itemName.contains("nchanted")) { if (itemName.contains("staff")) { c.magicLevelReq = 20; c.attackLevelReq = 40; } else { c.magicLevelReq = 20; c.defenceLevelReq = 20; } } if (itemName.contains("slayer helmet")) { c.defenceLevelReq = 10; } if (itemName.contains("initiate")) { c.defenceLevelReq = 20; } if (itemName.contains("infinity")) { c.magicLevelReq = 50; c.defenceLevelReq = 25; } if (itemName.contains("splitbark")) { c.magicLevelReq = 40; c.defenceLevelReq = 40; } if (itemName.contains("Black")) { if (itemName.contains("d'hide")) { c.rangeLevelReq = 70; if (itemName.contains("body")) c.defenceLevelReq = 40; return; } } if (itemName.contains("Green")) { if (itemName.contains("hide")) { c.rangeLevelReq = 40; if (itemName.contains("body")) c.defenceLevelReq = 40; return; } } if (itemName.contains("Blue")) { if (itemName.contains("hide")) { c.rangeLevelReq = 50; if (itemName.contains("body")) c.defenceLevelReq = 40; return; } } if (itemName.contains("Red")) { if (itemName.contains("hide")) { c.rangeLevelReq = 60; if (itemName.contains("body")) c.defenceLevelReq = 40; return; } } if (itemName.contains("Black")) { if (itemName.contains("hide")) { c.rangeLevelReq = 70; if (itemName.contains("body")) c.defenceLevelReq = 40; return; } } if (itemName.contains("bronze")) { if (!itemName.contains("knife") && !itemName.contains("dart") && !itemName.contains("javelin") && !itemName.contains("thrownaxe")) { c.attackLevelReq = c.defenceLevelReq = 1; } return; } if (itemName.contains("iron")) { if (!itemName.contains("knife") && !itemName.contains("dart") && !itemName.contains("javelin") && !itemName.contains("thrownaxe")) { c.attackLevelReq = c.defenceLevelReq = 1; } return; } if (itemName.contains("steel")) { if (!itemName.contains("knife") && !itemName.contains("dart") && !itemName.contains("javelin") && !itemName.contains("thrownaxe")) { c.attackLevelReq = c.defenceLevelReq = 5; } return; } if (itemName.contains("black")) { if (!itemName.contains("cavalier") && !itemName.contains("knife") && !itemName.contains("dart") && !itemName.contains("javelin") && !itemName.contains("thrownaxe") && !itemName.contains("vamb") && !itemName.contains("chap")) { c.attackLevelReq = c.defenceLevelReq = 10; } return; } if (itemName.contains("mithril")) { if (!itemName.contains("knife") && !itemName.contains("dart") && !itemName.contains("javelin") && !itemName.contains("thrownaxe")) { c.attackLevelReq = c.defenceLevelReq = 20; } return; } if (itemName.contains("adamant") || itemName.contains("adam")) { if (!itemName.contains("knife") && !itemName.contains("dart") && !itemName.contains("javelin") && !itemName.contains("thrownaxe")) { c.attackLevelReq = c.defenceLevelReq = 30; } return; } if (itemName.contains("rock-shell")) { c.defenceLevelReq = 40; } if (itemName.contains("zamorak")) { if (!itemName.contains("robe") && !itemName.contains("mitre") && !itemName.contains("stole") && !itemName.contains("godsword")) { c.defenceLevelReq = 40; } return; } if (itemName.contains("saradomin")) { if (!itemName.contains("robe") && !itemName.contains("mitre") && !itemName.contains("stole") && !itemName.contains("godsword")) { c.defenceLevelReq = 40; } return; } if (itemName.contains("guthix")) { if (!itemName.contains("robe") && !itemName.contains("mitre") && !itemName.contains("stole") && !itemName.contains("godsword")) { c.defenceLevelReq = 40; } return; } if (itemName.contains("rune")) { if (!itemName.contains("gloves") && !itemName.contains("knife") && !itemName.contains("dart") && !itemName.contains("javelin") && !itemName.contains("thrownaxe") && !itemName.contains("'bow")) { c.attackLevelReq = c.defenceLevelReq = 40; } return; } if (itemName.contains("dragon")) { if (!itemName.contains("nti-") && !itemName.contains("fire")) { c.attackLevelReq = c.defenceLevelReq = 60; return; } } if (itemName.contains("crystal")) { if (itemName.contains("shield")) { c.defenceLevelReq = 70; } else { c.rangeLevelReq = 70; } return; } if (itemName.contains("ahrim")) { if (itemName.contains("staff")) { c.magicLevelReq = 70; c.attackLevelReq = 70; } else { c.magicLevelReq = 70; c.defenceLevelReq = 70; } } if (itemName.contains("karil")) { if (itemName.contains("crossbow")) { c.rangeLevelReq = 70; } else { c.rangeLevelReq = 70; c.defenceLevelReq = 70; } } if (itemName.contains("godsword")) { c.attackLevelReq = 75; } if (itemName.contains("3rd age") && !itemName.contains("amulet")) { c.defenceLevelReq = 60; } if (itemName.contains("Initiate")) { c.defenceLevelReq = 20; } if (itemName.contains("verac") || itemName.contains("guthan") || itemName.contains("dharok") || itemName.contains("torag")) { if (itemName.contains("hammers")) { c.attackLevelReq = 70; c.strengthLevelReq = 70; } else if (itemName.contains("axe")) { c.attackLevelReq = 70; c.strengthLevelReq = 70; } else if (itemName.contains("warspear")) { c.attackLevelReq = 70; c.strengthLevelReq = 70; } else if (itemName.contains("flail")) { c.attackLevelReq = 70; c.strengthLevelReq = 70; } else { c.defenceLevelReq = 70; } } switch (itemId) { case 11720: case 11718: case 11722: c.defenceLevelReq = 70; c.rangeLevelReq = 70; return; case 10887: c.strengthLevelReq = 60; return; case 2497: case 2491: c.rangeLevelReq = 70; return; case 6528: c.strengthLevelReq = 60; return; case 8839: case 8840: case 8842: case 11663: case 11664: case 11665: c.attackLevelReq = 42; c.rangeLevelReq = 42; c.strengthLevelReq = 42; c.magicLevelReq = 42; c.defenceLevelReq = 42; return; case 10551: case 2503: case 2501: case 2499: case 1135: c.defenceLevelReq = 40; return; case 11235: case 6522: c.rangeLevelReq = 60; break; case 6524: c.defenceLevelReq = 60; break; case 11284: c.defenceLevelReq = 75; return; case 6889: case 6914: c.magicLevelReq = 60; break; case 861: c.rangeLevelReq = 50; break; case 10828: c.defenceLevelReq = 55; break; case 11724: case 11726: case 11728: c.defenceLevelReq = 65; break; case 3751: case 3749: case 3755: c.defenceLevelReq = 40; break; case 11283: c.defenceLevelReq = 75; break; case 851: case 853: c.rangeLevelReq = 30; break; case 847: case 849: c.rangeLevelReq = 20; break; case 845: case 843: c.rangeLevelReq = 5; break; case 5698: c.attackLevelReq = 60; break; case 7462: case 7461: c.defenceLevelReq = 40; break; case 8846: c.defenceLevelReq = 5; break; case 8847: c.defenceLevelReq = 10; break; case 8848: c.defenceLevelReq = 20; break; case 8849: c.defenceLevelReq = 30; break; case 8850: c.defenceLevelReq = 40; break; case 7460: c.defenceLevelReq = 40; break; case 837: c.rangeLevelReq = 61; break; case 4151: c.attackLevelReq = 70; return; case 14004: c.attackLevelReq = 75; case 6724: c.rangeLevelReq = 60; return; case 4153: c.attackLevelReq = 50; c.strengthLevelReq = 50; return; } } /** * Finds the item. * */ public int findItem(int id, int[] items, int[] amounts) { for (int i = 0; i < c.playerItems.length; i++) { if (((items[i] - 1) == id) && (amounts[i] > 0)) { return i; } } return -1; } /** * Updates the slot when wielding an item. * * [MENTION=75098]Para[/MENTION]m slot */ public void updateSlot(int slot) { synchronized (c) { if (c.getOutStream() != null && c != null) { c.getOutStream().createFrameVarSizeWord(34); c.getOutStream().writeWord(1688); c.getOutStream().writeByte(slot); c.getOutStream().writeWord(c.playerEquipment[slot] + 1); if (c.playerEquipmentN[slot] > 254) { c.getOutStream().writeByte(255); c.getOutStream().writeDWord(c.playerEquipmentN[slot]); } else { c.getOutStream().writeByte(c.playerEquipmentN[slot]); } c.getOutStream().endFrameVarSizeWord(); c.flushOutStream(); } } } /** * sendEquip **/ public boolean equip(int wearID, int slot) { synchronized (c) { int targetSlot = 0; boolean canWearItem = true; if (c.playerItems[slot] == (wearID + 1)) { getRequirements(getItemName(wearID).toLowerCase(), wearID); targetSlot = Item.targetSlots[wearID]; /** * String[] items */ for (String shields : SHIELDS) { if (itemType(wearID).toLowerCase().contains(shields)) { targetSlot = 5; } } for (String weapons : WEAPONS) { if (itemType(wearID).toLowerCase().contains(weapons)) { targetSlot = 0; } } if (itemType(wearID).equalsIgnoreCase("cape")) { targetSlot = 1; } else if (itemType(wearID).equalsIgnoreCase("hat")) { targetSlot = 0; } else if (itemType(wearID).equalsIgnoreCase("amulet")) { targetSlot = 2; } else if (itemType(wearID).equalsIgnoreCase("arrows")) { targetSlot = 13; } else if (itemType(wearID).equalsIgnoreCase("body")) { targetSlot = 4; } else if (itemType(wearID).equalsIgnoreCase("shield")) { targetSlot = 5; } else if (itemType(wearID).equalsIgnoreCase("legs")) { targetSlot = 7; } else if (itemType(wearID).equalsIgnoreCase("gloves")) { targetSlot = 9; } else if (itemType(wearID).equalsIgnoreCase("boots")) { targetSlot = 10; } else if (itemType(wearID).equalsIgnoreCase("ring")) { targetSlot = 12; } else { targetSlot = 3; } switch (wearID) { /* Gloves */ case 10336: case 9922: case 8842: targetSlot = 9; break; /* Arrows */ case 9144: targetSlot = 13; break; /* Capes */ case 19111: case 15008: case 9813: case 9747: case 9748: case 9750: case 9790: case 9751: case 9753: case 9754: case 9756: case 9757: case 9759: case 9760: case 9762: case 9763: case 9765: case 9766: case 9768: case 9769: case 9771: case 9772: case 9774: case 9775: case 10446: case 10448: case 10450: case 9777: case 9778: case 9780: case 9781: case 9783: case 9784: case 9786: case 9787: case 9792: case 9793: case 9795: case 9796: case 9798: case 9799: case 9801: case 9802: case 9804: case 9805: case 9807: case 9808: case 9810: case 9811: case 10499: targetSlot = 1; break; /* Arrows */ case 9244: targetSlot = 13; break; /* Boots */ case 15037: case 14605: case 11019: case 9921: case 11728: case 10839: targetSlot = 10; break; /* Legs */ case 11726: case 11722: case 9678: case 9923: case 9676: case 10394: case 8840: case 15035: case 10332: case 15036: case 14603: case 14938: case 14077: case 10346: case 10372: case 10838: case 11022: case 10388: case 10380: case 10340: case 15425: case 13360: case 13352: case 13346: targetSlot = 7; break; /* Amulets */ case 6861: case 6859: case 6863: case 9470: case 14000: case 6857: case 10344: case 11128: targetSlot = 2; break; /* Shields */ case 14502: case 14503: case 8850: case 8849: case 8848: case 8847: case 8846: case 8845: case 8844: case 11283: case 10352: targetSlot = 5; break; /* Bodies */ case 10551: case 10348: case 9674: case 10837: case 14936: case 15034: case 10386: case 10370: case 11720: case 10330: case 15423: case 14076: case 11020: case 14595: case 8839: case 10338: case 13348: case 13354: case 13358: case 9924: case 11724: targetSlot = 4; break; /* Helms */ case 13263: case 9920: case 10507: case 10836: case 10828: case 9672: case 10334: case 10350: case 10390: case 11718: case 10374: case 11021: case 15422: case 15033: case 9925: case 13362: case 11663: case 11664: case 11665: case 13355: case 13350: case 10342: case 1037: case 11335: case 10548: case 9749: case 9752: case 9755: case 9758: case 9761: case 9764: case 9767: case 9770: case 9773: case 9776: case 9779: case 9782: case 9785: case 9788: case 9791: case 9794: case 9797: case 9800: case 9803: case 9806: case 9809: case 9812: targetSlot = 0; break; /* Boots */ case 11732: targetSlot = 10; break; } if (c.duelRule[11] && targetSlot == 0) { c.sendMessage("Wearing hats has been disabled in this duel!"); return false; } if (c.duelRule[12] && targetSlot == 1) { c.sendMessage("Wearing capes has been disabled in this duel!"); return false; } if (c.duelRule[13] && targetSlot == 2) { c.sendMessage("Wearing amulets has been disabled in this duel!"); return false; } if (c.duelRule[14] && targetSlot == 3) { c.sendMessage("Wielding weapons has been disabled in this duel!"); return false; } if (c.duelRule[15] && targetSlot == 4) { c.sendMessage("Wearing bodies has been disabled in this duel!"); return false; } if ((c.duelRule[16] && targetSlot == 5) || (c.duelRule[16] && is2handed(getItemName(wearID) .toLowerCase(), wearID))) { c.sendMessage("Wearing shield has been disabled in this duel!"); return false; } if (c.duelRule[17] && targetSlot == 7) { c.sendMessage("Wearing legs has been disabled in this duel!"); return false; } if (c.duelRule[18] && targetSlot == 9) { c.sendMessage("Wearing gloves has been disabled in this duel!"); return false; } if (c.duelRule[19] && targetSlot == 10) { c.sendMessage("Wearing boots has been disabled in this duel!"); return false; } if (c.duelRule[20] && targetSlot == 12) { c.sendMessage("Wearing rings has been disabled in this duel!"); return false; } if (c.duelRule[21] && targetSlot == 13) { c.sendMessage("Wearing arrows has been disabled in this duel!"); return false; } if (Config.itemRequirements) { if (targetSlot == 10 || targetSlot == 7 || targetSlot == 5 || targetSlot == 4 || targetSlot == 0 || targetSlot == 9 || targetSlot == 10) { if (c.defenceLevelReq > 0) { if (c.getPA().getLevelForXP(c.playerXP[1]) < c.defenceLevelReq) { c.sendMessage("You need a defence level of " + c.defenceLevelReq + " to wear this item."); canWearItem = false; } } if (c.rangeLevelReq > 0) { if (c.getPA().getLevelForXP(c.playerXP[4]) < c.rangeLevelReq) { c.sendMessage("You need a range level of " + c.rangeLevelReq + " to wear this item."); canWearItem = false; } } if (c.magicLevelReq > 0) { if (c.getPA().getLevelForXP(c.playerXP[6]) < c.magicLevelReq) { c.sendMessage("You need a magic level of " + c.magicLevelReq + " to wear this item."); canWearItem = false; } } } if (targetSlot == 3) { if (c.attackLevelReq > 0) { if (c.getPA().getLevelForXP(c.playerXP[0]) < c.attackLevelReq) { c.sendMessage("You need an attack level of " + c.attackLevelReq + " to wield this weapon."); canWearItem = false; } } if (c.rangeLevelReq > 0) { if (c.getPA().getLevelForXP(c.playerXP[4]) < c.rangeLevelReq) { c.sendMessage("You need a range level of " + c.rangeLevelReq + " to wield this weapon."); canWearItem = false; } } if (c.magicLevelReq > 0) { if (c.getPA().getLevelForXP(c.playerXP[6]) < c.magicLevelReq) { c.sendMessage("You need a magic level of " + c.magicLevelReq + " to wield this weapon."); canWearItem = false; } } } } if (!canWearItem) { return false; } int wearAmount = c.playerItemsN[slot]; if (wearAmount < 1) { return false; } if (targetSlot == c.playerWeapon) { c.autocasting = false; c.autocastId = 0; c.getPA().sendFrame36(108, 0); } if (slot >= 0 && wearID >= 0) { int toEquip = c.playerItems[slot]; int toEquipN = c.playerItemsN[slot]; int toRemove = c.playerEquipment[targetSlot]; int toRemoveN = c.playerEquipmentN[targetSlot]; if (toEquip == toRemove + 1 && Item.itemStackable[toRemove]) { deleteItem(toRemove, getItemSlot(toRemove), toEquipN); c.playerEquipmentN[targetSlot] += toEquipN; } else if (targetSlot != 5 && targetSlot != 3) { c.playerItems[slot] = toRemove + 1; c.playerItemsN[slot] = toRemoveN; c.playerEquipment[targetSlot] = toEquip - 1; c.playerEquipmentN[targetSlot] = toEquipN; } else if (targetSlot == 5) { boolean wearing2h = is2handed( getItemName(c.playerEquipment[c.playerWeapon]) .toLowerCase(), c.playerEquipment[c.playerWeapon]); boolean wearingShield = c.playerEquipment[c.playerShield] > 0; if (wearing2h) { toRemove = c.playerEquipment[c.playerWeapon]; toRemoveN = c.playerEquipmentN[c.playerWeapon]; c.playerEquipment[c.playerWeapon] = -1; c.playerEquipmentN[c.playerWeapon] = 0; updateSlot(c.playerWeapon); } c.playerItems[slot] = toRemove + 1; c.playerItemsN[slot] = toRemoveN; c.playerEquipment[targetSlot] = toEquip - 1; c.playerEquipmentN[targetSlot] = toEquipN; } else if (targetSlot == 3) { boolean is2h = is2handed(getItemName(wearID) .toLowerCase(), wearID); boolean wearingShield = c.playerEquipment[c.playerShield] > 0; boolean wearingWeapon = c.playerEquipment[c.playerWeapon] > 0; if (is2h) { if (wearingShield && wearingWeapon) { if (freeSlots() > 0) { c.playerItems[slot] = toRemove + 1; c.playerItemsN[slot] = toRemoveN; c.playerEquipment[targetSlot] = toEquip - 1; c.playerEquipmentN[targetSlot] = toEquipN; removeItem( c.playerEquipment[c.playerShield], c.playerShield); } else { c.sendMessage("You do not have enough inventory space to do this."); return false; } } else if (wearingShield && !wearingWeapon) { c.playerItems[slot] = c.playerEquipment[c.playerShield] + 1; c.playerItemsN[slot] = c.playerEquipmentN[c.playerShield]; c.playerEquipment[targetSlot] = toEquip - 1; c.playerEquipmentN[targetSlot] = toEquipN; c.playerEquipment[c.playerShield] = -1; c.playerEquipmentN[c.playerShield] = 0; updateSlot(c.playerShield); } else { c.playerItems[slot] = toRemove + 1; c.playerItemsN[slot] = toRemoveN; c.playerEquipment[targetSlot] = toEquip - 1; c.playerEquipmentN[targetSlot] = toEquipN; } } else { c.playerItems[slot] = toRemove + 1; c.playerItemsN[slot] = toRemoveN; c.playerEquipment[targetSlot] = toEquip - 1; c.playerEquipmentN[targetSlot] = toEquipN; } } c.isFullHelm = Item .isFullHelm(c.playerEquipment[c.playerHat]); c.isFullMask = Item .isFullMask(c.playerEquipment[c.playerHat]); c.isFullBody = Item .isFullBody(c.playerEquipment[c.playerChest]); resetItems(3214); } if (targetSlot == 3) { c.usingSpecial = false; addSpecialBar(wearID); } if (c.getOutStream() != null && c != null) { c.getOutStream().createFrameVarSizeWord(34); c.getOutStream().writeWord(1688); c.getOutStream().writeByte(targetSlot); c.getOutStream().writeWord(wearID + 1); if (c.playerEquipmentN[targetSlot] > 254) { c.getOutStream().writeByte(255); c.getOutStream().writeDWord( c.playerEquipmentN[targetSlot]); } else { c.getOutStream().writeByte( c.playerEquipmentN[targetSlot]); } c.getOutStream().endFrameVarSizeWord(); c.flushOutStream(); } sendWeapon(c.playerEquipment[c.playerWeapon], getItemName(c.playerEquipment[c.playerWeapon])); resetBonus(); getBonus(); writeBonus(); c.getCombat().getPlayerAnimIndex( c.getItems() .getItemName(c.playerEquipment[c.playerWeapon]) .toLowerCase()); c.getPA().requestUpdates(); return true; } else { return false; } } } public void deleteItem(int id, int amount) { deleteItem(id, getItemSlot(id), amount); } public void deleteItem(int id, int slot, int amount) { if (id <= 0 || slot < 0) { return; } if (c.playerItems[slot] == (id + 1)) { if (c.playerItemsN[slot] > amount) { c.playerItemsN[slot] -= amount; } else { c.playerItemsN[slot] = 0; c.playerItems[slot] = 0; } PlayerSave.saveGame(c); resetItems(3214); } } /** * Gets the item slot. * * [MENTION=75098]Para[/MENTION]m ItemID * [MENTION=184045]return[/MENTION] */ public int getItemSlot(int ItemID) { for (int i = 0; i < c.playerItems.length; i++) { if ((c.playerItems[i] - 1) == ItemID) { return i; } } return -1; } /** * Two handed weapon check. **/ public boolean is2handed(String itemName, int itemId) { if (itemName.contains("ahrim") || itemName.contains("karil") || itemName.contains("verac") || itemName.contains("guthan") || itemName.contains("dharok") || itemName.contains("torag")) { return true; } if (itemName.contains("longbow") || itemName.contains("shortbow") || itemName.contains("ark bow")) { return true; } if (itemName.contains("crystal")) { return true; } if (itemName.contains("godsword") || itemName.contains("aradomin sword") || itemName.contains("2h") || itemName.contains("spear")) { return true; } switch (itemId) { case 6724: case 11730: case 4153: case 6528: case 10887: case 11777: return true; } return false; } /** * Checks if you have a free slot. * * [MENTION=184045]return[/MENTION] */ public int freeSlots() { int freeS = 0; for (int i = 0; i < c.playerItems.length; i++) { if (c.playerItems[i] <= 0) { freeS++; } } return freeS; } /** * Gets the item bonus from the item.cfg. */ public void getBonus() { for (int i = 0; i < c.playerEquipment.length; i++) { if (c.playerEquipment[i] > -1) { for (int j = 0; j < Config.ITEM_LIMIT; j++) { if (Server.itemHandler.ItemList[j] != null) { if (Server.itemHandler.ItemList[j].itemId == c.playerEquipment[i]) { for (int k = 0; k < c.playerBonus.length; k++) { c.playerBonus[k] += Server.itemHandler.ItemList[j].Bonuses[k]; } break; } } } } } } /** * Weapon type. **/ public void sendWeapon(int Weapon, String WeaponName) { String WeaponName2 = WeaponName.replaceAll("Bronze", ""); WeaponName2 = WeaponName2.replaceAll("Iron", ""); WeaponName2 = WeaponName2.replaceAll("Steel", ""); WeaponName2 = WeaponName2.replaceAll("Black", ""); WeaponName2 = WeaponName2.replaceAll("Mithril", ""); WeaponName2 = WeaponName2.replaceAll("Adamant", ""); WeaponName2 = WeaponName2.replaceAll("Rune", ""); WeaponName2 = WeaponName2.replaceAll("Granite", ""); WeaponName2 = WeaponName2.replaceAll("Dragon", ""); WeaponName2 = WeaponName2.replaceAll("Drag", ""); WeaponName2 = WeaponName2.replaceAll("Crystal", ""); WeaponName2 = WeaponName2.trim(); /** * Attack styles. */ if (WeaponName.equals("Unarmed")) { c.setSidebarInterface(0, 5855); // punch, kick, block c.getPA().sendFrame126(WeaponName, 5857); } else if (WeaponName.endsWith("whip") || WeaponName.contains("tentacle")) { c.setSidebarInterface(0, 12290); // flick, lash, deflect c.getPA().sendFrame246(12291, 200, Weapon); c.getPA().sendFrame126(WeaponName, 12293); } else if (WeaponName.endsWith("bow") || WeaponName.endsWith("10") || WeaponName.endsWith("full") || WeaponName.startsWith("seercull")) { c.setSidebarInterface(0, 1764); // accurate, rapid, longrange c.getPA().sendFrame246(1765, 200, Weapon); c.getPA().sendFrame126(WeaponName, 1767); } else if (WeaponName.startsWith("Staff") || WeaponName.endsWith("seas") || WeaponName.endsWith("staff") || WeaponName.endsWith("wand")) { c.setSidebarInterface(0, 328); // spike, impale, smash, block c.getPA().sendFrame246(329, 200, Weapon); c.getPA().sendFrame126(WeaponName, 331); } else if (WeaponName2.startsWith("dart") || WeaponName2.startsWith("knife") || WeaponName2.startsWith("javelin") || WeaponName.equalsIgnoreCase("toktz-xil-ul")) { c.setSidebarInterface(0, 4446); // accurate, rapid, longrange c.getPA().sendFrame246(4447, 200, Weapon); c.getPA().sendFrame126(WeaponName, 4449); } else if (WeaponName2.startsWith("dagger") || WeaponName2.contains("anchor") || WeaponName2.contains("sword")) { c.setSidebarInterface(0, 2276); // stab, lunge, slash, block c.getPA().sendFrame246(2277, 200, Weapon); c.getPA().sendFrame126(WeaponName, 2279); } else if (WeaponName2.startsWith("pickaxe")) { c.setSidebarInterface(0, 5570); // spike, impale, smash, block c.getPA().sendFrame246(5571, 200, Weapon); c.getPA().sendFrame126(WeaponName, 5573); } else if (WeaponName2.startsWith("axe") || WeaponName2.startsWith("battleaxe")) { c.setSidebarInterface(0, 1698); // chop, hack, smash, block c.getPA().sendFrame246(1699, 200, Weapon); c.getPA().sendFrame126(WeaponName, 1701); } else if (WeaponName2.startsWith("halberd")) { c.setSidebarInterface(0, 8460); // jab, swipe, fend c.getPA().sendFrame246(8461, 200, Weapon); c.getPA().sendFrame126(WeaponName, 8463); } else if (WeaponName2.startsWith("Scythe")) { c.setSidebarInterface(0, 8460); // jab, swipe, fend c.getPA().sendFrame246(8461, 200, Weapon); c.getPA().sendFrame126(WeaponName, 8463); } else if (WeaponName2.startsWith("spear")) { c.setSidebarInterface(0, 4679); // lunge, swipe, pound, block c.getPA().sendFrame246(4680, 200, Weapon); c.getPA().sendFrame126(WeaponName, 4682); } else if (WeaponName2.toLowerCase().contains("mace")) { c.setSidebarInterface(0, 3796); c.getPA().sendFrame246(3797, 200, Weapon); c.getPA().sendFrame126(WeaponName, 3799); } else if (c.playerEquipment[c.playerWeapon] == 4153) { c.setSidebarInterface(0, 425); // war hammer equip. c.getPA().sendFrame246(426, 200, Weapon); c.getPA().sendFrame126(WeaponName, 428); } else { c.setSidebarInterface(0, 2423); // chop, slash, lunge, block c.getPA().sendFrame246(2424, 200, Weapon); c.getPA().sendFrame126(WeaponName, 2426); } } /** * Removes a wielded item. **/ public void removeItem(int wearID, int slot) { // synchronized(c) { if (c.getOutStream() != null && c != null) { if (c.playerEquipment[slot] > -1) { if (addItem(c.playerEquipment[slot], c.playerEquipmentN[slot])) { c.playerEquipment[slot] = -1; c.playerEquipmentN[slot] = 0; sendWeapon(c.playerEquipment[c.playerWeapon], getItemName(c.playerEquipment[c.playerWeapon])); resetBonus(); getBonus(); writeBonus(); c.getCombat().getPlayerAnimIndex( ItemAssistant .getItemName( c.playerEquipment[c.playerWeapon]) .toLowerCase()); c.getOutStream().createFrame(34); c.getOutStream().writeWord(6); c.getOutStream().writeWord(1688); c.getOutStream().writeByte(slot); c.getOutStream().writeWord(0); c.getOutStream().writeByte(0); c.flushOutStream(); c.updateRequired = true; c.setAppearanceUpdateRequired(true); c.isFullHelm = Item .isFullHelm(c.playerEquipment[c.playerHat]); c.isFullMask = Item .isFullMask(c.playerEquipment[c.playerHat]); c.isFullBody = Item .isFullBody(c.playerEquipment[c.playerChest]); } } } } public boolean playerHasItem(int itemID, int amt, int slot) { itemID++; int found = 0; if (c.playerItems[slot] == (itemID)) { for (int i = 0; i < c.playerItems.length; i++) { if (c.playerItems[i] == itemID) { if (c.playerItemsN[i] >= amt) { return true; } else { found++; } } } if (found >= amt) { return true; } return false; } return false; } public boolean playerHasItem(int itemID) { itemID++; for (int i = 0; i < c.playerItems.length; i++) { if (c.playerItems[i] == itemID) return true; } return false; } public boolean playerHasItem(int itemID, int amt) { itemID++; int found = 0; for (int i = 0; i < c.playerItems.length; i++) { if (c.playerItems[i] == itemID) { if (c.playerItemsN[i] >= amt) { return true; } else { found++; } } } if (found >= amt) { return true; } return false; } public boolean addItem(int item, int amount) { // synchronized(c) { if (amount < 1) { amount = 1; } if (item <= 0) { return false; } if ((((freeSlots() >= 1) || playerHasItem(item, 1)) && Item.itemStackable[item]) || ((freeSlots() > 0) && !Item.itemStackable[item])) { for (int i = 0; i < c.playerItems.length; i++) { if ((c.playerItems[i] == (item + 1)) && Item.itemStackable[item] && (c.playerItems[i] > 0)) { c.playerItems[i] = (item + 1); if (((c.playerItemsN[i] + amount) < Config.MAXITEM_AMOUNT) && ((c.playerItemsN[i] + amount) > -1)) { c.playerItemsN[i] += amount; } else { c.playerItemsN[i] = Config.MAXITEM_AMOUNT; } if (c.getOutStream() != null && c != null) { c.getOutStream().createFrameVarSizeWord(34); c.getOutStream().writeWord(3214); c.getOutStream().writeByte(i); c.getOutStream().writeWord(c.playerItems[i]); if (c.playerItemsN[i] > 254) { c.getOutStream().writeByte(255); c.getOutStream().writeDWord(c.playerItemsN[i]); } else { c.getOutStream().writeByte(c.playerItemsN[i]); } c.getOutStream().endFrameVarSizeWord(); c.flushOutStream(); } i = 30; return true; } } for (int i = 0; i < c.playerItems.length; i++) { if (c.playerItems[i] <= 0) { c.playerItems[i] = item + 1; if ((amount < Config.MAXITEM_AMOUNT) && (amount > -1)) { c.playerItemsN[i] = 1; if (amount > 1) { c.getItems().addItem(item, amount - 1); return true; } } else { c.playerItemsN[i] = Config.MAXITEM_AMOUNT; } resetItems(3214); i = 30; return true; } } return false; } else { resetItems(3214); c.sendMessage("Not enough space in your inventory."); return false; } // } } /** * Empties all of (a) player's items. */ public void resetItems(int WriteFrame) { synchronized (c) { if (c.getOutStream() != null && c != null) { c.getOutStream().createFrameVarSizeWord(53); c.getOutStream().writeWord(WriteFrame); c.getOutStream().writeWord(c.playerItems.length); for (int i = 0; i < c.playerItems.length; i++) { if (c.playerItemsN[i] > 254) { c.getOutStream().writeByte(255); c.getOutStream().writeDWord_v2(c.playerItemsN[i]); } else { c.getOutStream().writeByte(c.playerItemsN[i]); } c.getOutStream().writeWordBigEndianA(c.playerItems[i]); } c.getOutStream().endFrameVarSizeWord(); c.flushOutStream(); } } } /** * Adds special attack bar to special attack weapons. Removes special attack * bar to weapons that do not have special attacks. **/ public void addSpecialBar(int weapon) { switch (weapon) { case 4151: // whip case 14004: c.getPA().sendFrame171(0, 12323); specialAmount(weapon, c.specAmount, 12335); break; case 859: // magic bows case 861: case 11235: c.getPA().sendFrame171(0, 7549); specialAmount(weapon, c.specAmount, 7561); break; case 4587: // dscimmy c.getPA().sendFrame171(0, 7599); specialAmount(weapon, c.specAmount, 7611); break; case 3204: // d hally c.getPA().sendFrame171(0, 8493); specialAmount(weapon, c.specAmount, 8505); break; case 1377: // d battleaxe c.getPA().sendFrame171(0, 7499); specialAmount(weapon, c.specAmount, 7511); break; case 4153: // gmaul c.getPA().sendFrame171(0, 7474); specialAmount(weapon, c.specAmount, 7486); break; case 1249: // dspear c.getPA().sendFrame171(0, 7674); specialAmount(weapon, c.specAmount, 7686); break; case 1215:// dragon dagger case 1231: case 5680: case 5698: case 1305: // dragon long case 11694: case 11698: case 11700: case 11730: case 11696: case 10887: c.getPA().sendFrame171(0, 7574); specialAmount(weapon, c.specAmount, 7586); break; case 1434: // dragon mace c.getPA().sendFrame171(0, 7624); specialAmount(weapon, c.specAmount, 7636); break; default: c.getPA().sendFrame171(1, 7624); // mace interface c.getPA().sendFrame171(1, 7474); // hammer, gmaul c.getPA().sendFrame171(1, 7499); // axe c.getPA().sendFrame171(1, 7549); // bow interface c.getPA().sendFrame171(1, 7574); // sword interface c.getPA().sendFrame171(1, 7599); // scimmy sword interface, for most // swords c.getPA().sendFrame171(1, 8493); c.getPA().sendFrame171(1, 12323); // whip interface break; } } /** * Special attack bar filling amount. **/ public void specialAmount(int weapon, double specAmount, int barId) { c.specBarId = barId; c.getPA().sendFrame70(specAmount >= 10 ? 500 : 0, 0, (--barId)); c.getPA().sendFrame70(specAmount >= 9 ? 500 : 0, 0, (--barId)); c.getPA().sendFrame70(specAmount >= 8 ? 500 : 0, 0, (--barId)); c.getPA().sendFrame70(specAmount >= 7 ? 500 : 0, 0, (--barId)); c.getPA().sendFrame70(specAmount >= 6 ? 500 : 0, 0, (--barId)); c.getPA().sendFrame70(specAmount >= 5 ? 500 : 0, 0, (--barId)); c.getPA().sendFrame70(specAmount >= 4 ? 500 : 0, 0, (--barId)); c.getPA().sendFrame70(specAmount >= 3 ? 500 : 0, 0, (--barId)); c.getPA().sendFrame70(specAmount >= 2 ? 500 : 0, 0, (--barId)); c.getPA().sendFrame70(specAmount >= 1 ? 500 : 0, 0, (--barId)); updateSpecialBar(); sendWeapon(weapon, getItemName(weapon)); } /** * Special attack text. **/ public void updateSpecialBar() { String percent = Double.toString(c.specAmount); if (percent.contains(".")) { percent = percent.replace(".", ""); } if (percent.startsWith("0") && !percent.equals("00")) { percent = percent.replace("0", ""); } if (percent.startsWith("0") && percent.equals("00")) { percent = percent.replace("00", "0"); } c.getPA() .sendFrame126( c.usingSpecial ? "@[email protected] Attack (" + percent + "%)" : "@[email protected] Attack (" + percent + "%)", c.specBarId); } } [/CODE]
  7. Title says it all. Sorry but this may be a stupid question but im new to the auto vote.
  8. Trying to find out what I have done wrong, I have jarred the client with Loader not loader, done everything properly, tried jdk 6 and 7 Tried using Loader.java instead of Loader.class neither work Tried adding cache into client files. Tried basically most of the suggestions on the internet it seems not to be something obviousy YES the jarred file is uploaded to dropbox and the link is inside the client.html file, I have tried many different html clients. if anyone could help me I'd really appreciate it my skype is Sam.Thomas20
  9. [CODE]could not find or load main class server.Server[/CODE] Here's my run.bat [CODE]@echo off title Running "C:\Program Files\Java\jre7\bin\java.exe" -Xmx1200m -cp bin;deps/*; server.Server pause[/CODE] Any help would be appreciated! Thankyou :-)
  10. so heres the deal i have alot of .java and .class files for alot of tools and utilities but the problem is i dont know how to run them or make them into a runnable file please help thanks
  11. Hi, I'm having a problem with the files that are getting loaded by my server. When i change or remove dialogues/commands, save them (using eclipse) and restart the server it still shows the old text. Nothing updates, everything has worked before. For me it seems to come out of nowhere. Eclipse should auto compile when you save a file and it says it does. Updating prices & shops does work, but this doesn't require an IDE. Does anyone know how to fix this? For now it seems to be related to display text and such..? Thanks in advance, HolyDivinity
  12. Hey, so I tried making my own little RSPS by following the RuneLocus 'How to make a RuneScape private server' tutorial. Everything worked perfectly fine until I got to step #4. Everytime I try to open the run.bat in the Client folder (from the RuneLocus Starter Kit) the cmd pops up and says Could not find or load main class GUI. Press any key to continue. I'm completely new to all of this and I've searched for about an hour for help and nothing even fits my situation. Someone pleaseee please help me, I will very much appreciate it. And keep in mind that I'm a beginner, so if you will, please 'dumb it down' for me. Thanks!
  13. I have been trying to figure out how to fix this for a while now and I am not certain as to what is wrong. I will be as detailed as I can be. I am using the RuneLocus StarterPack and every time I start the run.bat in the Server folder I get the a CMD prompt with the message: Could not find or load main class server.GUI The code in the run.bat file is: @echo off title Project Insanity java -cp bin;deps/poi.jar;deps/mysql.jar;deps/mina.jar;deps/slf4j.jar;deps/slf4j-nop.jar;deps/jython.jar;log4j-1.2.15.jar; server.GUI pause I took time to analyze the code to see what was going wrong and could not find any errors. I attempted to change my CLASSPATH Environmental Variable to multiple directories. Even including the user-defined classes for the RuneLocus StarterPack. I also played with my PATH Environmental Variable but I'm certain that must be correct since I can type java and get java -help feedback. To double check the CLASSSPATH and PATH I echoed both of them through CMD with: echo %CLASSPATH% and echo %PATH% from which I received: %CLASSPATH% and C:\Program Files\Java\jdk1.7.0_45\bin I even tried to skip the middle man by not using the run.bat and just going straight through CMD to run the GUI.class. From that I get a java.lang.NoClassDefFoundError. So my only thought is it must be a CLASSPATH issue. Here's where it gets very frustrating though... I have the RuneLocus StarterPack on two computers. It works on one, and the other it does not. I compared both of my CLASSPATH and PATH and the code of the run.bat file and everything matches up. It's all the same, from what I can see. Any thoughts on the issue here? I would like to also add that I did have this working before and I must have changed something not thinking it would affect it...
  14. I am attempting to use netbeans to edit some of the files in the instructional starter pack. It says showing generated source file. No sources are attached to class' JAR file. How do I make it so I can edit every file? It would be optimal if I could make it into a project. I've looked around and used search to no avail. Thanks in advance. I have JDK 1.51 jre7 sdk and all that snazzy stuff as far as I know.
  15. Please help nobody helps me :'( [img]http://i.imgur.com/H1IA7IY.png[/img]
  16. hi, i am new to all this so i need a bit of help. i downloaded the rsps provided by runelocus but when i click StarterPack_RuneLocus>server>run.bat this error shows up in command prompt: error: could not find or load main class server.GUI could someone explain to me how to fix this. thanks in advance
  17. Hello RuneLocus, Last night i decided to give my Commands system a little make over and re-do every command i had. When i whas done i whas gonna test my commands and i found out that all my Player commands (Playerrights 0) works perfectly, also my Donator commands (isDonator) works good. So when im trying to do a Mod/Admin/Owner command it just doesnt work. Also the yell system dont work. And when i do ::mute without a name it says: The player must be offline. If i do ::mute remco IT doesnt mute him, just does nothing. So here is a copy of my Commands class i made [14:55:35]http://pastebin.com/63mDrHYf Can someone help me out here? That would be very awesome. Remco
  18. K. So i THOUGHT i would have some fun playing on some RSPS's on my computer by myself just to pass a rainy day... so i came here to look for some fun sources to download. I downloaded 3. First, all the clients didn't work at all.. so i spent over two hours fixing that.. i FINALLY got the client to work. But now.. somewhere in my process of fixing the clients... it broke something that messes with my servers?.. I always get the message: "Error: Could not find or load main class server.Server Press any key to continue . . ." Not a CLUE what i'm doing, just so everyone knows. In my Program Files > Java.. i have 2 folders, jre6, and jdk1.7.0_25 I haven't got a clue what to do... I'm so stressed. Someone please help. Any suggestion is appreciated.. Thank you. PS. I'm not the smartest on anything dealing with Java.. so please dumb it down to a nooby level for me. THANK YOU :P
  19. Hello my good people! I just purchased a VPS and got everything setup, but there's one problem. I made a runserver.sh and when I run it I'm greeted with this [ATTACH=CONFIG]8416[/ATTACH] As you can see it is quite unfortunate. Here are the contents of my sh file. [CODE] #!/bin/bash java -server -Xmx512m -cp bin:lib/* org.dementhium.RS2ServerBootstrap [/CODE] Any help would be greatly appreciated! Yours truly, Wing Edit: Alright, so I got it working, but now I'm encountering this! [code]# java -server -Xmx512m -cp bin:lib/* org.dementhium.RS2ServerBootstrap [Cache] Loading cache... [Cache] Loaded cache! [MapXTEA] Loaded 2213 map XTEA key(s) [PacketManager] Loading packet handlers... [PacketManager] Loaded 60 packet handlers. [World] Loading World... [ClanManager] Loading clans.... com.thoughtworks.xstream.converters.ConversionException: Cannot construct org.dementhium.content.clans.Clan as it does not have a no-args constructor : Cannot construct org.dementhium.content.clans.Clan as it does not have a no-args constructor ---- Debugging information ---- message : Cannot construct org.dementhium.content.clans.Clan as it does not have a no-args constructor cause-exception : com.thoughtworks.xstream.converters.reflection.ObjectAccessException cause-message : Cannot construct org.dementhium.content.clans.Clan as it does not have a no-args constructor class : java.util.HashMap required-type : org.dementhium.content.clans.Clan path : /map/entry/org.dementhium.content.clans.Clan line number : 4 ------------------------------- at com.thoughtworks.xstream.core.TreeUnmarshaller.convert(TreeUnmarshaller.java:88) at com.thoughtworks.xstream.core.AbstractReferenceUnmarshaller.convert(AbstractReferenceUnmarshaller.java:55) at com.thoughtworks.xstream.core.TreeUnmarshaller.convertAnother(TreeUnmarshaller.java:75) at com.thoughtworks.xstream.core.TreeUnmarshaller.convertAnother(TreeUnmarshaller.java:59) at com.thoughtworks.xstream.converters.collections.AbstractCollectionConverter.readItem(AbstractCollectionConverter.java:77) at com.thoughtworks.xstream.converters.collections.MapConverter.populateMap(MapConverter.java:79) at com.thoughtworks.xstream.converters.collections.MapConverter.unmarshal(MapConverter.java:66) at com.thoughtworks.xstream.core.TreeUnmarshaller.convert(TreeUnmarshaller.java:81) at com.thoughtworks.xstream.core.AbstractReferenceUnmarshaller.convert(AbstractReferenceUnmarshaller.java:55) at com.thoughtworks.xstream.core.TreeUnmarshaller.convertAnother(TreeUnmarshaller.java:75) at com.thoughtworks.xstream.core.TreeUnmarshaller.convertAnother(TreeUnmarshaller.java:59) at com.thoughtworks.xstream.core.TreeUnmarshaller.start(TreeUnmarshaller.java:142) at com.thoughtworks.xstream.core.AbstractTreeMarshallingStrategy.unmarshal(AbstractTreeMarshallingStrategy.java:33) at com.thoughtworks.xstream.XStream.unmarshal(XStream.java:907) at com.thoughtworks.xstream.XStream.unmarshal(XStream.java:893) at com.thoughtworks.xstream.XStream.fromXML(XStream.java:845) at org.dementhium.io.XMLHandler.fromXML(XMLHandler.java:57) at org.dementhium.content.clans.ClanManager.<init>(ClanManager.java:23) at org.dementhium.model.World.load(World.java:114) at org.dementhium.RS2ServerBootstrap.main(RS2ServerBootstrap.java:42) Caused by: com.thoughtworks.xstream.converters.reflection.ObjectAccessException: Cannot construct org.dementhium.content.clans.Clan as it does not have a no-args constructor at com.thoughtworks.xstream.converters.reflection.PureJavaReflectionProvider.newInstance(PureJavaReflectionProvider.java:71) at com.thoughtworks.xstream.converters.reflection.AbstractReflectionConverter.instantiateNewInstance(AbstractReflectionConverter.java:279) at com.thoughtworks.xstream.converters.reflection.AbstractReflectionConverter.unmarshal(AbstractReflectionConverter.java:149) at com.thoughtworks.xstream.core.TreeUnmarshaller.convert(TreeUnmarshaller.java:81) ... 19 more [ClanManager] Loaded 0 clans. [AreaManager] Loading areas... com.thoughtworks.xstream.converters.ConversionException: Cannot construct org.dementhium.content.areas.impl.CircularArea as it does not have a no-args constructor : Cannot construct org.dementhium.content.areas.impl.CircularArea as it does not have a no-args constructor ---- Debugging information ---- message : Cannot construct org.dementhium.content.areas.impl.CircularArea as it does not have a no-args constructor cause-exception : com.thoughtworks.xstream.converters.reflection.ObjectAccessException cause-message : Cannot construct org.dementhium.content.areas.impl.CircularArea as it does not have a no-args constructor class : java.util.ArrayList required-type : org.dementhium.content.areas.impl.CircularArea path : /list/circle line number : 4 ------------------------------- at com.thoughtworks.xstream.core.TreeUnmarshaller.convert(TreeUnmarshaller.java:88) at com.thoughtworks.xstream.core.AbstractReferenceUnmarshaller.convert(AbstractReferenceUnmarshaller.java:55) at com.thoughtworks.xstream.core.TreeUnmarshaller.convertAnother(TreeUnmarshaller.java:75) at com.thoughtworks.xstream.core.TreeUnmarshaller.convertAnother(TreeUnmarshaller.java:59) at com.thoughtworks.xstream.converters.collections.AbstractCollectionConverter.readItem(AbstractCollectionConverter.java:77) at com.thoughtworks.xstream.converters.collections.CollectionConverter.populateCollection(CollectionConverter.java:68) at com.thoughtworks.xstream.converters.collections.CollectionConverter.unmarshal(CollectionConverter.java:61) at com.thoughtworks.xstream.core.TreeUnmarshaller.convert(TreeUnmarshaller.java:81) at com.thoughtworks.xstream.core.AbstractReferenceUnmarshaller.convert(AbstractReferenceUnmarshaller.java:55) at com.thoughtworks.xstream.core.TreeUnmarshaller.convertAnother(TreeUnmarshaller.java:75) at com.thoughtworks.xstream.core.TreeUnmarshaller.convertAnother(TreeUnmarshaller.java:59) at com.thoughtworks.xstream.core.TreeUnmarshaller.start(TreeUnmarshaller.java:142) at com.thoughtworks.xstream.core.AbstractTreeMarshallingStrategy.unmarshal(AbstractTreeMarshallingStrategy.java:33) at com.thoughtworks.xstream.XStream.unmarshal(XStream.java:907) at com.thoughtworks.xstream.XStream.unmarshal(XStream.java:893) at com.thoughtworks.xstream.XStream.fromXML(XStream.java:845) at org.dementhium.io.XMLHandler.fromXML(XMLHandler.java:57) at org.dementhium.content.areas.AreaManager.<init>(AreaManager.java:21) at org.dementhium.model.World.load(World.java:115) at org.dementhium.RS2ServerBootstrap.main(RS2ServerBootstrap.java:42) Caused by: com.thoughtworks.xstream.converters.reflection.ObjectAccessException: Cannot construct org.dementhium.content.areas.impl.CircularArea as it does not have a no-args constructor at com.thoughtworks.xstream.converters.reflection.PureJavaReflectionProvider.newInstance(PureJavaReflectionProvider.java:71) at com.thoughtworks.xstream.converters.reflection.AbstractReflectionConverter.instantiateNewInstance(AbstractReflectionConverter.java:279) at com.thoughtworks.xstream.converters.reflection.AbstractReflectionConverter.unmarshal(AbstractReflectionConverter.java:149) at com.thoughtworks.xstream.core.TreeUnmarshaller.convert(TreeUnmarshaller.java:81) ... 19 more Exception in thread "main" java.lang.NullPointerException at org.dementhium.content.areas.AreaManager.<init>(AreaManager.java:25) at org.dementhium.model.World.load(World.java:115) at org.dementhium.RS2ServerBootstrap.main(RS2ServerBootstrap.java:42) [/code] I'm not quite sure what to do!
  20. Well, I recently downloaded a server to try out and play, but when I open the run.bat, this error comes up [img]http://i.imgur.com/lIwvSUy.png[/img] There is an EGUI.class file in the folder, if that helps. This is what my run.bat looks like when I edit it: [img]http://img46.imageshack.us/img46/6011/g1xj.png[/img] I really know nothing about this stuff, so as much detail as possible is appreciated :) It's an Allstarscape source too
  21. I didn't mean to click the box that made notepad the default .class file opener. Now my .class files won't work. I'm unable to run clients anymore due to this. Is there any way I can reset them to files without default programs? Is there a program that I could use as the default program?
  22. Hey, I have this hunter file but nothing in there works. Its only made to hunt implings. Credits to cloudin [code] package com.rs2hd.content.skills.hunter; import com.rs2hd.event.Event; import com.rs2hd.model.NPC; import com.rs2hd.model.Player; import com.rs2hd.model.World; import com.rs2hd.packethandler.NpcPacketHandler; /* *Credits to CloudIn */ public class Hunter { private final Player p; public int trapId = -1; public Hunter(final Player p) { this.p = p; } public boolean isImp(final NPC n) { switch(n.getId()) { case 6055: return true; case 6056: return true; case 6057: return true; case 6058: return true; case 6059: return true; case 6061: return true; case 6062: return true; case 6063: return true; case 6064: return true; case 7845: return true; case 7846: return true; } return false; } public void catchImp(final NPC n) { try { if(!(p.getEquipment().get(3).getId() == 11259)) { p.getActionSender().sendMessage("You need a net equipped to catch imps!"); return; } } finally { p.getActionSender().sendMessage("You need a net equipped to catch imps!"); } switch(n.getId()) { case 1028://baby impling case 6055://Baby impling if(!p.isAnimating()) { p.turnTo(n); p.animate(5209); World.getInstance().registerEvent(new Event(500) { [MENTION=15855]Over[/MENTION]ride public void execute() { if(!n.isDead()) { n.setDead(true); n.setHidden(true); //n.delete(n); p.getActionSender().sendMessage("You catch the baby impling!"); p.getInventory().addItem(11238, 1); p.getSkills().addXp(21, 5550); } } }); } break; case 1029://Young impling case 6056://Young impling if (p.getSkills().getLevelForXp(21) < 22){ p.getActionSender().sendMessage("You need a Hunter Level of 22 to Catch this Impling"); return; } if(!p.isAnimating()) { p.turnTo(n); p.animate(5209); World.getInstance().registerEvent(new Event(500) { [MENTION=15855]Over[/MENTION]ride public void execute() { if(!n.isDead()) { n.setDead(true); n.setHidden(true); //n.delete(n); p.getActionSender().sendMessage("You catch the Young impling!"); p.getInventory().addItem(11240, 1); p.getSkills().addXp(21, 1500); } } }); } break; case 1030://Gourmet impling case 6057://Gourmet impling if (p.getSkills().getLevelForXp(21) < 28){ p.getActionSender().sendMessage("You need a Hunter Level of 28 to Catch this Impling"); return; } if(!p.isAnimating()) { p.turnTo(n); p.animate(5209); World.getInstance().registerEvent(new Event(500) { [MENTION=15855]Over[/MENTION]ride public void execute() { if(!n.isDead()) { n.setDead(true); n.setHidden(true); //n.delete(n); p.getActionSender().sendMessage("You catch the Gourmet impling!"); p.getInventory().addItem(11242, 1); p.getSkills().addXp(21, 2100); } } }); } break; case 1031://Earth impling case 6058://Earth impling if (p.getSkills().getLevelForXp(21) < 36){ p.getActionSender().sendMessage("You need a Hunter Level of 36 to Catch this Impling"); return; } if(!p.isAnimating()) { p.turnTo(n); p.animate(5209); World.getInstance().registerEvent(new Event(500) { [MENTION=15855]Over[/MENTION]ride public void execute() { if(!n.isDead()) { n.setDead(true); n.setHidden(true); //n.delete(n); p.getActionSender().sendMessage("You catch the Earth impling!"); p.getInventory().addItem(11244, 1); p.getSkills().addXp(21, 2500); } } }); } break; case 1032://Essence impling case 6059://Essence impling if (p.getSkills().getLevelForXp(21) < 42){ p.getActionSender().sendMessage("You need a Hunter Level of 42 to Catch this Impling"); return; } if(!p.isAnimating()) { p.turnTo(n); p.animate(5209); World.getInstance().registerEvent(new Event(500) { [MENTION=15855]Over[/MENTION]ride public void execute() { if(!n.isDead()) { n.setDead(true); n.setHidden(true); //n.delete(n); p.getActionSender().sendMessage("You catch the Essence impling!"); p.getInventory().addItem(11246, 1); p.getSkills().addXp(21, 5602); } } }); } break; case 1033://Eclectic impling case 6060://Eclectic impling if (p.getSkills().getLevelForXp(21) < 50){ p.getActionSender().sendMessage("You need a Hunter Level of 50 to Catch this Impling"); return; } if(!p.isAnimating()) { p.turnTo(n); p.animate(5209); World.getInstance().registerEvent(new Event(500) { [MENTION=15855]Over[/MENTION]ride public void execute() { if(!n.isDead()) { n.setDead(true); n.setHidden(true); //n.delete(n); p.getActionSender().sendMessage("You catch the Eclectic impling!"); p.getInventory().addItem(11248, 1); p.getSkills().addXp(21, 7503); } } }); } break; case 1034://Nature impling case 6061://Nature impling if (p.getSkills().getLevelForXp(21) < 58){ p.getActionSender().sendMessage("You need a Hunter Level of 58 to Catch this Impling"); return; } if(!p.isAnimating()) { p.turnTo(n); p.animate(5209); World.getInstance().registerEvent(new Event(500) { [MENTION=15855]Over[/MENTION]ride public void execute() { if(!n.isDead()) { n.setDead(true); n.setHidden(true); //n.delete(n); p.getActionSender().sendMessage("You catch the Nature impling!"); p.getInventory().addItem(11250, 1); p.getSkills().addXp(21, 15583); } } }); } break; case 1035://Magpie impling case 6062://Magpie impling if (p.getSkills().getLevelForXp(21) < 65){ p.getActionSender().sendMessage("You need a Hunter Level of 65 to Catch this Impling"); return; } if(!p.isAnimating()) { p.turnTo(n); p.animate(5209); World.getInstance().registerEvent(new Event(500) { [MENTION=15855]Over[/MENTION]ride public void execute() { if(!n.isDead()) { n.setDead(true); n.setHidden(true); //n.delete(n); p.getActionSender().sendMessage("You catch the Magpie impling!"); p.getInventory().addItem(11252, 1); p.getSkills().addXp(21, 26084); } } }); } break; case 6063://Ninja impling if (p.getSkills().getLevelForXp(21) < 74){ p.getActionSender().sendMessage("You need a Hunter Level of 74 to Catch this Impling"); return; } if(!p.isAnimating()) { p.turnTo(n); p.animate(5209); World.getInstance().registerEvent(new Event(500) { [MENTION=15855]Over[/MENTION]ride public void execute() { if(!n.isDead()) { n.setDead(true); n.setHidden(true); //n.delete(n); p.getActionSender().sendMessage("You catch the Ninja impling!"); p.getInventory().addItem(11254, 1); p.getSkills().addXp(21, 56159); } } }); } break; case 7845://Pirate impling case 7846://Pirate impling if (p.getSkills().getLevelForXp(21) < 76){ p.getActionSender().sendMessage("You need a Hunter Level of 76 to Catch this Impling"); return; } if(!p.isAnimating()) { p.turnTo(n); p.animate(5209); World.getInstance().registerEvent(new Event(500) { [MENTION=15855]Over[/MENTION]ride public void execute() { if(!n.isDead()) { n.setDead(true); n.setHidden(true); //n.delete(n); p.getActionSender().sendMessage("You catch the Pirate impling!"); p.getInventory().addItem(11254, 1); p.getSkills().addXp(21, 61053); } } }); } break; case 6064://Dragon impling if (p.getSkills().getLevelForXp(21) < 83){ p.getActionSender().sendMessage("You need a Hunter Level of 83 to Catch this Impling"); return; } else if(!p.isAnimating()) { p.turnTo(n); p.animate(5209); World.getInstance().registerEvent(new Event(500) { [MENTION=15855]Over[/MENTION]ride public void execute() { if(!n.isDead()) { n.setDead(true); n.setHidden(true); //n.delete(n); p.getActionSender().sendMessage("You catch the Dragon impling!"); p.getInventory().addItem(11256, 1); p.getSkills().addXp(21, 76582); } } }); } break; } } public static int giveItems[] = { 4151,4153 }; public static int giveItem(){ return giveItems[(int)(Math.random() * (double)giveItems.length)]; } } [/code] When ever I click on a npc, nothing happens, how do I fix that? Also does anyone have the emote to catch imps? 5209 is a glitchy emote
  23. i want to ask how to add items like chaotic and the other items for pking and they you cant use them in class8 i want to ask in which class i want to put them?.lolking
  24. the title says it all, when i get load up the download client i get the message: could not find main class: server.server any help greatly appreciated :)
×