Jump to content

jefersonpang

Member
  • Content count

    28
  • Joined

  • Last visited

About jefersonpang

  • Rank
    Bronze Member
  1. ok so far ive made it when you use a gold bar with furnace it brings up interface 446 which is:[ATTACH=CONFIG]10164[/ATTACH]now it recognizes the mould and gem and bar(i know i messed up with necklace and ammy) but now im at a standstill and just overwhelmed and cant figure out how to make the make 1,make 5..ect.. and actually delete bar and gem and add ring to inv. i know its something in buttonhandler but im not sure how to connect my jewellerycrafting.java file to buttonhandler and get the items. heres what ive got.[QUOTE]package com.rs.game.player.actions; import com.rs.cache.loaders.ItemDefinitions; import com.rs.game.Animation; import com.rs.game.item.Item; import com.rs.game.player.Player; import com.rs.game.player.Skills; /** * @author Kova+ (Alex) * */ public class JewerlyCrafting extends Action { private static int[] GEMS = { 0, 1607, 1605, 1603, 1601, 1615, 6573 }; private static int[] RINGS = { 1635, 2550, 2552, 2568, 2570, 2572, 6583 }; private static int[] BRACELETS = { 11069, 11074, 11079, 11088, 11095, 11118, 11133 }; private static int[] NECKLACES = { 1654, 3853, 5521, 11194, 11090, 11105, 11128 }; private static int[] AMULETS = { 1673, 1675, 1677, 1679, 1681, 1683, 6579 }; private static int[] RING_COMPONENTS = { 81, 83, 85, 87, 89, 91, 93, 96 }; private static int[] NECKLACE_COMPONENTS = { 67, 69, 71, 73, 75, 77, 79 }; private static int[] AMULET_COMPONENTS = { 52, 54, 56, 58, 60, 62, 64 }; private static int[] BRACELET_COMPONENTS = { 32, 34, 36, 38, 40, 42, 44 }; private static int[] MOULDS = { 1592, 1595, 1597, 11065 }; private static int NO_RING = 1647, NO_NECKLACE = 1666, NO_AMULET = 1685, NO_BRACELET = 11067, GOLD_BAR = 2357; public static void sendInterface(Player player) { player.getInterfaceManager().sendInterface(446); if (player.getInventory().containsItem(MOULDS[0], 1)) { for (int i = 0; i < RING_COMPONENTS.length; i++) { player.getPackets().sendItemOnIComponent(446, RING_COMPONENTS[i], NO_RING, 1); player.getPackets().sendIComponentText(446, 98, ""); } for (int i = 0; i < GEMS.length; i++) { if (player.getInventory().containsItem(GOLD_BAR, 1) && player.getInventory().containsItem(GEMS[i], 1)) { player.getPackets().sendItemOnIComponent(446, RING_COMPONENTS[i], RINGS[i], 1); } } if (player.getInventory().containsItem(MOULDS[0], 1) && player.getInventory().containsItem(GOLD_BAR, 1)) { player.getPackets().sendItemOnIComponent(446, RING_COMPONENTS[0], RINGS[0], 1); } } if (player.getInventory().containsItem(MOULDS[1], 1)) { for (int i = 0; i < NECKLACE_COMPONENTS.length; i++) { player.getPackets().sendItemOnIComponent(446, NECKLACE_COMPONENTS[i], NO_NECKLACE, 1); player.getPackets().sendIComponentText(446, 22, ""); } for (int i = 0; i < GEMS.length; i++) { if (player.getInventory().containsItem(GOLD_BAR, 1) && player.getInventory().containsItem(GEMS[i], 1)) { player.getPackets().sendItemOnIComponent(446, NECKLACE_COMPONENTS[i], NECKLACES[i], 1); } } if (player.getInventory().containsItem(MOULDS[1], 1) && player.getInventory().containsItem(GOLD_BAR, 1)) { player.getPackets().sendItemOnIComponent(446, NECKLACE_COMPONENTS[0], NECKLACES[0], 1); } } if (player.getInventory().containsItem(MOULDS[2], 1)) { for (int i = 0; i < AMULET_COMPONENTS.length; i++) { player.getPackets().sendItemOnIComponent(446, AMULET_COMPONENTS[i], NO_AMULET, 1); player.getPackets().sendIComponentText(446, 66, ""); } for (int i = 0; i < GEMS.length; i++) { if (player.getInventory().containsItem(GOLD_BAR, 1) && player.getInventory().containsItem(GEMS[i], 1)) { player.getPackets().sendItemOnIComponent(446, AMULET_COMPONENTS[i], AMULETS[i], 1); } } if (player.getInventory().containsItem(MOULDS[2], 1) && player.getInventory().containsItem(GOLD_BAR, 1)) { player.getPackets().sendItemOnIComponent(446, AMULET_COMPONENTS[0], AMULETS[0], 1); } } if (player.getInventory().containsItem(MOULDS[3], 1)) { for (int i = 0; i < BRACELET_COMPONENTS.length; i++) { player.getPackets().sendItemOnIComponent(446, BRACELET_COMPONENTS[i], NO_BRACELET, 1); player.getPackets().sendIComponentText(446, 51, ""); } for (int i = 0; i < GEMS.length; i++) { if (player.getInventory().containsItem(GOLD_BAR, 1) && player.getInventory().containsItem(GEMS[i], 1)) { player.getPackets().sendItemOnIComponent(446, BRACELET_COMPONENTS[i], BRACELETS[i], 1); } } if (player.getInventory().containsItem(MOULDS[3], 1) && player.getInventory().containsItem(GOLD_BAR, 1)) { player.getPackets().sendItemOnIComponent(446, BRACELET_COMPONENTS[0], BRACELETS[0], 1); } } } public enum JewerlyData { GOLD_RING(5, 15, 1635), SAPPHIRE_RING(20, 40, 2550), EMERALD_RING(27, 55, 2552), RUBY_RING(34, 70, 2568), DIAMOND_RING(43, 85, 2570), DRAGONSTONE_RING(55, 100, 2572), ONYX_RING(67, 115, 6583), GOLD_NECKLACE(6, 20, 1654), SAPPHIRE_NECKLACE(22, 55, 3853), EMERALD_NECKLACE(29, 60, 5521), RUBY_NECKLACE(40, 75, 11194), DIAMOND_NECKLACE(56, 90, 11090), DRAGONSTONE_NECKLACE(72, 105, 11105), ONYX_NECKLACE(82, 120, 11128), GOLD_BRACELET(7, 25, 11069), SAPPHIRE_BRACELET( 23, 60, 11074), EMERALD_BRACELET(30, 65, 11079), RUBY_BRACELET(42, 80, 11088), DIAMOND_BRACELET(58, 95, 11095), DRAGONSTONE_BRACELET(74, 110, 11118), ONYX_BRACELET(84, 125, 11133), GOLD_AMULET(8, 30, 1673), SAPPHIRE_AMULET(24, 65, 1675), EMERALD_AMULET(31, 70, 1677), RUBY_AMULET(50, 85, 1679), DIAMOND_AMULET(70, 100, 1681), DRAGONSTONE_AMULET(80, 150, 1683), ONYX_AMULET(90, 165, 6579); private int level, outcome; private double xp; private JewerlyData(int levelNeeded, double xp, int outcome) { this.level = levelNeeded; this.xp = xp; this.outcome = outcome; } private int getLevel() { return level; } private int getOutcome() { return outcome; } private double getXp() { return xp; } } private int amount; private Item gold, gem; private JewerlyData data; public JewerlyCrafting(JewerlyData data, Item gold, Item gem, int amount) { this.data = data; this.gold = gold; this.gem = gem; this.amount = amount; } @Override public boolean start(Player player) { if (checkAll(player)) { setActionDelay(player, 1); return true; } return false; } public boolean checkAll(Player player) { if (player.getSkills().getLevel(Skills.CRAFTING) < data .getLevel()) { player.getDialogueManager().startDialogue( "SimpleMessage", "You need a crafting level of " + data.getLevel() + " to create that."); return false; } if (!player.getInventory().containsItem(gold.getId(), 1)) { player.getDialogueManager().startDialogue( "SimpleMessage", "You don't have any more " + ItemDefinitions .getItemDefinitions(gold.getId()) .getName().toLowerCase() + "s to use."); return false; } if (!player.getInventory().containsItem(gem.getId(), 1)) { if (gem.getId() == -1) { return true; } player.getDialogueManager().startDialogue( "SimpleMessage", "You don't have any more " + ItemDefinitions .getItemDefinitions(gem.getId()) .getName().toLowerCase() + "s to use."); return false; } return true; } @Override public boolean process(Player player) { return checkAll(player); } @Override public int processWithDelay(Player player) { if (gem.getId() == -1) { player.getInventory().deleteItem(gold.getId(), 1); player.getInventory().addItem(data.getOutcome(), 1); player.getSkills().addXp(Skills.CRAFTING, data.getXp()); player.getPackets().sendGameMessage( "You shape the gold bar with the mould to make " + ItemDefinitions.getItemDefinitions(data.getOutcome()) .getName().toLowerCase() + ".", true); } else { player.getInventory().deleteItem(gold.getId(), 1); player.getInventory().deleteItem(gem.getId(), 1); player.getInventory().addItem(data.getOutcome(), 1); player.getSkills().addXp(Skills.CRAFTING, data.getXp()); player.getPackets().sendGameMessage( "You bind the Gold bar and the " + ItemDefinitions.getItemDefinitions(gem.getId()) .getName().toLowerCase() + " together to make a " + ItemDefinitions.getItemDefinitions(data.getOutcome()) .getName().toLowerCase() + ".", true); } amount--; if (amount <= 0) return -1; player.setNextAnimation(new Animation(3243)); return 0; } @Override public void stop(final Player player) { setActionDelay(player, 3); } }[/QUOTE]and this is how i set it up in objecthandler[QUOTE] if (itemId == 2357 && object.getId() == 11010) { JewerlyCrafting.sendInterface(player);[/QUOTE]if someone could help me that would be just fantastic. thanks!
  2. [img]http://d2bm3ljpacyxu8.cloudfront.net/width/709/crop/0,0,709x203/aztarkingdom.webs.com/FULL_LOGO.jpg[/img] [u]Base[/u]: Rune-evo [u]Creds[/u]: alot of moparscape community and alot of google community. alot of credit to myself for hours and hours and months of coding. HOME [img]http://d2bm3ljpacyxu8.cloudfront.net/width/724/crop/0,0,724x381/aztarkingdom.webs.com/home-1.jpg[/img] New Starters and their Starting locations. [img]http://d2bm3ljpacyxu8.cloudfront.net/width/935/crop/0,0,935x570/aztarkingdom.webs.com/starter.jpg[/img] Working on every full dungeon, ladder, and door. More explorable places for hours of gameplay. [img]http://d2bm3ljpacyxu8.cloudfront.net/width/935/crop/0,0,935x719/aztarkingdom.webs.com/qbd.jpg[/img] there really is alot of content in this. for example I made every fish able to be fished with the right eq, bait, level, and spot. I made full polypore dungeon. Not to mention countless random dungeons everywhere. Most of them with a little hidden suprise somewhere in it. I have worked alot on pvp. Im currently working on a whole new badass pvp battle ground. There is alot more but the best way is to just experience it yourself. Enjoy. (p.s. im not sure if im going to do donators or not so everything should always be free to play. just saying.) [U][FONT=Arial Black][COLOR="#FF0000"]LINKS[/COLOR][/FONT][/U] webiste - [url]http://aztarkingdom.webs.com/742[/url] download - [url]http://www.mediafire.com/download/6qadby948kdl14y/aztar_Kingdom_Client.jar[/url] YOUTUBE - [url]http://www.youtube.com/watch?v=mlapi1hbxI8[/url]
  3. *sigh* if i had people to help i sure as hell wouldnt be posting asking for help. i have literally posted on 3 sites hoping that one person would help. every single one says lower revision, portforward and every other possible obvious as fuck thing to say except actually help. but thanks for telling me.
  4. Hello. i am trying to put my server online for the first time. just really seeing if someone can connect to my server and everything. heres the link [url]http://www.mediafire.com/?kums1gu3ghw9ol3[/url] thanks :)
  5. btw i would really appreciate if there was one helpful person on rL cuz there isnt any on mop
  6. ok so i have my server online and it works on my computer. i gave it to a friend and he has been able to connect to my server but most of the time it gives the js5connect error. if someone knows how to fix this that would be awesome. actually been trying to fix this for a while now. just want people to be able to play my server. i found this by the way: [url]http://services.runescape.com/m=forum/forums.ws?25,26,700,63996042,&showuser=Mod%A0Bro[/url] and maybe this is the problem. if so i have no idea how to fix it. thanks -Jefersonpang
  7. [quote name='diox788']Error connecting..[/QUOTE] check your messages fool
  8. [quote name='diox788']Ok, sorry for the inconvenience, Its just being funky.[/QUOTE] [url]http://uppit.com/ntoyevreyoa8/AK.zip[/url]
  9. [quote name='Scientist']wat[/QUOTE] lol go to the website and youll see. *edit* there fixed it.
×