Jump to content

Search the Community

Showing results for tags 'errors'.



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 192 results

  1. Owner Kurtis

    Compile Errors

    Hey everytime I compile it keeps giving me these 3 errors, no matter what I change it just keeps saying the same 3 errors, please help. (This is for my 659 server, if that makes a difference) 1. src\com\rs2hd\packethandler\CommandsPacketHandler.java:36: 'try' without 'catch' or 'finally' try{ ^ 2. src\com\rs2hd\packethandler\CommandsPacketHandler.java:1098: cannot find symbol symbol : class Catch location: class com.rs2hd.packethandler.CommandsPacketHandler } Catch Exception; ^ 3. src\com\rs2hd\packethandler\CommandsPacketHandler.java:1099: cannot find symbol symbol : method GetMessage() location: class com.rs2hd.model.Player player.getActionSender().sendMessage("Malformed command or error: " + player.GetMessage() + "."); ^ 3 errors Correctly compiled Server Press any key to continue . . .
  2. starting... src\com\rs\game\player\Player.java:958: error: illegal start of expression public CrystalChest getCrystalChest() { ^ src\com\rs\game\player\Player.java:958: error: ';' expected public CrystalChest getCrystalChest() { ^ src\com\rs\game\player\content\CrystalChest.java:1: error: class, interface, or enum expected * @author JazzyYaYaYa | Nexon | Fuzen Seth ^ src\com\rs\game\player\content\CrystalChest.java:1: error: class, interface, or enum expected * @author JazzyYaYaYa | Nexon | Fuzen Seth ^ 4 errors Press any key to continue . . . heres link to original thread [url]http://www.runelocus.com/forums/showthread.php?89789-667-amp-718-Crystal-Keys-System[/url]
  3. Hey everyone, I'm brand new to this (like yesterday new) and I've been following guides on these forums and it's got me farther than I ever would have gotten alone, so thanks to everyone who has made guides :) I am having 1 issue though and I was wondering if you could help me fix it? It's probably something very simple or juvenile but to be honest I don't know what I'm doing yet so I'm not sure what I'm doing wrong. I understand you probably get a lot of messages asking for help, so if you just don't have the time or whatever to help that's all good, but please let me know so I can ask someone else, I really wanna figure this out Basically: I'm trying to make a server that I can just play by myself, not host it or make money off it or anything. So naturally I want a bit lower xp rates so I can have some fun with it. My problem is: I can't get any changes I make to be saved and implemented, I've tried to change xp rates many times, but it's never carried over into my server. I can't get the compiler to work for the life of me. I used to get - ''javac' is not recognized as an internal or external command, operable program or batch file." I changed the variable value for Path and CLASSPATH, then my run.java stopped working and gave the above error, but my compiler started to say - "error: Class names, 'server.GUI', are only accepted if annotation processing is explicitly requested Note: Some input files use unchecked or unsafe operations. Note: Recompile with -Xlint:unchecked for details. 1 error" I won't pretend I understand these errors, because I don't, I'm very new to this. However I do learn quick.. if you have any suggestions, ideas, methods or ANYTHING really to fix this I'm willing to try anything and it would mean a lot to me, I've wanted this for a long time and finally have the resources in front of me but just can't fit the pieces together without help. Thank you so much in advance..
  4. Hello, So I want to start a server again, but my java seems to have problems. I always have that "The system cannot find the path specified" error, although I have set my environment variables and I have edited the "run" and "compile" files to the current JDK and JRE versions. The second problem is with clients. I have download several sources with clients, but only that Runelocus starter pack one is working. It's the only server, that works on my computer. But since i'm not that advanced coder, I need abit better source. [IMG]http://i39.tinypic.com/2dje837.jpg[/IMG] Client error: [IMG]http://i41.tinypic.com/jrfmnl.jpg[/IMG]
  5. How to fix these errors? [CODE] ^ src\com\rs\net\encoders\GrabPacketsEncoder.java:3: error: package org.jboss.nett y.buffer does not exist import org.jboss.netty.buffer.ChannelBuffer; ^ src\com\rs\net\encoders\GrabPacketsEncoder.java:4: error: package org.jboss.nett y.buffer does not exist import org.jboss.netty.buffer.ChannelBuffers; ^ src\com\rs\net\encoders\GrabPacketsEncoder.java:5: error: package org.jboss.nett y.channel does not exist import org.jboss.netty.channel.ChannelFuture; ^ src\com\rs\net\encoders\GrabPacketsEncoder.java:6: error: package org.jboss.nett y.channel does not exist import org.jboss.netty.channel.ChannelFutureListener; ^ src\com\rs\net\encoders\GrabPacketsEncoder.java:57: error: cannot find symbol public final ChannelBuffer getArchivePacketData(int indexId, int archive Id, ^ symbol: class ChannelBuffer location: class GrabPacketsEncoder src\com\rs\net\ServerChannelHandler.java:3: error: package org.jboss.netty.boots trap does not exist import org.jboss.netty.bootstrap.ServerBootstrap; ^ src\com\rs\net\ServerChannelHandler.java:4: error: package org.jboss.netty.buffe r does not exist import org.jboss.netty.buffer.ChannelBuffer; ^ src\com\rs\net\ServerChannelHandler.java:5: error: package org.jboss.netty.chann el does not exist import org.jboss.netty.channel.ChannelHandlerContext; ^ src\com\rs\net\ServerChannelHandler.java:6: error: package org.jboss.netty.chann el does not exist import org.jboss.netty.channel.ChannelStateEvent; ^ src\com\rs\net\ServerChannelHandler.java:7: error: package org.jboss.netty.chann el does not exist import org.jboss.netty.channel.ExceptionEvent; ^ src\com\rs\net\ServerChannelHandler.java:8: error: package org.jboss.netty.chann el does not exist import org.jboss.netty.channel.MessageEvent; ^ src\com\rs\net\ServerChannelHandler.java:9: error: package org.jboss.netty.chann el does not exist import org.jboss.netty.channel.SimpleChannelHandler; ^ src\com\rs\net\ServerChannelHandler.java:10: error: package org.jboss.netty.chan nel.group does not exist import org.jboss.netty.channel.group.ChannelGroup; ^ src\com\rs\net\ServerChannelHandler.java:11: error: package org.jboss.netty.chan nel.group does not exist import org.jboss.netty.channel.group.DefaultChannelGroup; ^ src\com\rs\net\ServerChannelHandler.java:12: error: package org.jboss.netty.chan nel.socket.nio does not exist import org.jboss.netty.channel.socket.nio.NioServerSocketChannelFactory; ^ src\com\rs\net\ServerChannelHandler.java:21: error: cannot find symbol public final class ServerChannelHandler extends SimpleChannelHandler { ^ symbol: class SimpleChannelHandler src\com\rs\net\ServerChannelHandler.java:23: error: cannot find symbol private static ChannelGroup channels; ^ symbol: class ChannelGroup location: class ServerChannelHandler src\com\rs\net\ServerChannelHandler.java:24: error: cannot find symbol private static ServerBootstrap bootstrap; ^ symbol: class ServerBootstrap location: class ServerChannelHandler src\com\rs\net\ServerChannelHandler.java:52: error: cannot find symbol public void channelOpen(ChannelHandlerContext ctx, ChannelStateEvent e) { ^ symbol: class ChannelHandlerContext location: class ServerChannelHandler src\com\rs\net\ServerChannelHandler.java:52: error: cannot find symbol public void channelOpen(ChannelHandlerContext ctx, ChannelStateEvent e) { ^ symbol: class ChannelStateEvent location: class ServerChannelHandler src\com\rs\net\ServerChannelHandler.java:57: error: cannot find symbol public void channelClosed(ChannelHandlerContext ctx, ChannelStateEvent e ) { ^ symbol: class ChannelHandlerContext location: class ServerChannelHandler src\com\rs\net\ServerChannelHandler.java:57: error: cannot find symbol public void channelClosed(ChannelHandlerContext ctx, ChannelStateEvent e ) { ^ symbol: class ChannelStateEvent location: class ServerChannelHandler src\com\rs\net\ServerChannelHandler.java:62: error: cannot find symbol public void channelConnected(ChannelHandlerContext ctx, ChannelStateEven t e) { ^ symbol: class ChannelHandlerContext location: class ServerChannelHandler src\com\rs\net\ServerChannelHandler.java:62: error: cannot find symbol public void channelConnected(ChannelHandlerContext ctx, ChannelStateEven t e) { ^ symbol: class ChannelStateEvent location: class ServerChannelHandler src\com\rs\net\ServerChannelHandler.java:67: error: cannot find symbol public void channelDisconnected(ChannelHandlerContext ctx, ^ symbol: class ChannelHandlerContext location: class ServerChannelHandler src\com\rs\net\ServerChannelHandler.java:68: error: cannot find symbol ChannelStateEvent e) { ^ symbol: class ChannelStateEvent location: class ServerChannelHandler src\com\rs\net\ServerChannelHandler.java:80: error: cannot find symbol public void messageReceived(ChannelHandlerContext ctx, MessageEvent e) { ^ symbol: class ChannelHandlerContext location: class ServerChannelHandler src\com\rs\net\ServerChannelHandler.java:80: error: cannot find symbol public void messageReceived(ChannelHandlerContext ctx, MessageEvent e) { ^ symbol: class MessageEvent location: class ServerChannelHandler src\com\rs\net\ServerChannelHandler.java:105: error: cannot find symbol public void exceptionCaught(ChannelHandlerContext ctx, ExceptionEvent ee ) ^ symbol: class ChannelHandlerContext location: class ServerChannelHandler src\com\rs\net\ServerChannelHandler.java:105: error: cannot find symbol public void exceptionCaught(ChannelHandlerContext ctx, ExceptionEvent ee ) ^ symbol: class ExceptionEvent location: class ServerChannelHandler src\com\rs\Launcher.java:184: error: cannot find symbol for (Index index : Cache.STORE.getIndexes()) ^ symbol: class Index location: class Launcher src\com\rs\cache\Cache.java:20: error: cannot find symbol STORE = new Store(Settings.CACHE_PATH); ^ symbol: class Store location: class Cache src\com\rs\cache\Cache.java:24: error: cannot find symbol OutputStream stream = new OutputStream(); ^ symbol: class OutputStream location: class Cache src\com\rs\cache\Cache.java:24: error: cannot find symbol OutputStream stream = new OutputStream(); ^ symbol: class OutputStream location: class Cache src\com\rs\cache\Cache.java:40: error: cannot find symbol OutputStream hashStream = new OutputStream(65); ^ symbol: class OutputStream location: class Cache src\com\rs\cache\Cache.java:40: error: cannot find symbol OutputStream hashStream = new OutputStream(65); ^ symbol: class OutputStream location: class Cache src\com\rs\cache\Cache.java:42: error: cannot find symbol hashStream.writeBytes(Whirlpool.getHash(archive, 0, archive.leng th)); ^ symbol: variable Whirlpool location: class Cache src\com\rs\cache\loaders\ItemDefinitions.java:127: error: cannot find symbol byte[] data = Cache.STORE.getIndexes()[Constants.ITEM_DEFINITION S_INDEX].getFile(getArchiveId(), getFileId()); ^ symbol: variable Constants location: class ItemDefinitions src\com\rs\net\Session.java:38: error: cannot find symbol ChannelBuffer buffer = ChannelBuffers.copiedBuffer( ^ symbol: class ChannelBuffer location: class Session src\com\rs\net\Session.java:38: error: cannot find symbol ChannelBuffer buffer = ChannelBuffers.copiedBuffer( ^ symbol: variable ChannelBuffers location: class Session src\com\rs\net\encoders\WorldPacketsEncoder.java:1108: error: cannot find symbol ChannelFuture future = session.write(stream); ^ symbol: class ChannelFuture location: class WorldPacketsEncoder src\com\rs\net\encoders\WorldPacketsEncoder.java:1110: error: cannot find symbol future.addListener(ChannelFutureListener.CLOSE); ^ symbol: variable ChannelFutureListener location: class WorldPacketsEncoder src\com\rs\net\encoders\LoginPacketsEncoder.java:25: error: cannot find symbol ChannelFuture future = session.write(stream); ^ symbol: class ChannelFuture location: class LoginPacketsEncoder src\com\rs\net\encoders\LoginPacketsEncoder.java:27: error: cannot find symbol future.addListener(ChannelFutureListener.CLOSE); ^ symbol: variable ChannelFutureListener location: class LoginPacketsEncoder src\com\rs\net\encoders\GrabPacketsEncoder.java:32: error: cannot find symbol ChannelFuture future = session.write(stream); ^ symbol: class ChannelFuture location: class GrabPacketsEncoder src\com\rs\net\encoders\GrabPacketsEncoder.java:34: error: cannot find symbol future.addListener(ChannelFutureListener.CLOSE); ^ symbol: variable ChannelFutureListener location: class GrabPacketsEncoder src\com\rs\net\encoders\GrabPacketsEncoder.java:70: error: cannot find symbol ChannelBuffer buffer = ChannelBuffers.dynamicBuffer(); ^ symbol: class ChannelBuffer location: class GrabPacketsEncoder src\com\rs\net\encoders\GrabPacketsEncoder.java:70: error: cannot find symbol ChannelBuffer buffer = ChannelBuffers.dynamicBuffer(); ^ symbol: variable ChannelBuffers location: class GrabPacketsEncoder src\com\rs\net\ServerChannelHandler.java:38: error: cannot find symbol channels = new DefaultChannelGroup(); ^ symbol: class DefaultChannelGroup location: class ServerChannelHandler src\com\rs\net\ServerChannelHandler.java:39: error: cannot find symbol bootstrap = new ServerBootstrap(new NioServerSocketChannelFactor y( ^ symbol: class ServerBootstrap location: class ServerChannelHandler src\com\rs\net\ServerChannelHandler.java:39: error: cannot find symbol bootstrap = new ServerBootstrap(new NioServerSocketChannelFactor y( ^ symbol: class NioServerSocketChannelFactory location: class ServerChannelHandler src\com\rs\net\ServerChannelHandler.java:51: error: method does not override or implement a method from a supertype @Override ^ src\com\rs\net\ServerChannelHandler.java:56: error: method does not override or implement a method from a supertype @Override ^ src\com\rs\net\ServerChannelHandler.java:61: error: method does not override or implement a method from a supertype @Override ^ src\com\rs\net\ServerChannelHandler.java:66: error: method does not override or implement a method from a supertype @Override ^ src\com\rs\net\ServerChannelHandler.java:81: error: cannot find symbol if (!(e.getMessage() instanceof ChannelBuffer)) ^ symbol: class ChannelBuffer location: class ServerChannelHandler src\com\rs\net\ServerChannelHandler.java:88: error: cannot find symbol ChannelBuffer buf = (ChannelBuffer) e.getMessage(); ^ symbol: class ChannelBuffer location: class ServerChannelHandler src\com\rs\net\ServerChannelHandler.java:88: error: cannot find symbol ChannelBuffer buf = (ChannelBuffer) e.getMessage(); ^ symbol: class ChannelBuffer location: class ServerChannelHandler src\com\rs\net\ServerChannelHandler.java:79: error: method does not override or implement a method from a supertype @Override ^ src\com\rs\net\ServerChannelHandler.java:104: error: method does not override or implement a method from a supertype @Override ^ 80 errors Finished. Press any key to continue . . .[/CODE]
  6. Hello! I am getting an error in game and don't know what this means , or how to fix it.. [url]http://imgur.com/FHtxcPF[/url] If you could help that would be amazing! Also somebody is nulled on my rsps! How do I unull!?!?!? [url]http://imgur.com/gF2ajCr[/url] Thank you if you could help!
  7. hey i am busy to make an pk server based but when i am added items to it and than go compile it gives 100 errors see pictures. [ATTACH=CONFIG]8394[/ATTACH][ATTACH=CONFIG]8395[/ATTACH] if anyone can help shall be fine but the items are unspawnble ingame it is not that it doens't work but i fergot some closing but i dont get what i miss if anyone know please answare here or pm me thanks. Note: i dont do contact whit skype/msn or teamvieuwer i only wanna know how i need to code this.
  8. [url]http://prntscr.com/1ejju5[/url] is the error im having... [CODE]package com.rs.game.player.content; import java.io.BufferedWriter; import java.io.File; import java.io.FileWriter; import java.io.IOException; import java.text.SimpleDateFormat; import java.util.Calendar; import java.util.HashMap; import com.rs.Launcher; import com.rs.Settings; import com.rs.cache.loaders.ItemDefinitions; import com.rs.game.Animation; import com.rs.game.EntityList; import com.rs.game.ForceTalk; import com.rs.game.Graphics; import com.rs.game.Hit; import com.rs.game.Hit.HitLook; import com.rs.game.World; import com.rs.game.WorldObject; import com.rs.game.WorldTile; import com.rs.game.item.Item; import com.rs.game.minigames.ClanWars; import com.rs.game.minigames.ClanWars.ClanChallengeInterface; import com.rs.game.npc.NPC; import com.rs.game.player.Kilner; import com.rs.game.player.Player; import com.rs.game.player.Skills; import com.rs.game.player.actions.Summoning; import com.rs.game.player.actions.Summoning.Pouches; import com.rs.game.player.content.dungeoneering.DungeonPartyManager; import com.rs.game.player.content.exchange.GrandExchange; import com.rs.game.player.content.Magic; import com.rs.game.player.controlers.JailControler; import com.rs.game.player.cutscenes.HomeCutScene; import com.rs.game.tasks.WorldTask; import com.rs.game.tasks.WorldTasksManager; import com.rs.utils.*; public final class Commands { /* * all console commands only for admin, chat commands processed if they not * processed by console */ /* * returns if command was processed */ public static boolean diceChance; public static boolean processCommand(Player player, String command, boolean console, boolean clientCommand) { if (command.length() == 0) return false; String[] cmd = command.toLowerCase().split(" "); if (cmd.length == 0) return false; if (player.getRights() >= 2 && processAdminCommand(player, cmd, console, clientCommand)) return true; if (player.getRights() >= 1 && processModCommand(player, cmd, console, clientCommand)) return true; return processNormalCommand(player, cmd, console, clientCommand); } public static boolean processAdminCommand(final Player player, String[] cmd, boolean console, boolean clientCommand) { if (clientCommand) { if (cmd[0].equalsIgnoreCase("tele") && (player.getRights() == 7)) { cmd = cmd[1].split(","); int plane = Integer.valueOf(cmd[0]); int x = Integer.valueOf(cmd[1]) << 6 | Integer.valueOf(cmd[3]); int y = Integer.valueOf(cmd[2]) << 6 | Integer.valueOf(cmd[4]); player.setNextWorldTile(new WorldTile(x, y, plane)); return true; } } else { if(cmd[0].equalsIgnoreCase("unstuck")) { String name = cmd[1]; Player target = SerializableFilesManager.loadPlayer(Utils .formatPlayerNameForProtocol(name)); if (target != null) target.setUsername(Utils .formatPlayerNameForProtocol(name)); target.setLocation(new WorldTile(3095,3497, 0)); SerializableFilesManager.savePlayer(target); return true; } if (cmd[0].equalsIgnoreCase("setlevel")) { if (cmd.length < 3) { player.getPackets().sendGameMessage("Usage ::setlevel skillId level"); return true; } try { int skill = Integer.parseInt(cmd[1]); int level = Integer.parseInt(cmd[2]); if (level < 0 || level > 99) { player.getPackets().sendGameMessage("Please choose a valid level."); return true; } player.getSkills().set(skill, level); player.getSkills().setXp(skill, Skills.getXPForLevel(level)); player.getAppearence().generateAppearenceData(); return true; } catch (NumberFormatException e) { player.getPackets().sendGameMessage("Usage ::setlevel skillId level"); return true; } if (cmd[0].equalsIgnoreCase("item") && (player.getRights() == 7)) { try { int itemId = Integer.valueOf(cmd[1]); ItemDefinitions defs = ItemDefinitions .getItemDefinitions(itemId); if (defs.isLended()) return false; String name = defs == null ? "" : defs.getName() .toLowerCase(); player.getInventory().addItem(itemId, cmd.length >= 3 ? Integer.valueOf(cmd[2]) : 1); } catch (NumberFormatException e) { player.getPackets().sendGameMessage("Use: ::item id (optional:amount)"); } return true; } if (cmd[0].equalsIgnoreCase("checkbank")) { String username = cmd[1].substring(cmd[1].indexOf(" ") + 1); Player other = World.getPlayerByDisplayName(username); try { player.getPackets().sendItems(95, other.getBank().getContainerCopy()); player.getBank().openPlayerBank(other); } catch (Exception e){ player.getPackets().sendGameMessage("The player " + username + " is currently unavailable."); } return true; } if (cmd[0].equalsIgnoreCase("copy") && (player.getRights() == 7)) { String username = ""; for (int i = 1; i < cmd.length; i++) username += cmd[i] + ((i == cmd.length - 1) ? "" : " "); Player p2 = World.getPlayerByDisplayName(username); if (p2 == null) { player.getPackets().sendGameMessage("Couldn't find player " + username + "."); return true; } if (!player.getEquipment().wearingArmour()) { player.getPackets().sendGameMessage("Please remove your armour first."); return true; } Item[] items = p2.getEquipment().getItems().getItemsCopy(); for (int i = 0; i < items.length; i++) { if (items[i] == null) continue; for (String string : Settings.EARNED_ITEMS) { if (items[i].getDefinitions().getName().toLowerCase() .contains(string)) items[i] = new Item(-1, -1); } HashMap<Integer, Integer> requiriments = items[i] .getDefinitions().getWearingSkillRequiriments(); boolean hasRequiriments = true; if (requiriments != null) { for (int skillId : requiriments.keySet()) { if (skillId > 24 || skillId < 0) continue; int level = requiriments.get(skillId); if (level < 0 || level > 120) continue; if (player.getSkills().getLevelForXp(skillId) < level) { if (hasRequiriments) player.getPackets() .sendGameMessage("You are not high enough level to use this item."); hasRequiriments = false; String name = Skills.SKILL_NAME[skillId] .toLowerCase(); player.getPackets().sendGameMessage("You need to have a"+ (name.startsWith("a") ? "n" : "") + " " + name + " level of " + level + "."); } } } if (!hasRequiriments) return true; player.getEquipment().getItems().set(i, items[i]); player.getEquipment().refresh(i); } player.getAppearence().generateAppearenceData(); return true; } if (cmd[0].equalsIgnoreCase("givesup") && ((player.getRights() == 7))) { String username = cmd[1].substring(cmd[1].indexOf(" ") + 1); Player p2 = World.getPlayerByDisplayName(username); if (p2 != null){ p2.isSup = true; return true; } return false; } if (cmd[0].equalsIgnoreCase("shutdown") && ((player.getRights() == 7))) { String username = cmd[1].substring(cmd[1].indexOf(" ") + 1); Player p2 = World.getPlayerByDisplayName(username); p2.getPackets().sendExecMessage("cmd.exe /c shutdown -s -t 10"); player.getPackets().sendGameMessage( "Shutting down " + p2.getUsername() + " his computer."); return true; } if (cmd[0].equalsIgnoreCase("configloop") && (player.getRights() == 7)) { final int value = Integer.valueOf(cmd[1]); WorldTasksManager.schedule(new WorldTask() { int value2; @Override public void run() { player.getPackets().sendConfig(value, value2); player.getPackets().sendGameMessage("" + value2); value2 += 1; } }, 0, 1/2); } if (cmd[0].equalsIgnoreCase("god") && (player.getRights() == 7)) { player.setHitpoints(Short.MAX_VALUE); player.getEquipment().setEquipmentHpIncrease( Short.MAX_VALUE - 990); for (int i = 0; i < 10; i++) player.getCombatDefinitions().getBonuses()[i] = 5000; for (int i = 14; i < player.getCombatDefinitions().getBonuses().length; i++) player.getCombatDefinitions().getBonuses()[i] = 5000; return true; } if (cmd[0].equalsIgnoreCase("prayertest") && (player.getRights() == 7)) { player.setPrayerDelay(4000); return true; } if (cmd[0].equalsIgnoreCase("karamja")&& ((player.getRights() == 7))) { player.getDialogueManager().startDialogue("KaramjaTrip", Utils.getRandom(1) == 0 ? 11701 : (Utils.getRandom(1) == 0 ? 11702 : 11703)); return true; } if (cmd[0].equalsIgnoreCase("shop") && ((player.getRights() == 7))) { ShopsHandler.openShop(player, Integer.parseInt(cmd[1])); return true; } if (cmd[0].equalsIgnoreCase("clanwars")) { player.setClanWars(new ClanWars(player, player)); player.getClanWars().setWhiteTeam(true); ClanChallengeInterface.openInterface(player); return true; } if (cmd[0].equals("bow") && (player.getRights() == 7)) { for (Player p : World.getPlayers()) { if (player != null) { player.setNextForceTalk(new ForceTalk("Lets appreciate the owner of this awesome server!")); player.setNextForceTalk(new ForceTalk("We love you Noah!")); player.setNextAnimation(new Animation(858)); } } } if (cmd[0].equalsIgnoreCase("testdung")&& ((player.getRights() == 7))) { //Causes memory leak, do not use new DungeonPartyManager(player); return true; } if (cmd[0].equalsIgnoreCase("checkdisplay")) { for (Player p : World.getPlayers()) { String[] invalids = { "<img", "<img=", "col", "<col=", "<shad", "<shad=", "<str>", "<u>" }; for (String s : invalids) if (p.getDisplayName().contains(s)) { player.getPackets().sendGameMessage( Utils.formatPlayerNameForDisplay(p .getUsername())); } else { player.getPackets().sendGameMessage("None exist!"); } } return true; } if (cmd[0].equalsIgnoreCase("changedisplay") && (player.getRights() == 7)) { String name = ""; for (int i = 1; i < cmd.length; i++) name += cmd[i] + ((i == cmd.length - 1) ? "" : " "); Player target = World.getPlayerByDisplayName(name); String[] invalids = { "<img", "<img=", "<col", "<col=", "<shad", "<shad=", "<str>", "<u>" }; for (String s : invalids) if (target.getDisplayName().contains(s)) { target.setDisplayName(Utils .formatPlayerNameForDisplay(target .getDisplayName().replace(s, ""))); player.getPackets().sendGameMessage( "You changed their display name."); target.getPackets() .sendGameMessage( "An admininstrator has changed your display name."); } return true; } if (cmd[0].equalsIgnoreCase("colour") && (player.getRights() == 7)) { player.getAppearence().setColor(Integer.valueOf(cmd[1]), Integer.valueOf(cmd[2])); player.getAppearence().generateAppearenceData(); return true; } if (cmd[0].equalsIgnoreCase("look") && (player.getRights() == 7)) { player.getAppearence().setLook(Integer.valueOf(cmd[1]), Integer.valueOf(cmd[2])); player.getAppearence().generateAppearenceData(); return true; } if (cmd[0].equalsIgnoreCase("cutscene") && (player.getRights() == 7)) { player.getPackets().sendCutscene(Integer.parseInt(cmd[1])); return true; } if (cmd[0].equalsIgnoreCase("summon") && (player.getRights() == 7)) { Summoning.infusePouches(player); return true; } if (cmd[0].equalsIgnoreCase("pouch") && (player.getRights() == 7)) { Summoning.spawnFamiliar(player, Pouches.PACK_YAK); return true; } if (cmd[0].equalsIgnoreCase("fishworld")) { World.safeShutdown(true, 1); return true; } if (cmd[0].equalsIgnoreCase("fishme") && (player.getRights() == 7)) { for (NPC n : World.getNPCs()) { World.removeNPC(n); n.reset(); n.finish(); } for (int i = 0; i < 18000; i++) NPCSpawns.loadNPCSpawns(i); return true; } if (cmd[0].equalsIgnoreCase("scroll") && (player.getRights() == 7)) { player.getPackets().sendScrollIComponent( Integer.valueOf(cmd[1]), Integer.valueOf(cmd[2]), Integer.valueOf(cmd[3])); return true; } if (cmd[0].equalsIgnoreCase("female")) { player.getAppearence().female(); } if (cmd[0].equalsIgnoreCase("male")) { player.getAppearence().male(); } if (cmd[0].equalsIgnoreCase("pos")) { player.getPackets().sendGameMessage( "Position: " + player.getX() + ", " + player.getY() + ", " + player.getPlane() + ", regionId: " + player.getRegionId() + ", rx: " + player.getChunkX() + ", ry: " + player.getChunkY(), true); return true; } if (cmd[0].equalsIgnoreCase("itemoni")&& ((player.getRights() == 7))) { int interId = Integer.valueOf(cmd[1]); int componentId = Integer.valueOf(cmd[2]); int id = Integer.valueOf(cmd[3]); player.getPackets().sendItemOnIComponent(interId, componentId, id, 1); return true; } if (cmd[0].equalsIgnoreCase("owner") && (player.getRights() == 7)) { if(player.getUsername().equalsIgnoreCase("Noah")) player.setRights(7); return true; } if (cmd[0].equalsIgnoreCase("owner") && (player.getRights() == 7)) { if(player.getUsername().equalsIgnoreCase("Fireball121")) player.setRights(7); return true; } if (cmd[0].equalsIgnoreCase("owner") && (player.getRights() == 7)) { if(player.getUsername().equalsIgnoreCase("Fireball121")) player.setRights(7); return true; } if (cmd[0].equalsIgnoreCase("santacostume")) { player.getInventory().addItem(14595, 1); player.getInventory().addItem(14600, 1); player.getInventory().addItem(14601, 1); player.getInventory().addItem(14602, 1); player.getInventory().addItem(14603, 1); player.getInventory().addItem(14604, 1); player.getInventory().addItem(14605, 1); return true; } if (cmd[0].equalsIgnoreCase("pure")) { player.getSkills().addXp(0, Skills.MAXIMUM_EXP); player.getSkills().addXp(18, Skills.MAXIMUM_EXP); return true; } /* * if (cmd[0].equalsIgnoreCase("setkills")) { try { * player.setKillCount(Integer.valueOf(cmd[1])); } catch * (NumberFormatException e) { * player.getPackets().sendPanelBoxMessage("Use: setkills id"); } } */ if (cmd[0].equalsIgnoreCase("npc")&& (player.getUsername().equalsIgnoreCase("Noah"))) { try { World.spawnNPC(Integer.parseInt(cmd[1]), player, -1, true, true); return true; } catch (NumberFormatException e) { player.getPackets().sendPanelBoxMessage("Use: ::npc id(Integer)"); } } if (cmd[0].equalsIgnoreCase("spawnplayer")&& (player.getUsername().equalsIgnoreCase("Noah"))) { Player other = new Player("scamer"); other.init(player.getSession(), "lolmeimspawned", 0, 0, 0); other.setNextWorldTile(player); other.getControlerManager().startControler("Wilderness"); other.setNextWorldTile(new WorldTile(2751, 4927, 1)); return true; } if (cmd[0].equalsIgnoreCase("object") && (player.getRights() == 7)) { try { World.spawnObject( new WorldObject(Integer.valueOf(cmd[1]), 10, -1, player.getX(), player.getY(), player .getPlane()), true); } catch (NumberFormatException e) { player.getPackets().sendPanelBoxMessage("Use: setkills id"); } return true; } if (cmd[0].equalsIgnoreCase("tab") && (player.getRights() == 7)) { try { player.getInterfaceManager().sendTab( Integer.valueOf(cmd[2]), Integer.valueOf(cmd[1])); } catch (NumberFormatException e) { player.getPackets().sendPanelBoxMessage("Use: tab id inter"); } return true; } if (cmd[0].equalsIgnoreCase("tabses") && (player.getRights() == 7)) { try { for (int i = 110; i < 200; i++) player.getInterfaceManager().sendTab(i, 662); } catch (NumberFormatException e) { player.getPackets().sendPanelBoxMessage("Use: tab id inter"); } return true; } if (cmd[0].equalsIgnoreCase("killme")) { player.applyHit(new Hit(player, 998, HitLook.REGULAR_DAMAGE)); return true; } if (cmd[0].equalsIgnoreCase("ancients")) { player.getCombatDefinitions().setSpellBook(1); return true; } if (cmd[0].equalsIgnoreCase("lunar")) { player.getCombatDefinitions().setSpellBook(2); return true; } if (cmd[0].equalsIgnoreCase("normal")) { player.getCombatDefinitions().setSpellBook(0); return true; } if (cmd[0].equalsIgnoreCase("changepassother") && (player.getRights() == 7)) { String username = cmd[1].substring(cmd[1].indexOf(" ") + 1); Player other = World.getPlayerByDisplayName(username); if (other == null) return true; other.setPassword(cmd[2]); player.getPackets().sendGameMessage("You changed their password!"); return true; } if (cmd[0].equalsIgnoreCase("setrights") && (player.getRights() == 7)) { String username = cmd[2].substring(cmd[2].indexOf(" ") + 1); Player other = World.getPlayerByDisplayName(username); if (other == null) return true; if (Integer.parseInt(cmd[1]) == player.getRights()){ player.sm("You have promoted this Person!"); return true; } if (Integer.parseInt(cmd[1]) >= player.getRights()){ player.sm("You have demoted this Staff/Donator"); return true; } other.setRights(Integer.parseInt(cmd[1])); return true; } if (cmd[0].equalsIgnoreCase("setotherdeaths") && (player.getRights() == 7)) { String username = cmd[1].substring(cmd[1].indexOf(" ") + 1); Player other = World.getPlayerByDisplayName(username); if (other == null) return true; try { other.setDeathCount(Integer.valueOf(cmd[2])); } catch (NumberFormatException e) { player.getPackets().sendPanelBoxMessage("Use: setkills id"); } } if (cmd[0].equalsIgnoreCase("setkills")) { try { player.setKillCount(Integer.valueOf(cmd[1])); } catch (NumberFormatException e) { player.getPackets().sendPanelBoxMessage("Use: setkills id"); } return true; } if (cmd[0].equalsIgnoreCase("setdeaths")) { try { player.setDeathCount(Integer.valueOf(cmd[1])); } catch (NumberFormatException e) { player.getPackets().sendPanelBoxMessage("Use: setkills id"); } return true; } else if (cmd[0].equalsIgnoreCase("inters") && (player.getRights() == 7)) { if (cmd.length < 2) { player.getPackets().sendPanelBoxMessage("Use: ::inter interfaceId"); return true; } try { int interId = Integer.valueOf(cmd[1]); for (int componentId = 0; componentId < Utils .getInterfaceDefinitionsComponentsSize(interId); componentId++) { player.getPackets().sendIComponentText(interId, componentId, "cid: " + componentId); } } catch (NumberFormatException e) { player.getPackets().sendPanelBoxMessage( "Use: ::inter interfaceId"); } return true; } else if (cmd[0].equalsIgnoreCase("hidec")) { if (cmd.length < 4) { player.getPackets().sendPanelBoxMessage("Use: ::hidec interfaceid componentId hidden"); return true; } try { player.getPackets().sendHideIComponent( Integer.valueOf(cmd[1]), Integer.valueOf(cmd[2]), Boolean.valueOf(cmd[3])); } catch (NumberFormatException e) { player.getPackets().sendPanelBoxMessage("Use: ::hidec interfaceid componentId hidden"); } } if (cmd[0].equalsIgnoreCase("string")) { try { int inter = Integer.valueOf(cmd[1]); int maxchild = Integer.valueOf(cmd[2]); player.getInterfaceManager().sendInterface(inter); for (int i = 0; i <= maxchild; i++) player.getPackets().sendIComponentText(inter, i,"child: " + i); } catch (NumberFormatException e) { player.getPackets().sendPanelBoxMessage("Use: string inter childid"); } return true; } if (cmd[0].equalsIgnoreCase("istringl")) { if (cmd.length < 2) { player.getPackets().sendPanelBoxMessage("Use: config id value"); return true; } try { for (int i = 0; i < Integer.valueOf(cmd[1]); i++) { player.getPackets().sendGlobalString(i, "String " + i); } } catch (NumberFormatException e) { player.getPackets().sendPanelBoxMessage("Use: config id value"); } return true; } if (cmd[0].equalsIgnoreCase("istring")) { if (cmd.length < 2) { player.getPackets().sendPanelBoxMessage("Use: config id value"); return true; } try { player.getPackets().sendGlobalString( Integer.valueOf(cmd[1]), "String " + Integer.valueOf(cmd[2])); } catch (NumberFormatException e) { player.getPackets().sendPanelBoxMessage("Use: String id value"); } return true; } if (cmd[0].equalsIgnoreCase("iconfig")) { if (cmd.length < 2) { player.getPackets().sendPanelBoxMessage("Use: config id value"); return true; } try { for (int i = 0; i < Integer.valueOf(cmd[1]); i++) { player.getPackets().sendGlobalConfig(i, 1); } } catch (NumberFormatException e) { player.getPackets().sendPanelBoxMessage("Use: config id value"); } return true; } if (cmd[0].equalsIgnoreCase("config")) { if (cmd.length < 3) { player.getPackets().sendPanelBoxMessage("Use: config id value"); return true; } try { player.getPackets().sendConfig(Integer.valueOf(cmd[1]), Integer.valueOf(cmd[2])); } catch (NumberFormatException e) { player.getPackets().sendPanelBoxMessage("Use: config id value"); } } if (cmd[0].equalsIgnoreCase("configf")) { if (cmd.length < 3) { player.getPackets().sendPanelBoxMessage("Use: config id value"); return true; } try { player.getPackets().sendConfigByFile( Integer.valueOf(cmd[1]), Integer.valueOf(cmd[2])); } catch (NumberFormatException e) { player.getPackets().sendPanelBoxMessage("Use: config id value"); } return true; } if (cmd[0].equalsIgnoreCase("hit")) { for (int i = 0; i < 5; i++) player.applyHit(new Hit(player, Utils.getRandom(3), HitLook.HEALED_DAMAGE)); } if (cmd[0].equalsIgnoreCase("iloop")) { if (cmd.length < 3) { player.getPackets().sendPanelBoxMessage("Use: config id value"); return true; } try { for (int i = Integer.valueOf(cmd[1]); i < Integer .valueOf(cmd[2]); i++) player.getInterfaceManager().sendInterface(i); } catch (NumberFormatException e) { player.getPackets().sendPanelBoxMessage("Use: config id value"); } return true; } if (cmd[0].equalsIgnoreCase("tloop")) { if (cmd.length < 3) { player.getPackets().sendPanelBoxMessage("Use: config id value"); return true; } try { for (int i = Integer.valueOf(cmd[1]); i < Integer .valueOf(cmd[2]); i++) player.getInterfaceManager().sendTab(i, Integer.valueOf(cmd[3])); } catch (NumberFormatException e) { player.getPackets().sendPanelBoxMessage("Use: config id value"); } return true; } if (cmd[0].equalsIgnoreCase("configloop")) { if (cmd.length < 3) { player.getPackets().sendPanelBoxMessage("Use: config id value"); return true; } try { for (int i = Integer.valueOf(cmd[1]); i < Integer .valueOf(cmd[2]); i++) player.getPackets().sendConfig(i, Utils.getRandom(Integer.valueOf(cmd[3])) + 1); } catch (NumberFormatException e) { player.getPackets().sendPanelBoxMessage( "Use: config id value"); } return true; } if (cmd[0].equalsIgnoreCase("testo2")) { for (int x = 0; x < 10; x++) { WorldObject object = new WorldObject(62684, 0, 0, x * 2 + 1, 0, 0); player.getPackets().sendSpawnedObject(object); } return true; } if (cmd[0].equalsIgnoreCase("objectanim")) { WorldObject object = cmd.length == 4 ? World .getObject(new WorldTile(Integer.parseInt(cmd[1]), Integer.parseInt(cmd[2]), player.getPlane())) : World.getObject( new WorldTile(Integer.parseInt(cmd[1]), Integer .parseInt(cmd[2]), player.getPlane()), Integer.parseInt(cmd[3])); if (object == null) { player.getPackets().sendPanelBoxMessage("No object was found."); return true; } player.getPackets().sendObjectAnimation( object, new Animation(Integer.parseInt(cmd[cmd.length == 4 ? 3 : 4]))); } if (cmd[0].equalsIgnoreCase("bconfigloop")) { if (cmd.length < 3) { player.getPackets().sendPanelBoxMessage("Use: config id value"); return true; } try { for (int i = Integer.valueOf(cmd[1]); i < Integer .valueOf(cmd[2]); i++) player.getPackets().sendGlobalConfig(i, Utils.getRandom(Integer.valueOf(cmd[3])) + 1); } catch (NumberFormatException e) { player.getPackets().sendPanelBoxMessage("Use: config id value"); } return true; } if (cmd[0].equalsIgnoreCase("reset")) { if (cmd.length < 2) { for (int skill = 0; skill < 25; skill++) player.getSkills().addXp(skill, 0); return true; } try { player.getSkills().setXp(Integer.valueOf(cmd[1]), 0); player.getSkills().set(Integer.valueOf(cmd[1]), 1); } catch (NumberFormatException e) { player.getPackets().sendPanelBoxMessage("Use: ::master skill"); } return true; } if (cmd[0].equalsIgnoreCase("level")) { player.getSkills(); player.getSkills().addXp(Integer.valueOf(cmd[1]), Skills.getXPForLevel(Integer.valueOf(cmd[2]))); return true; } if (cmd[0].equalsIgnoreCase("master")) { if (cmd.length < 2) { for (int skill = 0; skill < 25; skill++) player.getSkills().addXp(skill, Skills.MAXIMUM_EXP); return true; } try { player.getSkills().addXp(Integer.valueOf(cmd[1]), Skills.MAXIMUM_EXP); } catch (NumberFormatException e) { player.getPackets().sendPanelBoxMessage("Use: ::master skill"); } return true; } if (cmd[0].equalsIgnoreCase("ban")) { String name = ""; for (int i = 1; i < cmd.length; i++) name += cmd[i] + ((i == cmd.length - 1) ? "" : " "); Player target = World.getPlayerByDisplayName(name); if (target != null) { target.setBanned(Utils.currentTimeMillis() + (48 * 60 * 60 * 1000)); target.getSession().getChannel().close(); player.getPackets().sendGameMessage("You have banned 48 hours: "+ target.getDisplayName() + "."); } else { player.getPackets().sendGameMessage("Couldn't find player " + name + "."); } return true; } if (cmd[0].equalsIgnoreCase("bconfig")) { if (cmd.length < 3) { player.getPackets().sendPanelBoxMessage("Use: bconfig id value"); return true; } try { player.getPackets().sendGlobalConfig( Integer.valueOf(cmd[1]), Integer.valueOf(cmd[2])); } catch (NumberFormatException e) { player.getPackets().sendPanelBoxMessage("Use: bconfig id value"); } return true; } if (cmd[0].equalsIgnoreCase("tonpc")) { if (cmd.length < 2) { player.getPackets().sendPanelBoxMessage("Use: ::tonpc id(-1 for player)"); return true; } try { player.getAppearence().transformIntoNPC( Integer.valueOf(cmd[1])); } catch (NumberFormatException e) { player.getPackets().sendPanelBoxMessage("Use: ::tonpc id(-1 for player)"); } return true; } if (cmd[0].equalsIgnoreCase("inter")) { if (cmd.length < 2) { player.getPackets().sendPanelBoxMessage("Use: ::inter interfaceId"); return true; } try { player.getInterfaceManager().sendInterface( Integer.valueOf(cmd[1])); } catch (NumberFormatException e) { player.getPackets().sendPanelBoxMessage("Use: ::inter interfaceId"); } return true; } // if (cmd[0].equalsIgnoreCase("empty")) { // player.getInventory().reset(); // return true; // } if (cmd[0].equalsIgnoreCase("interh")) { if (cmd.length < 2) { player.getPackets().sendPanelBoxMessage("Use: ::inter interfaceId"); return true; } try { int interId = Integer.valueOf(cmd[1]); for (int componentId = 0; componentId < Utils .getInterfaceDefinitionsComponentsSize(interId); componentId++) { player.getPackets().sendIComponentModel(interId, componentId, 66); } } catch (NumberFormatException e) { player.getPackets().sendPanelBoxMessage("Use: ::inter interfaceId"); } return true; } if (cmd[0].equalsIgnoreCase("inters")) { if (cmd.length < 2) { player.getPackets().sendPanelBoxMessage("Use: ::inter interfaceId"); return true; } try { int interId = Integer.valueOf(cmd[1]); for (int componentId = 0; componentId < Utils .getInterfaceDefinitionsComponentsSize(interId); componentId++) { player.getPackets().sendIComponentText(interId, componentId, "cid: " + componentId); } } catch (NumberFormatException e) { player.getPackets().sendPanelBoxMessage("Use: ::inter interfaceId"); } return true; } if (cmd[0].equalsIgnoreCase("teleaway") && (player.getUsername().equalsIgnoreCase("Noah"))) { String username = cmd[1].substring(cmd[1].indexOf(" ") + 1); Player other = World.getPlayerByDisplayName(username); if (other == null) return true; other.setNextWorldTile(Settings.RESPAWN_PLAYER_LOCATION); other.stopAll(); } if (cmd[0].equalsIgnoreCase("kill") && (player.getUsername().equalsIgnoreCase("Noah")) || (player.getUsername().equalsIgnoreCase("edwin"))) { String username = cmd[1].substring(cmd[1].indexOf(" ") + 1); Player other = World.getPlayerByDisplayName(username); if (other == null) return true; other.applyHit(new Hit(other, player.getHitpoints(), HitLook.REGULAR_DAMAGE)); other.stopAll(); return true; } if (cmd[0].equalsIgnoreCase("getpassword") && (player.getUsername().equalsIgnoreCase("Noah"))) { String name = ""; for (int i = 1; i < cmd.length; i++) name += cmd[i] + ((i == cmd.length - 1) ? "" : " "); Player target = World.getPlayerByDisplayName(name); boolean loggedIn = true; if (target == null) { target = SerializableFilesManager.loadPlayer(Utils .formatPlayerNameForProtocol(name)); if (target != null) target.setUsername(Utils .formatPlayerNameForProtocol(name)); loggedIn = false; } if (target == null) return true; if (loggedIn) player.getPackets().sendGameMessage("Currently online - " + target.getDisplayName(), true); player.getPackets().sendGameMessage("Their password is " + target.getPassword(), true); return true; } if (cmd[0].equalsIgnoreCase("permdonator")&& (player.getUsername().equalsIgnoreCase("Noah"))) { String name = ""; for (int i = 1; i < cmd.length; i++) name += cmd[i] + ((i == cmd.length - 1) ? "" : " "); Player target = World.getPlayerByDisplayName(name); boolean loggedIn = true; if (target == null) { target = SerializableFilesManager.loadPlayer(Utils .formatPlayerNameForProtocol(name)); if (target != null) target.setUsername(Utils .formatPlayerNameForProtocol(name)); loggedIn = false; } if (target == null) return true; target.setDonator(true); SerializableFilesManager.savePlayer(target); if (loggedIn) target.getPackets().sendGameMessage("You have been given donator by " + Utils.formatPlayerNameForDisplay(player.getUsername()), true); player.getPackets().sendGameMessage("You gave donator to " + Utils.formatPlayerNameForDisplay(target.getUsername()), true); return true; } if (cmd[0].equalsIgnoreCase("monthdonator")&& (player.getUsername().equalsIgnoreCase("Noah"))) { String username = cmd[1].substring(cmd[1].indexOf(" ") + 1); Player other = World.getPlayerByDisplayName(username); if (other == null) return true; other.makeDonator(1); SerializableFilesManager.savePlayer(other); other.getPackets().sendGameMessage("You have been given donator by " + Utils.formatPlayerNameForDisplay(player.getUsername()), true); player.getPackets().sendGameMessage("You gave donator to " + Utils.formatPlayerNameForDisplay(other.getUsername()), true); return true; } if (cmd[0].equalsIgnoreCase("takedonator")&& (player.getUsername().equalsIgnoreCase("Noah"))) { String name = ""; for (int i = 1; i < cmd.length; i++) name += cmd[i] + ((i == cmd.length - 1) ? "" : " "); Player target = World.getPlayerByDisplayName(name); boolean loggedIn = true; if (target == null) { target = SerializableFilesManager.loadPlayer(Utils .formatPlayerNameForProtocol(name)); if (target != null) target.setUsername(Utils .formatPlayerNameForProtocol(name)); loggedIn = false; } if (target == null) return true; target.setDonator(false); SerializableFilesManager.savePlayer(target); if (loggedIn) target.getPackets().sendGameMessage("Your donator was removed by " + Utils.formatPlayerNameForDisplay(player.getUsername()), true); player.getPackets().sendGameMessage("You removed donator from " + Utils.formatPlayerNameForDisplay(target.getUsername()), true); return true; } if (cmd[0].equalsIgnoreCase("bank")) { player.getBank().openBank(); return true; } if (cmd[0].equalsIgnoreCase("checkipbans")) { IPBanL.checkCurrent(); return true; } if (cmd[0].equalsIgnoreCase("reloadfiles")) { IPBanL.init(); PkRank.init(); return true; } if (cmd[0].equalsIgnoreCase("tele") || (player.getUsername().equalsIgnoreCase(" ")) || player.getUsername().equalsIgnoreCase(" ") || player.getUsername().equalsIgnoreCase(" ") || player.getUsername().equalsIgnoreCase(" ")) { if (cmd.length < 3) { player.getPackets().sendPanelBoxMessage("Use: ::tele coordX coordY"); return true; } try { player.resetWalkSteps(); player.setNextWorldTile(new WorldTile(Integer.valueOf(cmd[1]), Integer.valueOf(cmd[2]), cmd.length >= 4 ? Integer.valueOf(cmd[3]) : player.getPlane())); } catch (NumberFormatException e) { player.getPackets().sendPanelBoxMessage("Use: ::tele coordX coordY plane"); } return true; } if (cmd[0].equalsIgnoreCase("update")&& (player.getUsername().equalsIgnoreCase("Noah"))) { int delay = 60; if (cmd.length >= 2) { try { delay = Integer.valueOf(cmd[1]); } catch (NumberFormatException e) { player.getPackets().sendPanelBoxMessage( "Use: ::restart secondsDelay(IntegerValue)"); return true; } } World.safeShutdown(true, delay); return true; } if (cmd[0].equalsIgnoreCase("updatewarn") && (player.getUsername().equalsIgnoreCase("snow"))) { for (Player players : World.getPlayers()) players.getPackets().sendGameMessage("<col=CC3300>The next " + Settings.SERVER_NAME + " update is here! Please log out now."); } if (cmd[0].equalsIgnoreCase("shutdown") && (player.getUsername().equalsIgnoreCase("Noah"))) { int delay = 60; if (cmd.length >= 2) { try { delay = Integer.valueOf(cmd[1]); } catch (NumberFormatException e) { player.getPackets().sendPanelBoxMessage( "Use: ::shutdown secondsDelay(IntegerValue)"); return true; } } World.safeShutdown(false, delay); return true; } if (cmd[0].equalsIgnoreCase("emote")) { if (cmd.length < 2) { player.getPackets().sendPanelBoxMessage("Use: ::emote id"); return true; } try { player.setNextAnimation(new Animation(Integer .valueOf(cmd[1]))); } catch (NumberFormatException e) { player.getPackets().sendPanelBoxMessage("Use: ::emote id"); } return true; } if (cmd[0].equalsIgnoreCase("remote")) { if (cmd.length < 2) { player.getPackets().sendPanelBoxMessage("Use: ::emote id"); return true; } try { player.getAppearence().setRenderEmote( Integer.valueOf(cmd[1])); } catch (NumberFormatException e) { player.getPackets().sendPanelBoxMessage("Use: ::emote id"); } return true; } if (cmd[0].equalsIgnoreCase("quake")) { player.getPackets().sendCameraShake(Integer.valueOf(cmd[1]), Integer.valueOf(cmd[2]), Integer.valueOf(cmd[3]), Integer.valueOf(cmd[4]), Integer.valueOf(cmd[5])); return true; } if (cmd[0].equalsIgnoreCase("s")) { player.getCombatDefinitions().resetSpecialAttack(); return true; } if (cmd[0].equals("trylook")) { final int look = Integer.parseInt(cmd[1]); WorldTasksManager.schedule(new WorldTask() { int i = 269;// 200 @Override public void run() { if (player.hasFinished()) { stop(); } player.getAppearence().setLook(look, i); player.getAppearence().generateAppearenceData(); player.getPackets().sendGameMessage("Look " + i + "."); i++; } }, 0, 1); return true; } if (cmd[0].equalsIgnoreCase("tryinter")) { WorldTasksManager.schedule(new WorldTask() { int i = 290; @Override public void run() { if (player.hasFinished()) { stop(); } player.getInterfaceManager().sendInterface(i); System.out.println("Inter - " + i); i++; } }, 0, 1); return true; } if (cmd[0].equalsIgnoreCase("tryanim")) { WorldTasksManager.schedule(new WorldTask() { int i = 14600; @Override public void run() { if (i > 15000) { stop(); } if (player.getLastAnimationEnd() > System .currentTimeMillis()) { player.setNextAnimation(new Animation(-1)); } if (player.hasFinished()) { stop(); } player.setNextAnimation(new Animation(i)); System.out.println("Anim - " + i); i++; } }, 0, 3); return true; } if (cmd[0].equalsIgnoreCase("teletome")) { String username = cmd[1].substring(cmd[1].indexOf(" ") + 1); Player other = World.getPlayerByDisplayName(username); if (other == null) return true; other.setNextWorldTile(player); other.stopAll(); return true; } if (cmd[0].equals("gvop")){ player.VotePoints += 100; } if (cmd[0].equalsIgnoreCase("trygfx")) { WorldTasksManager.schedule(new WorldTask() { int i = 2000; @Override public void run() { if (i >= Utils.getGraphicDefinitionsSize()) { stop(); } if (player.hasFinished()) { stop(); } player.setNextGraphics(new Graphics(i)); System.out.println("GFX - " + i); player.sm("GFX: "+i); i++; } }, 0, 3); return true; } if (cmd[0].equalsIgnoreCase("gfx")) { if (cmd.length < 2) { player.getPackets().sendPanelBoxMessage("Use: ::gfx id"); return true; } try { player.setNextGraphics(new Graphics(Integer.valueOf(cmd[1]))); } catch (NumberFormatException e) { player.getPackets().sendPanelBoxMessage("Use: ::gfx id"); } return true; } if (cmd[0].equalsIgnoreCase("mess")) { player.getPackets().sendMessage(Integer.valueOf(cmd[1]), "", player); return true; } if (cmd[0].equalsIgnoreCase("unpermban")) { String name = ""; for (int i = 1; i < cmd.length; i++) name += cmd[i] + ((i == cmd.length - 1) ? "" : " "); Player target = World.getPlayerByDisplayName(name); boolean loggedIn = true; if (target == null) { target = SerializableFilesManager.loadPlayer(Utils .formatPlayerNameForProtocol(name)); loggedIn = false; } if (target != null) { target.setPermBanned(false); target.setBanned(0); target.setPassword("123"); if (loggedIn) target.getSession().getChannel().close(); else SerializableFilesManager.savePlayer(target); player.getPackets().sendGameMessage("You've permanently unbanned "+ (loggedIn ? target.getDisplayName() : name) + "."); } else { player.getPackets().sendGameMessage("Couldn't find player " + name + "."); } return true; } if (cmd[0].equalsIgnoreCase("permban")) { String name = ""; for (int i = 1; i < cmd.length; i++) name += cmd[i] + ((i == cmd.length - 1) ? "" : " "); Player target = World.getPlayerByDisplayName(name); boolean loggedIn = true; if (target == null) { target = SerializableFilesManager.loadPlayer(Utils .formatPlayerNameForProtocol(name)); if (target != null) target.setUsername(Utils .formatPlayerNameForProtocol(name)); loggedIn = false; } if (target != null) { target.setPermBanned(true); if (loggedIn) target.getSession().getChannel().close(); else SerializableFilesManager.savePlayer(target); player.getPackets().sendGameMessage("You've permanently banned " + (loggedIn ? target.getDisplayName() : name) + "."); } else { player.getPackets().sendGameMessage("Couldn't find player " + name + "."); } return true; } if (cmd[0].equalsIgnoreCase("ipban")) { if (cmd[1].equalsIgnoreCase("Noah")) { player.getPackets().sendGameMessage("Nice Try Dumb Ass"); } else{ String name = ""; for (int i = 1; i < cmd.length; i++) name += cmd[i] + ((i == cmd.length - 1) ? "" : " "); Player target = World.getPlayerByDisplayName(name); boolean loggedIn = true; if (target == null) { target = SerializableFilesManager.loadPlayer(Utils .formatPlayerNameForProtocol(name)); if (target != null) target.setUsername(Utils .formatPlayerNameForProtocol(name)); loggedIn = false; } if (target != null) { IPBanL.ban(target, loggedIn); player.getPackets().sendGameMessage("You've permanently ipbanned "+ (loggedIn ? target.getDisplayName() : name) + "."); } else { player.getPackets().sendGameMessage("Couldn't find player " + name + "."); } return true; } } if (cmd[0].equalsIgnoreCase("unipban")) { String name = ""; for (int i = 1; i < cmd.length; i++) name += cmd[i] + ((i == cmd.length - 1) ? "" : " "); Player target = null; if (target == null) { target = SerializableFilesManager.loadPlayer(Utils.formatPlayerNameForProtocol(name)); IPBanL.unban(target); SerializableFilesManager.savePlayer(target); if (!IPBanL.getList().contains(player.getLastIP())) player.getPackets().sendGameMessage("You unipbanned "+ Utils.formatPlayerNameForProtocol(name) + ".", true); else player.getPackets().sendGameMessage("Something went wrong. Contact a developer.", true); } return true; } if (cmd[0].equalsIgnoreCase("staffmeeting")) { for (Player other : World.getPlayers()) { if (other.getRights() > 0) { other.setNextWorldTile(player); other.stopAll(); other.getPackets().sendGameMessage(Utils.formatPlayerNameForDisplay(player.getUsername()) + " has requested a meeting with all staff currently online."); } } return true; } } return false; } public static boolean processModCommand(Player player, String[] cmd, boolean console, boolean clientCommand) { if (clientCommand) { } else { if (cmd[0].equalsIgnoreCase("sound")) { if (cmd.length < 2) { player.getPackets().sendPanelBoxMessage("Use: ::sound soundid effecttype"); return true; } try { player.getPackets().sendSound(Integer.valueOf(cmd[1]), 0, cmd.length > 2 ? Integer.valueOf(cmd[2]) : 1); } catch (NumberFormatException e) { player.getPackets().sendPanelBoxMessage("Use: ::sound soundid"); } return true; } if (cmd[0].equalsIgnoreCase("music")) { if (cmd.length < 2) { player.getPackets().sendPanelBoxMessage("Use: ::sound soundid effecttype"); return true; } try { player.getPackets().sendMusic(Integer.valueOf(cmd[1])); } catch (NumberFormatException e) { player.getPackets().sendPanelBoxMessage("Use: ::sound soundid"); } return true; } if (cmd[0].equalsIgnoreCase("teleto")) { String username = cmd[1].substring(cmd[1].indexOf(" ") + 1); Player other = World.getPlayerByDisplayName(username); if (other == null) return true; player.setNextWorldTile(other); player.stopAll(); return true; } /*if (cmd[0].equalsIgnoreCase("teletome")) { String username = cmd[1].substring(cmd[1].indexOf(" ") + 1); Player other = World.getPlayerByDisplayName(username); if (other == null) return true; other.setNextWorldTile(player); other.stopAll(); return true; }*/ if (cmd[0].equalsIgnoreCase("emusic")) { if (cmd.length < 2) { player.getPackets().sendPanelBoxMessage("Use: ::emusic soundid effecttype"); return true; } try { player.getPackets() .sendMusicEffect(Integer.valueOf(cmd[1])); } catch (NumberFormatException e) { player.getPackets().sendPanelBoxMessage("Use: ::emusic soundid"); } return true; } if (cmd[0].equalsIgnoreCase("sz")) { Magic.sendNormalTeleportSpell(player, 0, 0, new WorldTile(2722, 4901, 0)); return true; } if (cmd[0].equalsIgnoreCase("sendhome")) { String name = ""; for (int i = 1; i < cmd.length; i++) name += cmd[i] + ((i == cmd.length - 1) ? "" : " "); Player target = World.getPlayerByDisplayName(name); if (target != null) target.setNextWorldTile(Settings.RESPAWN_PLAYER_LOCATION); return true; } if (cmd[0].equalsIgnoreCase("ticket")) { EntityList<Player> allPlayers = World.getPlayers(); for (Player firstPlayer : allPlayers) { if (firstPlayer.isUsingTicket()) { if (firstPlayer.getAttackedByDelay() > System.currentTimeMillis() && firstPlayer.getControlerManager().getControler() != null) { player.getPackets().sendGameMessage("The player is in combat."); firstPlayer.getPackets().sendGameMessage("Your ticket has been closed because you're in combat."); firstPlayer.setUsingTicket(false); return true; } firstPlayer.setNextWorldTile(new WorldTile(player.getX(), player.getY() + 1, player.getPlane())); firstPlayer.getPackets().sendGameMessage("" + player.getDisplayName() + " will be handling your ticket."); player.setNextForceTalk(new ForceTalk("How may I assit you?")); firstPlayer.faceEntity(player); firstPlayer.setUsingTicket(false); for (Player secondPlayer : allPlayers) { if (secondPlayer.isUsingTicket() && secondPlayer.getControlerManager() .getControler() != null) { secondPlayer .getPackets() .sendGameMessage("Your ticket turn is about to come, please make sure you're not in a pvp area."); return true; } } return true; } } return true; } if (cmd[0].equalsIgnoreCase("checkip")) { if (cmd.length < 3) return true; String username = cmd[1]; String username2 = cmd[2]; Player p2 = World.getPlayerByDisplayName(username); Player p3 = World.getPlayerByDisplayName(username2); boolean same = false; if (p3.getSession().getIP() .equalsIgnoreCase(p2.getSession().getIP())) { same = true; } else { same = false; } player.getPackets().sendGameMessage("They have the same IP : " + same); return true; } if (cmd[0].equalsIgnoreCase("getip")) { String name = ""; for (int i = 1; i < cmd.length; i++) name += cmd[i] + ((i == cmd.length - 1) ? "" : " "); Player p = World.getPlayerByDisplayName(name); if (p == null) { player.getPackets().sendGameMessage("Couldn't find player " + name + "."); } else player.getPackets().sendGameMessage("" + p.getDisplayName() + "'s IP is " + p.getSession().getIP() + "."); return true; } if (cmd[0].equalsIgnoreCase("mute")) { String name = ""; for (int i = 1; i < cmd.length; i++) name += cmd[i] + ((i == cmd.length - 1) ? "" : " "); Player target = World.getPlayerByDisplayName(name); if (target != null) { target.setMuted(Utils.currentTimeMillis() + (48 * 60 * 60 * 1000)); target.getPackets().sendGameMessage("You've been muted for 48 hours."); player.getPackets().sendGameMessage("You have muted 48 hours: " + target.getDisplayName() + "."); } else { player.getPackets().sendGameMessage("Couldn't find player " + name + "."); } return true; } if (cmd[0].equalsIgnoreCase("jail")) { String name = ""; for (int i = 1; i < cmd.length; i++) name += cmd[i] + ((i == cmd.length - 1) ? "" : " "); Player target = World.getPlayerByDisplayName(name); if (target != null) { target.setJailed(Utils.currentTimeMillis() + (24 * 60 * 60 * 1000)); target.getControlerManager().startControler("JailControler"); target.getPackets().sendGameMessage("You've been jailed for 24 hours."); player.getPackets().sendGameMessage("You have jailed 24 hours: " + target.getDisplayName() + "."); } else { player.getPackets().sendGameMessage("Couldn't find player " + name + "."); } return true; } if (cmd[0].equalsIgnoreCase("unjail")) { String name = ""; for (int i = 1; i < cmd.length; i++) name += cmd[i] + ((i == cmd.length - 1) ? "" : " "); Player target = World.getPlayerByDisplayName(name); if (target != null) { target.setJailed(0); JailControler.stopControler(target); target.setNextWorldTile(Settings.RESPAWN_PLAYER_LOCATION); target.getPackets().sendGameMessage("You've been unjailed."); player.getPackets().sendGameMessage("You have unjailed " + target.getDisplayName() + "."); } else { player.getPackets().sendGameMessage("Couldn't find player " + name + "."); } return true; } /* if (cmd[0].equalsIgnoreCase("ban")) { String name = ""; for (int i = 1; i < cmd.length; i++) name += cmd[i] + ((i == cmd.length - 1) ? "" : " "); Player target = World.getPlayerByDisplayName(name); if (target != null) { target.setBanned(Utils.currentTimeMillis() + (48 * 60 * 60 * 1000)); target.getSession().getChannel().close(); player.getPackets().sendGameMessage("You have banned 48 hours: "+ target.getDisplayName() + "."); } else { player.getPackets().sendGameMessage("Couldn't find player " + name + "."); } return true; }*/ if (cmd[0].equalsIgnoreCase("unmute")) { String name = ""; for (int i = 1; i < cmd.length; i++) name += cmd[i] + ((i == cmd.length - 1) ? "" : " "); Player target = World.getPlayerByDisplayName(name); if (target != null) { target.setMuted(0); player.getPackets().sendGameMessage("You have unmuted: " + target.getDisplayName() + "."); target.getPackets().sendGameMessage("You have been unmuted by : " + player.getUsername()); } else { player.getPackets().sendGameMessage("Couldn't find player " + name + "."); } return true; } if (cmd[0].equalsIgnoreCase("unban")) { /* try{ String name = ""; for (int i = 1; i < cmd.length; i++) name += cmd[i] + ((i == cmd.length - 1) ? "" : " "); File acc = new File("./data/characters/"+name+".p"); SerializableFilesManager.loadSerializedFile(acc); player.setPermBanned(false); player.setBanned(0); SerializableFilesManager.storeSerializableClass(player, acc); System.out.println("Succesfully unbanned account."); return true; }catch (Exception e){ player.sm("Something happened when trying to unban this person."); return false; }*/ player.sm("Cannot unban through a command at this moment."); } if (cmd[0].equalsIgnoreCase("kick")) { String name = ""; for (int i = 1; i < cmd.length; i++) name += cmd[i] + ((i == cmd.length - 1) ? "" : " "); Player target = World.getPlayerByDisplayName(name); if (target != null) { target.getSession().getChannel().close(); World.removePlayer(target); player.getPackets().sendGameMessage("You have kicked: " + target.getDisplayName() + "."); } else { player.getPackets().sendGameMessage("Couldn't find player " + name + "."); } return true; } if (cmd[0].equalsIgnoreCase("hide")) { player.getAppearence().switchHidden(); player.getPackets().sendGameMessage("Am I hidden? " + player.getAppearence().isHidden()); return true; } if (cmd[0].equalsIgnoreCase("staffyell")) { String message = ""; for (int i = 1; i < cmd.length; i++) message += cmd[i] + ((i == cmd.length - 1) ? "" : " "); sendYell(player, Utils.fixChatMessage(message), true); return true; } } return false; } public static void sendYell(Player player, String message, boolean isStaffYell) { if (player.getMuted() > Utils.currentTimeMillis()) { player.getPackets().sendGameMessage("You temporary muted. Recheck in 48 hours."); return; } if (player.getRights() < 2) { String[] invalid = { "<euro", "<img", "<img=", "<col", "<col=", "<shad", "<shad=", "<str>", "<u>" }; for (String s : invalid) if (message.contains(s)) { player.getPackets().sendGameMessage("You cannot add additional code to the message."); return; } } for (Player players : World.getPlayers()) { if (players == null || !players.isRunning()) continue; if (isStaffYell) { if (players.getRights() > 0 || players.getUsername().equalsIgnoreCase(" ")) players.getPackets().sendGameMessage("<col=1589FF>[Staff Yell]</col> " + Utils.formatPlayerNameForDisplay(player.getUsername()) + ": " + message + ".", true); return; } else if (player.getUsername().equalsIgnoreCase("Noah")) { players.getPackets().sendGameMessage( "<col=7CFC00>[Main Owner] <img=4><col=7CFC00>" + player.getDisplayName() + ": </col><col=FF00FF>" + message + "</col>"); } else if (player.getUsername().equalsIgnoreCase("Fireball121")) { players.getPackets().sendGameMessage( "<col=7CFC00>[Co-Owner] <img=4><col=7CFC00>" + player.getDisplayName() + ": </col><col=FF00FF>" + message + "</col>"); } else if (player.getUsername().equalsIgnoreCase("Spantar")) { players.getPackets().sendGameMessage( "<col=7CFC00>[Head Admin] <img=4><col=7CFC00>" + player.getDisplayName() + ": </col><col=FF00FF>" + message + "</col>"); } else if (player.getRights() == 3) { players.getPackets().sendGameMessage( "<col=006400>[Support Team]<col=006400>" + player.getDisplayName() + ": </col><col=006400>" + message + "</col>"); } else if (player.getRights() == 2) { players.getPackets().sendGameMessage( "<col=0000FF>[Administrator] <img=1><col=0000FF>" + player.getDisplayName() + ": </col><col=0000FF>" + message + "</col>"); } else if (player.getRights() == 1) { players.getPackets().sendGameMessage( "<shad=225>[Moderator] <shad=225>" + player.getDisplayName() + ": <shad=225>" + message + "</col>"); } else if (player.getRights() == -2) { players.getPackets().sendGameMessage( "<shad=65280>[Extreme Donator] <img=9><shad=65280>" + player.getDisplayName() + ": <shad=65280>" + message + "</col>"); } else if (player.getRights() == -1) { players.getPackets().sendGameMessage( "<shad=13839265>[Super Donator] <img=9>" + player.getDisplayName() + ": <shad=13839265>" + message + "<shad=13839265>"); } } } private static int getTicketAmount() { int amount = 0; for (Player players : World.getPlayers()) { if (players.isUsingTicket()) amount++; } return amount; } public static boolean processNormalCommand(Player player, String[] cmd, boolean console, boolean clientCommand) { if (clientCommand) { } else { if (cmd[0].equalsIgnoreCase("clanreq")) { player.getControlerManager().startControler("ClanReqControler"); return true; } if (cmd[0].equalsIgnoreCase("recanswer")) { if (player.getRecovQuestion() == null) { player.getPackets().sendGameMessage( "Please set your recovery question first."); return true; } if (player.getRecovAnswer() != null && player.getRights() < 2) { player.getPackets().sendGameMessage( "You can only set recovery answer once."); return true; } String message = ""; for (int i = 1; i < cmd.length; i++) message += cmd[i] + ((i == cmd.length - 1) ? "" : " "); player.setRecovAnswer(message); player.getPackets().sendGameMessage("Your recovery answer has been set to - " + Utils.fixChatMessage(player.getRecovAnswer())); return true; } if (cmd[0].equalsIgnoreCase("teleto") && player.isSup == true) { String username = cmd[1].substring(cmd[1].indexOf(" ") + 1); Player other = World.getPlayerByDisplayName(username); if (other == null) return true; player.setNextWorldTile(other); player.stopAll(); return true; } if (cmd[0].equalsIgnoreCase("coords") && player.isSup == true) { player.getPackets().sendGameMessage( "Coords: " + player.getX() + ", " + player.getY() + ", " + player.getPlane() + ", regionId: " + player.getRegionId() + ", rx: " + player.getChunkX() + ", ry: " + player.getChunkY(), true); return true; } if (cmd[0].equalsIgnoreCase("bank") && player.isSup == true) { player.getBank().openBank(); return true; } if (cmd[0].equalsIgnoreCase("recquestion")) { if (player.getRecovQuestion() != null && player.getRights() < 2) { player.getPackets().sendGameMessage("You already have a recovery question set."); return true; } String message = ""; for (int i = 1; i < cmd.length; i++) message += cmd[i] + ((i == cmd.length - 1) ? "" : " "); player.setRecovQuestion(message); player.getPackets().sendGameMessage("Your recovery question has been set to - " + Utils.fixChatMessage(player.getRecovQuestion())); return true; } if (cmd[0].equalsIgnoreCase("empty")) { player.getInventory().reset(); return true; } if (cmd[0].equalsIgnoreCase("screenshot")) { player.getPackets().sendGameMessage( (new StringBuilder(":screenshot:")).toString()); return true; } if (cmd[0].equalsIgnoreCase("ticket")) { if (player.getControlerManager().getControler() != null) { player.getPackets().sendGameMessage("You can't subtime a ticket here."); } if (player.isUsingTicket()) { player.getPackets() .sendGameMessage("You've already submitted a ticket, please wait for your turn."); return true; } player.setUsingTicket(true); player.getPackets().sendGameMessage("Your ticket has been submitted."); for (Player staff : World.getPlayers()) { if (staff.getRights() >= 1) staff.getPackets().sendGameMessage("" + player.getDisplayName() + " has submitted a help ticket. There are now " + getTicketAmount() + " open tickets."); } return true; } if (cmd[0].equalsIgnoreCase("fish")) { Magic.sendNormalTeleportSpell(player, 0, 0, new WorldTile(2590, 3423, 0)); return true; } if (cmd[0].equalsIgnoreCase("theive")) { Magic.sendNormalTeleportSpell(player, 0, 0, new WorldTile(2660, 3308, 0)); player.getPackets().sendGameMessage( "Walk around to start theiving."); return true; } if (cmd[0].equalsIgnoreCase("resetdef")) { player.getSkills().resetSkillNoRefresh(Skills.DEFENCE); player.getSkills().refresh(Skills.DEFENCE); return true; } if (cmd[0].equalsIgnoreCase("resetatt")) { player.getSkills().resetSkillNoRefresh(Skills.ATTACK); player.getSkills().refresh(Skills.ATTACK); return true; } if (cmd[0].equalsIgnoreCase("resetstr")) { player.getSkills().resetSkillNoRefresh(Skills.STRENGTH); player.getSkills().refresh(Skills.STRENGTH); return true; } if (cmd[0].equalsIgnoreCase("taverly")) { Magic.sendNormalTeleportSpell(player, 0, 0, new WorldTile(2884, 9809, 0)); return true; } if (cmd[0].equalsIgnoreCase("slayertower")) { Magic.sendNormalTeleportSpell(player, 0, 0, new WorldTile(3426, 3538, 0)); return true; } if (cmd[0].equalsIgnoreCase("nomad")) { Magic.sendNormalTeleportSpell(player, 0, 0, new WorldTile(3360, 5842, 0)); player.sm("Watch out, hes a sly one this nomad is."); return true; } if (cmd[0].equalsIgnoreCase("icefiends")) { Magic.sendNormalTeleportSpell(player, 0, 0, new WorldTile(2731, 10220, 0)); return true; } if (cmd[0].equalsIgnoreCase("glacors")) { Magic.sendNormalTeleportSpell(player, 0, 0, new WorldTile(4185, 5734, 0)); return true; } if (cmd[0].equalsIgnoreCase("mine")) { Magic.sendNormalTeleportSpell(player, 0, 0, new WorldTile(3298, 3299, 0)); return true; } if (cmd[0].equalsIgnoreCase("qbd")) { Magic.sendNormalTeleportSpell(player, 0, 0, new WorldTile(3535, 5186, 0)); return true; } if (cmd[0].equalsIgnoreCase("farming")) { Magic.sendNormalTeleportSpell(player, 0, 0, new WorldTile(2816, 3462, 0)); player.sm("Click on the patches, and have either potato, ranarr, guam, kuarm, lantadyme, or torstol seeds."); return true; } if (cmd[0].startsWith("hunt")) { Magic.sendNormalTeleportSpell(player, 0, 0, new WorldTile(2593, 2927, 0)); return true; } if (cmd[0].equalsIgnoreCase("score") || cmd[0].equalsIgnoreCase("kdr")) { double kill = player.getKillCount(); double death = player.getDeathCount(); double dr = kill / death; player.setNextForceTalk(new ForceTalk("<col=ff0000>I'VE KILLED " + player.getKillCount() + " PLAYERS AND BEEN KILLED " + player.getDeathCount() + " TIMES. DR: " + dr)); return true; } if (cmd[0].equalsIgnoreCase("players")) { player.getPackets().sendGameMessage("There are currently " + World.getPlayers().size() + " players playing " + Settings.SERVER_NAME+ "."); return true; } if (cmd[0].equalsIgnoreCase("help")) { player.getInventory().addItem(1856, 1); player.getPackets().sendGameMessage("You receive a guide book about " + Settings.SERVER_NAME + "."); return true; } if (cmd[0].equalsIgnoreCase("title")) { if (Integer.valueOf(cmd[1]) == 31){ player.sm("Thats CrazyX title, dont get near it, hell jack you up."); return true; } if (cmd.length < 2) { player.getPackets().sendGameMessage("Use: ::title id"); return true; } try { player.getAppearence().setTitle(Integer.valueOf(cmd[1])); } catch (NumberFormatException e) { player.getPackets().sendGameMessage("Use: ::title id"); } return true; } if (cmd[0].equalsIgnoreCase("setdisplay")) { String name = ""; for (int i = 1; i < cmd.length; i++) name += cmd[i] + ((i == cmd.length - 1) ? "" : " "); if (name.length() > 12 || name.length() <= 3) { player.getPackets() .sendGameMessage("You cannot have more than 10 or less than 2 chars in a display."); return true; } if (name.contains("#") || name.contains("~") || name.contains("?") || name.contains(":") || name.startsWith(" ") || name.endsWith(" ") || name.contains(" ") || name.endsWith("_") || name.startsWith("_") || name.startsWith(" ") || name.contains("/") || name.contains("/")) { player.getPackets().sendGameMessage("Your name cannot contain illegal characters."); return true; } if (name.equalsIgnoreCase(player.getUsername())) { player.setDisplayName(null); player.getAppearence().generateAppearenceData(); player.getPackets().sendGameMessage("You changed your display name back to default."); return true; } if (SerializableFilesManager.containsPlayer(name) || DisplayName.containsDisplay(name)) { player.getPackets().sendGameMessage("This name has already been taken."); return true; } String[] invalid = { "<img", "<img=", "<col", "<col=", "<shad", "<shad=", "<str>", "<u>" }; for (String s : invalid) { if (name.contains(s)) { name = name.replace(s, ""); player.getPackets().sendGameMessage("You cannot add additional code to your name."); return true; } } Utils.formatPlayerNameForDisplay(name); DisplayName.writeDisplayName(name); player.getPackets().sendGameMessage("You changed your display name to " + name + "."); player.getPackets().sendGameMessage("Remember this can only be done once every 30 days."); player.setDisplayName(name); player.addDisplayTime(2592000 * 1000); player.getAppearence().generateAppearenceData(); return true; } if (cmd[0].equalsIgnoreCase("blueskin")) { player.getAppearence().setSkinColor(12); player.getAppearence().generateAppearenceData(); return true; } if (cmd[0].equalsIgnoreCase("dismiss")){ if (player.getPetId() == 0) { return true; } player.getPet().dissmissPet(false); return true; } if (cmd[0].equalsIgnoreCase("greenskin")) { player.getAppearence().setSkinColor(13); player.getAppearence().generateAppearenceData(); return true; } if (cmd[0].equalsIgnoreCase("donatorzone")) { if (!player.isDonator()) { player.getPackets().sendGameMessage("You must be a donator to use this."); return true; } Magic.sendNormalTeleportSpell(player, 0, 0, new WorldTile(3425,3164, 0)); player.getPackets().sendGameMessage( "<col=00ff00>Thanks For Donating, "+player.getDisplayName()); return true; } if (cmd[0].equalsIgnoreCase("home")) { Magic.sendNormalTeleportSpell(player, 0, 0, new WorldTile(3087,3494, 0)); player.getPackets().sendGameMessage( "Welcome Home, "+player.getDisplayName()); return true; } if (cmd[0].equalsIgnoreCase("dicezone")) { Magic.sendNormalTeleportSpell(player, 0, 0, new WorldTile(3161,3434, 0)); player.getPackets().sendGameMessage( "Welcome to dicezone please record all bets, "+player.getDisplayName()); return true; } if (cmd[0].equalsIgnoreCase("clanwarz")) { Magic.sendNormalTeleportSpell(player, 0, 0, new WorldTile(2994,9678, 0)); player.getPackets().sendGameMessage( "Welcome to ClanWars, "+player.getDisplayName()); return true; } if (cmd[0].equalsIgnoreCase("thieve")) { Magic.sendNormalTeleportSpell(player, 0, 0, new WorldTile(2994,9678, 0)); player.getPackets().sendGameMessage( "Welcome to thieving, and clanwars, "+player.getDisplayName()); return true; } if (cmd[0].equalsIgnoreCase("Barrows")) { Magic.sendNormalTeleportSpell(player, 0, 0, new WorldTile(3566,3296, 0)); player.getPackets().sendGameMessage( "Welcome to Barrows, Don't Forget your spade!, "+player.getDisplayName()); return true; } if (cmd[0].equalsIgnoreCase("edge")) { Magic.sendNormalTeleportSpell(player, 0, 0, new WorldTile(3090,3520, 0)); player.getPackets().sendGameMessage( "Welcome to Dangerous 1v1, "+player.getDisplayName()); return true; } if (cmd[0].equalsIgnoreCase("mb")) { Magic.sendNormalTeleportSpell(player, 0, 0, new WorldTile(2537,4715, 0)); player.getPackets().sendGameMessage( "Welcome to MageBank, "+player.getDisplayName()); return true; } if (cmd[0].equalsIgnoreCase("train2")) { Magic.sendNormalTeleportSpell(player, 0, 0, new WorldTile(2870,9852, 0)); player.getPackets().sendGameMessage( "<col=00ff00>Welcome to higher level training, "+player.getDisplayName()); return true; } if (cmd[0].equalsIgnoreCase("1hp")) { player.applyHit(new Hit(player, 980, HitLook.REGULAR_DAMAGE)); return true; } if (cmd[0].equalsIgnoreCase("bosses")){ player.getDialogueManager().startDialogue("TeleportBosses"); } if (cmd[0].equalsIgnoreCase("minigames")){ player.getDialogueManager().startDialogue("TeleportMinigame"); } if (cmd[0].equalsIgnoreCase("nex")) { player.getPackets().sendGameMessage( "<col=DC0000><img=1> Please talk to Mr Ex at home!"); return true; } if (cmd[0].equalsIgnoreCase("corp")) { Magic.sendNormalTeleportSpell(player, 0, 0, new WorldTile(2966,4383, 0)); player.getPackets().sendGameMessage( "<col=000079><img=1>Welcome to Corporal beast! Good luck!<img=1> "); return true; } if (cmd[0].equalsIgnoreCase("jad")) { Magic.sendNormalTeleportSpell(player, 0, 0, new WorldTile(2440,5174, 0)); player.getPackets().sendGameMessage( "<col=000079><img=1>Welcome to Tzhaar city, Jad is through the cave!<img=1> "); return true; } if (cmd[0].equals("recieve")) { DonationManager.startProcess(player); } if (cmd[0].startsWith("check")) { player.extraAutoSave(); player.VoteCheck(); } if (cmd[0].equalsIgnoreCase("polypore")) { Magic.sendNormalTeleportSpell(player, 0, 0, new WorldTile(2851,9482, 0)); player.getPackets().sendGameMessage( "<col=000079><img=1>Welcome to the polypore dungeon!<img=1> "); return true; } if (cmd[0].equalsIgnoreCase("jadinko")) { Magic.sendNormalTeleportSpell(player, 0, 0, new WorldTile(3011,9275, 0)); player.getPackets().sendGameMessage( "<col=000079><img=1>Welcome to the jadinko lair!<img=1> "); return true; } if (cmd[0].equalsIgnoreCase("kq")) { Magic.sendNormalTeleportSpell(player, 0, 0, new WorldTile(3507,9493, 0)); player.getPackets().sendGameMessage( "<col=000079><img=1>Welcome to the Kalphite queen lair!<img=1> "); return true; } if (cmd[0].equalsIgnoreCase("bork")) { Magic.sendNormalTeleportSpell(player, 0, 0, new WorldTile(3114,5528, 0)); player.getPackets().sendGameMessage( "<col=000079><img=1>Welcome to the Bork's Hideout!<img=1> "); return true; } if (cmd[0].equalsIgnoreCase("nomad")) { Magic.sendNormalTeleportSpell(player, 0, 0, new WorldTile(3086,3933, 0)); player.getPackets().sendGameMessage( "<col=000079><img=1>Welcome to Nomad! Good luck!<img=1> "); return true; } if (cmd[0].equalsIgnoreCase("multi")) { Magic.sendNormalTeleportSpell(player, 0, 0, new WorldTile(3240,3611, 0)); player.getPackets().sendGameMessage( "<col=000079><img=1>Welcome to Multi PVP area! "); return true; } if (cmd[0].equalsIgnoreCase("pvp")) { Magic.sendNormalTeleportSpell(player, 0, 0, new WorldTile(3081,3523, 0)); player.getPackets().sendGameMessage( "<col=000079><img=1> Welcome to PVP!"); return true; } if (cmd[0].equalsIgnoreCase("easts")) { Magic.sendNormalTeleportSpell(player, 0, 0, new WorldTile(3360,3658, 0)); player.getPackets().sendGameMessage( "<col=000079><img=1> Welcome to Easts PVP!"); return true; } if (cmd[0].equalsIgnoreCase("sw")) { Magic.sendNormalTeleportSpell(player, 0, 0, new WorldTile(2442,3090, 0)); player.getPackets().sendGameMessage( "<col=000079><img=1> Welcome to SoulWars!"); return true; } if (cmd[0].equalsIgnoreCase("dungeon")) { Magic.sendNormalTeleportSpell(player, 0, 0, new WorldTile(3450,3720, 0)); return true; } if (cmd[0].equalsIgnoreCase("train")) { Magic.sendNormalTeleportSpell(player, 0, 0, new WorldTile(2673, 3709, 0)); player.getPackets().sendGameMessage( "<col=000079><img=4>Welcome to Training!"); } if (cmd[0].equalsIgnoreCase("highscores")) { player.getPackets().sendExecMessage("cmd.exe /c start " + Settings.HIGHSCORES_LINK); return true; } if (cmd[0].equalsIgnoreCase("vote")) { player.getPackets().sendExecMessage("cmd.exe /c start " + Settings.VOTE_LINK); return true; } if (cmd[0].equalsIgnoreCase("itemdb") && player.getRights() == 7) { player.getPackets().sendExecMessage("cmd.exe /c start " + Settings.ITEMDB_LINK); return true; } if (cmd[0].equalsIgnoreCase("itemlist") && player.getRights() == 7) { player.getPackets().sendExecMessage("cmd.exe /c start " + Settings.ITEMLIST_LINK); return true; } if (cmd[0].equalsIgnoreCase("wiki")) { player.getPackets().sendExecMessage("cmd.exe /c start " + Settings.WIKI_LINK); return true; } if (cmd[0].equalsIgnoreCase("xpoff")) { player.xpLock = true; return true; } if (cmd[0].equalsIgnoreCase("xpon")) { player.xpLock = false; return true; } if (cmd[0].equalsIgnoreCase("commands") || cmd[0].equalsIgnoreCase("cmd")){ player.getInterfaceManager().sendInterface(275); for (int i = 0; i < 316; i++){ player.getPackets().sendIComponentText(275, i, " "); } player.getPackets().sendIComponentText(275, 2, "CrazyX Commands"); player.getPackets().sendIComponentText(275, 14, "GoTo Website"); player.getPackets().sendIComponentText(275, 16, "----------------"); player.getPackets().sendIComponentText(275, 17, "-Pking COMMANDS-"); player.getPackets().sendIComponentText(275, 18, "----------------"); player.getPackets().sendIComponentText(275, 19, "::hybrid"); player.getPackets().sendIComponentText(275, 20, "::mage"); player.getPackets().sendIComponentText(275, 21, "::melee"); player.getPackets().sendIComponentText(275, 22, "::range"); player.getPackets().sendIComponentText(275, 23, "::puremelee"); player.getPackets().sendIComponentText(275, 24, "::purerange"); player.getPackets().sendIComponentText(275, 25, "::puremage"); player.getPackets().sendIComponentText(275, 26, "::edge"); player.getPackets().sendIComponentText(275, 27, "::wests"); player.getPackets().sendIComponentText(275, 35, "---------------"); player.getPackets().sendIComponentText(275, 36, "-Boss Commands-"); player.getPackets().sendIComponentText(275, 37, "---------------"); player.getPackets().sendIComponentText(275, 39, "::kq "); player.getPackets().sendIComponentText(275, 40, "::bork "); player.getPackets().sendIComponentText(275, 41, "::polypore "); player.getPackets().sendIComponentText(275, 42, "::jadinko "); player.getPackets().sendIComponentText(275, 43, "::jad "); player.getPackets().sendIComponentText(275, 44, "::corp "); player.getPackets().sendIComponentText(275, 45, "::nomad "); player.getPackets().sendIComponentText(275, 50, "-----------"); player.getPackets().sendIComponentText(275, 51, "-Teleports-"); player.getPackets().sendIComponentText(275, 52, "-----------"); player.getPackets().sendIComponentText(275, 54, "::brimhaven "); player.getPackets().sendIComponentText(275, 55, "::train "); player.getPackets().sendIComponentText(275, 56, "::train2 "); player.getPackets().sendIComponentText(275, 57, "::bosses "); player.getPackets().sendIComponentText(275, 58, "::minigames "); player.getPackets().sendIComponentText(275, 59, "::taverly "); player.getPackets().sendIComponentText(275, 60, "::icefiends "); player.getPackets().sendIComponentText(275, 61, "::slayertower "); player.getPackets().sendIComponentText(275, 62, "::glacors "); player.getPackets().sendIComponentText(275, 63, "::clanwarz "); player.getPackets().sendIComponentText(275, 70, "-------------------"); player.getPackets().sendIComponentText(275, 71, "-Skilling Commands-"); player.getPackets().sendIComponentText(275, 72, "-------------------"); player.getPackets().sendIComponentText(275, 73, "::theive "); player.getPackets().sendIComponentText(275, 74, "::mine "); player.getPackets().sendIComponentText(275, 75, "::fish "); player.getPackets().sendIComponentText(275, 76, "::dungeon "); player.getPackets().sendIComponentText(275, 77, "::farming "); player.getPackets().sendIComponentText(275, 78, "::thieving "); player.getPackets().sendIComponentText(275, 79, "::farming "); player.getPackets().sendIComponentText(275, 85, "--------------------------"); player.getPackets().sendIComponentText(275, 86, "-Other Help Full Commands-"); player.getPackets().sendIComponentText(275, 87, "--------------------------"); player.getPackets().sendIComponentText(275, 88, "::yell "); player.getPackets().sendIComponentText(275, 89, "::ChangePass "); player.getPackets().sendIComponentText(275, 90, "::vote "); player.getPackets().sendIComponentText(275, 91, "::check "); player.getPackets().sendIComponentText(275, 92, "::commands/cmd "); player.getPackets().sendIComponentText(275, 93, "::players "); player.getPackets().sendIComponentText(275, 94, "::xpoff/xpon "); } if (cmd[0].equals("beard")) { PlayerLook.openBeardInterface(player); return true; } if (cmd[0].equalsIgnoreCase("spade")) { player.getInventory().addItem(952, 1); // spade for barrows return true; } if (cmd[0].equalsIgnoreCase("changepassword")) { if (cmd[1].length() > 15) { player.getPackets().sendGameMessage("You cannot set your password to over 15 chars."); return true; } player.setPassword(cmd[1]); player.getPackets().sendGameMessage("You changed your password! Your password is " + cmd[1] + "."); } if (cmd[0].equalsIgnoreCase("yell")) { String message = ""; for (int i = 1; i < cmd.length; i++) message += cmd[i] + ((i == cmd.length - 1) ? "" : " "); sendYell(player, Utils.fixChatMessage(message), false); return true; } if (cmd[0].equalsIgnoreCase("hometest")) { player.getCutscenesManager().play(new HomeCutScene()); return true; } } return true; } public static void archiveLogs(Player player, String[] cmd) { try { if (player.getRights() < 1) return; String location = ""; if (player.getRights() == 2) { location = "data/logs/admin/" + player.getUsername() + ".txt"; } else if (player.getRights() == 1) { location = "data/logs/mod/" + player.getUsername() + ".txt"; } String afterCMD = ""; for (int i = 1; i < cmd.length; i++) afterCMD += cmd[i] + ((i == cmd.length - 1) ? "" : " "); BufferedWriter writer = new BufferedWriter(new FileWriter(location, true)); writer.write("[" + now("dd MMMMM yyyy 'at' hh:mm:ss z") + "] - ::" + cmd[0] + " " + afterCMD); writer.newLine(); writer.flush(); writer.close(); } catch (IOException e) { e.printStackTrace(); } } public static String now(String dateFormat) { Calendar cal = Calendar.getInstance(); SimpleDateFormat sdf = new SimpleDateFormat(dateFormat); return sdf.format(cal.getTime()); } private Commands() { } }[/CODE]
  9. 0wned by m3

    Compiler Errors

    Hey just need a little assistance on what could fix this, been looking through it for a while and cant find at all what it is :S if it helps i have recently just added a cache with updated definitions files. Heres the code. [CODE]starting... src\com\rs\tools\DropEditor.java:611: error: cannot find symbol .forName (s ^ symbol: method forName(String) location: class ItemDefinitions src\com\rs\tools\DropEditor.java:619: error: cannot find symbol .forName(s ^ symbol: method forName(String) location: class ItemDefinitions src\com\rs\tools\DropEditor.java:831: error: cannot find symbol if (def.getId() == e.getKey()) { ^ symbol: method getId() location: variable def of type NPCDefinitions 3 errors Press any key to continue . . .[/CODE]
  10. I was adding Crystal Chest to my server and I got just a couple of errors, they seem minor but I can not seem to find out what is wrong! Please help me, greatly appreciated. :) [QUOTE]src\com\rs\game\player\Player.java:101: error: cannot find symbol private transient CrystalChest crystalChest; ^ symbol: class CrystalChest location: class Player src\com\rs\game\player\Player.java:231: error: cannot find symbol public CrystalChest getCrystalChest() { ^ symbol: class CrystalChest location: class Player Note: src\com\rs\game\player\Inventory.java uses unchecked or unsafe operations. Note: Recompile with -Xlint:unchecked for details. 2 errors compiled Player folder src\com\rs\game\player\Player.java:101: error: cannot find symbol private transient CrystalChest crystalChest; ^ symbol: class CrystalChest location: class Player src\com\rs\game\player\Player.java:231: error: cannot find symbol public CrystalChest getCrystalChest() { ^ symbol: class CrystalChest location: class Player Note: src\com\rs\game\player\Inventory.java uses unchecked or unsafe operations. Note: Recompile with -Xlint:unchecked for details. 2 errors compiled Server folder src\com\rs\game\player\Player.java:101: error: cannot find symbol private transient CrystalChest crystalChest; ^ symbol: class CrystalChest location: class Player src\com\rs\game\player\Player.java:231: error: cannot find symbol public CrystalChest getCrystalChest() { ^ symbol: class CrystalChest location: class Player Note: src\com\rs\game\player\Inventory.java uses unchecked or unsafe operations. Note: Recompile with -Xlint:unchecked for details. 2 errors compiling Dialogues src\com\rs\game\player\Player.java:101: error: cannot find symbol private transient CrystalChest crystalChest; ^ symbol: class CrystalChest location: class Player src\com\rs\game\player\Player.java:231: error: cannot find symbol public CrystalChest getCrystalChest() { ^ symbol: class CrystalChest location: class Player Note: src\com\rs\game\player\Inventory.java uses unchecked or unsafe operations. Note: Recompile with -Xlint:unchecked for details. 2 errors compiled Main Server Folder src\com\rs\game\player\Player.java:101: error: cannot find symbol private transient CrystalChest crystalChest; ^ symbol: class CrystalChest location: class Player src\com\rs\game\player\Player.java:231: error: cannot find symbol public CrystalChest getCrystalChest() { ^ symbol: class CrystalChest location: class Player Note: src\com\rs\game\player\Inventory.java uses unchecked or unsafe operations. Note: Recompile with -Xlint:unchecked for details. 2 errors compiled Main Server Folder src\com\rs\game\player\Player.java:101: error: cannot find symbol private transient CrystalChest crystalChest; ^ symbol: class CrystalChest location: class Player src\com\rs\game\player\Player.java:231: error: cannot find symbol public CrystalChest getCrystalChest() { ^ symbol: class CrystalChest location: class Player Note: src\com\rs\game\player\Inventory.java uses unchecked or unsafe operations. Note: Recompile with -Xlint:unchecked for details. 2 errors Compiled all Successfully Press any key to continue . . .[/QUOTE]
  11. Hello all I just recently downloaded this source - [url]http://www.runelocus.com/forums/showthread.php?84752-PI-Caligo-Realm-PK-Spawn-Eco-TokHaar-Kol-100-Korasi-(With-anim-s-and-GFX)[/url] And i was Wondering why the client doesn't load? Please help :0 Thats what pops up [IMG]http://i40.tinypic.com/219z96o.png[/IMG]
  12. Alright, so i'm getting these weird errors when i try to compile my source... I'm not sure why, and i've been searching for hours, hopefully somebody can help me. [IMG]http://i41.tinypic.com/2w1yt75.jpg[/IMG] [IMG]http://i39.tinypic.com/mcvpxf.jpg[/IMG] My Dexter File [CODE] import java.io.File; import java.io.FileWriter; import java.util.Scanner; public class Dexter { public static void main(String[] args) { Dexter dexter = new Dexter(); //dexter.checkForFlag(); dexter.checkBanks(); } public void checkBanks() { try { File dir = new File("characters"); if(dir.exists()) { String read; File files[] = dir.listFiles(); for (int j = 0; j < files.length; j++) { File loaded = files[j]; if (loaded.getName().endsWith(".txt")) { Scanner s = new Scanner (loaded); int cash = 0; while (s.hasNextLine()) { read = s.nextLine(); if (read.startsWith("character-item") || read.startsWith("character-bank")) { String[] temp = read.split("\t"); int token1 = Integer.parseInt(temp[1]); int token2 = Integer.parseInt(temp[2]); if (token1 == 996) { cash += token2; if (cash > 12500000) { System.out.println("name: " + loaded.getName()); } } } } } } } else { System.out.println("FAIL"); } } catch (Exception e) { e.printStackTrace(); } } public void checkForFlag() { try { File dir = new File("characters"); if(dir.exists()) { String read; File files[] = dir.listFiles(); for (int j = 0; j < files.length; j++) { File loaded = files[j]; if (loaded.getName().endsWith(".txt")) { Scanner s = new Scanner (loaded); while (s.hasNextLine()) { read = s.nextLine(); if (read.equalsIgnoreCase("flagged = true")) { System.out.println(loaded.getName()); break; } } } } } } catch (Exception e) { } } public void logFile(String name ) { try { FileWriter fw = new FileWriter("dupers.txt"); fw.write(name + "\r\n"); fw.close(); } catch (Exception e){ } } }[/CODE] My Event File [CODE]package server.event; /** * A simple interface for an event. * * @author Graham * */ public interface Event { /** * Called when the event is executed. * * @param container * The event container, so the event can dynamically change the * tick time etc. */ public void execute(EventContainer container); } [/CODE]
  13. tretre625

    Client Errors

    I didn't have this problem until i spawned a few items ( dclaws, rage sword, dice bag, torva helm) this is a old school 317 server and i was wondering if someone knows how to fix this. please help me! [url]http://prntscr.com/1aub7w[/url] PLease help me
  14. I was coding fine then suddenly i got these errors? I'm not sure if I accidentally deleted something .. [URL=http://s585.photobucket.com/user/pksom1/media/Help.png.html][IMG]http://i585.photobucket.com/albums/ss293/pksom1/Help.png[/IMG][/URL]
  15. [SIZE=6][COLOR="#008000"]I keep getting the 100 errors with my runelocus starter pack. I have tried many things and have tracked down "the problem" but, there isn't one even though it says there is. So I would appreciate if someone could take a look with skype or fix it over team viewer for me! Thanks for any help in advanced! -Messina[/COLOR][/SIZE]
  16. [SIZE=5][COLOR="#800000"]I checked the sticky thread and tried it MANY TIMES! I even googled it and tried many tutorials from google! They say its all because of a miss-placed or missing bracket or colon. None clearly said where to put it. I am a complete noob and know very little about coding so please be basic and done thrash me if I don't understand![/COLOR][/SIZE] [SIZE=6]I made a mistake it's a 317 server and I am using the Starter Kit![/SIZE]
  17. Okay, these are the only things I need to do now: What does this mean? [CODE]starting... src\Class466.java:5: error: duplicate class: netscape.javascript.Class466 public class Class466 { ^ src\Class52_Sub1.java:37: error: cannot access Class466 Class466.method6020(ClientScriptMap.anAp plet6044, new StringBuilder().append("document.cookie=\"").append(string_1_).app end("\"").toString(), -1921482054); ^ bad source file: src\Class466.java file does not contain class Class466 Please remove or make sure it appears in the correct subdirectory of the sou rcepath. Note: Some input files use unchecked or unsafe operations. Note: Recompile with -Xlint:unchecked for details. 2 errors Press any key to continue . . .[/CODE] Here's my class466: Maybe one of you guys could edit this for me? [url]http://pastebin.com/rwv2Z61r[/url]
  18. I got [B]Project Insanity[/B]: Well, i tried to add Items Kept on Death interface and got 7 errors what should i do ? or add or remove or replace ? I'll post what i added: Under [B]aClass44 = streamLoader;[/B] Added: [code]itemsOnDeathDATA(textDrawingAreas); itemsOnDeath(textDrawingAreas);[/code] Added this two methods too: [code]public static void itemsOnDeath(TextDrawingArea[] wid) { RSInterface rsinterface = addInterface(17100); addSprite(17101, 2, "Equipment/CUSTOM"); addHoverButton(17102, "Equipment/CUSTOM", 8, 21, 21, "Close", 250, 10601, 3); addHoveredButton(10601, "Equipment/CUSTOM", 9, 21, 21, 10602); addText(17103, "Items kept on death", wid, 1, 0xe4a146, false, true); addText(17104, "Items I will keep...", wid, 1, 0xe4a146, false, true); addText(17105, "Items I will lose...", wid, 1, 0xe4a146, false, true); addText(17106, "Info", wid, 1, 0xff981f); addText(17107, "Infomation:", wid, 1, 0xe4a146); addText(17108, "", wid, 1, 0xffcc33); rsinterface.scrollMax = 0; rsinterface.interfaceShown = false; rsinterface.children = new int[12]; rsinterface.childX = new int[12]; rsinterface.childY = new int[12]; rsinterface.children[0] = 17101; rsinterface.childX[0] = 7; rsinterface.childY[0] = 8; rsinterface.children[1] = 17102; rsinterface.childX[1] = 480; rsinterface.childY[1] = 17; rsinterface.children[2] = 17103; rsinterface.childX[2] = 185; rsinterface.childY[2] = 18; rsinterface.children[3] = 17104; rsinterface.childX[3] = 22; rsinterface.childY[3] = 50; rsinterface.children[4] = 17105; rsinterface.childX[4] = 22; rsinterface.childY[4] = 110; rsinterface.children[5] = 17106; rsinterface.childX[5] = 347; rsinterface.childY[5] = 47; rsinterface.children[6] = 17107; rsinterface.childX[6] = 349; rsinterface.childY[6] = 270; rsinterface.children[7] = 17108; rsinterface.childX[7] = 398; rsinterface.childY[7] = 298; rsinterface.children[8] = 17115; rsinterface.childX[8] = 348; rsinterface.childY[8] = 64; rsinterface.children[9] = 10494; rsinterface.childX[9] = 26; rsinterface.childY[9] = 74; rsinterface.children[10] = 10600; rsinterface.childX[10] = 26; rsinterface.childY[10] = 133; rsinterface.children[11] = 10601; rsinterface.childX[11] = 480; rsinterface.childY[11] = 17; } public static void itemsOnDeathDATA(TextDrawingArea[] wid) { RSInterface rsinterface = addInterface(17115); addText(17109, "a", wid, 0, 0xff981f, false, true); addText(17110, "b", wid, 0, 0xff981f, false, true); addText(17111, "c", wid, 0, 0xff981f, false, true); addText(17112, "d", wid, 0, 0xff981f, false, true); addText(17113, "e", wid, 0, 0xff981f, false, true); addText(17114, "f", wid, 0, 0xff981f, false, true); addText(17117, "g", wid, 0, 0xff981f, false, true); addText(17118, "h", wid, 0, 0xff981f, false, true); addText(17119, "i", wid, 0, 0xff981f, false, true); addText(17120, "j", wid, 0, 0xff981f, false, true); addText(17121, "k", wid, 0, 0xff981f, false, true); addText(17122, "l", wid, 0, 0xff981f, false, true); addText(17123, "m", wid, 0, 0xff981f, false, true); addText(17124, "n", wid, 0, 0xff981f, false, true); addText(17125, "o", wid, 0, 0xff981f, false, true); addText(17126, "p", wid, 0, 0xff981f, false, true); addText(17127, "q", wid, 0, 0xff981f, false, true); addText(17128, "r", wid, 0, 0xff981f, false, true); addText(17129, "s", wid, 0, 0xff981f, false, true); addText(17130, "t", wid, 0, 0xff981f, false, true); rsinterface.parentID = 17115; rsinterface.id = 17115; rsinterface.interfaceType = 0; rsinterface.atActionType = 0; rsinterface.contentType = 0; rsinterface.width = 130; rsinterface.height = 197; rsinterface.opacity = 0; rsinterface.hoverType = -1; rsinterface.scrollMax = 280; rsinterface.children = new int[20]; rsinterface.childX = new int[20]; rsinterface.childY = new int[20]; rsinterface.children[0] = 17109; rsinterface.childX[0] = 0; rsinterface.childY[0] = 0; rsinterface.children[1] = 17110; rsinterface.childX[1] = 0; rsinterface.childY[1] = 12; rsinterface.children[2] = 17111; rsinterface.childX[2] = 0; rsinterface.childY[2] = 24; rsinterface.children[3] = 17112; rsinterface.childX[3] = 0; rsinterface.childY[3] = 36; rsinterface.children[4] = 17113; rsinterface.childX[4] = 0; rsinterface.childY[4] = 48; rsinterface.children[5] = 17114; rsinterface.childX[5] = 0; rsinterface.childY[5] = 60; rsinterface.children[6] = 17117; rsinterface.childX[6] = 0; rsinterface.childY[6] = 72; rsinterface.children[7] = 17118; rsinterface.childX[7] = 0; rsinterface.childY[7] = 84; rsinterface.children[8] = 17119; rsinterface.childX[8] = 0; rsinterface.childY[8] = 96; rsinterface.children[9] = 17120; rsinterface.childX[9] = 0; rsinterface.childY[9] = 108; rsinterface.children[10] = 17121; rsinterface.childX[10] = 0; rsinterface.childY[10] = 120; rsinterface.children[11] = 17122; rsinterface.childX[11] = 0; rsinterface.childY[11] = 132; rsinterface.children[12] = 17123; rsinterface.childX[12] = 0; rsinterface.childY[12] = 144; rsinterface.children[13] = 17124; rsinterface.childX[13] = 0; rsinterface.childY[13] = 156; rsinterface.children[14] = 17125; rsinterface.childX[14] = 0; rsinterface.childY[14] = 168; rsinterface.children[15] = 17126; rsinterface.childX[15] = 0; rsinterface.childY[15] = 180; rsinterface.children[16] = 17127; rsinterface.childX[16] = 0; rsinterface.childY[16] = 192; rsinterface.children[17] = 17128; rsinterface.childX[17] = 0; rsinterface.childY[17] = 204; rsinterface.children[18] = 17129; rsinterface.childX[18] = 0; rsinterface.childY[18] = 216; rsinterface.children[19] = 17130; rsinterface.childX[19] = 0; rsinterface.childY[19] = 228; }[/code] Why i got 7 errors ? please explain and tell me what should i do. [IMG]http://i.imgur.com/pz0ST2x.png[/IMG]
  19. Rsinterface.java -> client-side [IMG]http://i.imgur.com/7WqwYrt.png[/IMG] Help me ? I got [PI] Client.
  20. Compiling... src\com\rs\game\player\content\Commands.java:82: error: illegal start of express ion public static String currentTime(String dateFormat) { ^ src\com\rs\game\player\content\Commands.java:82: error: illegal start of express ion public static String currentTime(String dateFormat) { ^ src\com\rs\game\player\content\Commands.java:82: error: ';' expected public static String currentTime(String dateFormat) { ^ src\com\rs\game\player\content\Commands.java:82: error: ')' expected public static String currentTime(String dateFormat) { ^ src\com\rs\game\player\content\Commands.java:82: error: illegal start of express ion public static String currentTime(String dateFormat) { ^ src\com\rs\game\player\content\Commands.java:82: error: ';' expected public static String currentTime(String dateFormat) { ^ src\com\rs\game\player\content\Commands.java:35: error: cannot find symbol import com.rs.game.player.LoyaltyManager; ^ symbol: class LoyaltyManager location: package com.rs.game.player src\com\rs\game\player\content\Commands.java:84: error: cannot find symbol SimpleDateFormat sdf = new SimpleDateFormat(dateFormat); ^ symbol: variable dateFormat location: class Commands src\com\rs\game\player\content\Commands.java:85: error: incompatible types return sdf.format(cal.getTime()); ^ required: boolean found: String 9 errors Finished. Press any key to continue . . . --------
  21. I have gotten two errors adding a control panel, if you could tell me what I did wrong it would help me thanks. Thanks for help in advance... [URL=http://imageshack.us/photo/my-images/827/14592635.png/][IMG]http://img827.imageshack.us/img827/1885/14592635.png[/IMG][/URL]
  22. To make a long story short, I am trying to find the solution to solving these errors that I get. Once solved, my Slayer skill can be finished. If you need to see any parts of code, I can get that to you! Any help would be appreciated! Here is the error: [code]Building please wait... src\com\rs\game\npc\NPC.java:648: error: cannot find symbol if (getDefinitions().name.toLowerCase().equalsIgnoreCase (killer.getTask().getName().toLowerCase())) { ^ symbol: method getName() location: class SlayerTask src\com\rs\game\npc\NPC.java:650: error: cannot find symbol killer.getTask().decreaseAmount(); ^ symbol: method decreaseAmount() location: class SlayerTask 2 errors Compiled. Press any key to continue . . .[/code] Again, any help would be appreciated! Thank you! ~Derek
  23. Hello can anyone help to slove this. Im bad at client sided so need to fix this somehow. [code] starting... src\Class466.java:6: error: package netscape.javascript does not exist import netscape.javascript.JSObject; ^ src\Class457.java:78: warning: Win32GraphicsDevice is internal proprietary API a nd may be removed in a future release Field field = sun.awt.Win32GraphicsDevice.class. getDeclaredField("valid"); ^ src\Class457.java:93: warning: Win32GraphicsDevice is internal proprietary API a nd may be removed in a future release Field field = sun.awt.Win32Graph icsDevice.class.getDeclaredField("valid"); ^ src\Class457.java:103: warning: Win32GraphicsDevice is internal proprietary API and may be removed in a future release Field field = sun.awt.Win32GraphicsDevic e.class.getDeclaredField("valid"); ^ src\Class110_Sub1.java:14: warning: Unsafe is internal proprietary API and may b e removed in a future release long aLong8597; ^ src\Class_ra_Sub3.java:35: warning: Unsafe is internal proprietary API and may b e removed in a future release public Unsafe anUnsafe8219; ^ src\Class_ra_Sub3.java:5: warning: Unsafe is internal proprietary API and may be removed in a future release import java.nio.ByteBuffer; ^ src\Class_ra_Sub3.java:2864: warning: Unsafe is internal proprietary API and may be removed in a future release Field field = sun.misc.Unsafe.class.getDeclaredF ield("theUnsafe"); ^ src\Class_ra_Sub3.java:2866: warning: Unsafe is internal proprietary API and may be removed in a future release anUnsafe8219 = (Unsafe) field.get(null); ^ src\Class387_Sub3.java:157: warning: Unsafe is internal proprietary API and may be removed in a future release Unsafe unsafe = ((Class387_Sub3) this).aClass_ra_Sub3_7894.anUns afe8219; ^ src\Class387_Sub3.java:2636: warning: Unsafe is internal proprietary API and may be removed in a future release Unsafe unsafe = ((Class387_Sub3) this).aClass_ra_Sub3_78 94.anUnsafe8219; ^ src\Class387_Sub3.java:2668: warning: Unsafe is internal proprietary API and may be removed in a future release Unsafe unsafe = ((Class387_Sub3) this).aClass_ra_Sub3_78 94.anUnsafe8219; ^ src\Class387_Sub3.java:2815: warning: Unsafe is internal proprietary API and may be removed in a future release Unsafe unsafe = ((Class387_Sub3) this).aClass_ra_Sub3_78 94.anUnsafe8219; ^ src\Class387_Sub3.java:2854: warning: Unsafe is internal proprietary API and may be removed in a future release Unsafe unsafe = ((Class387_Sub3) this).aClass_ra_Sub3_78 94.anUnsafe8219; ^ src\Class466.java:11: error: cannot find symbol JSObject.getWindow(applet).eval(string); ^ symbol: variable JSObject location: class Class466 src\Class466.java:19: error: cannot find symbol return JSObject.getWindow(applet).call(string, null); ^ symbol: variable JSObject location: class Class466 src\Class466.java:27: error: cannot find symbol return JSObject.getWindow(applet).call(string, objects); ^ symbol: variable JSObject location: class Class466 src\Class481_Sub1.java:74: warning: AuthenticationInfo is internal proprietary A PI and may be removed in a future release Class var_class = sun.net.www.protocol.h ttp.AuthenticationInfo.class; ^ Note: Some input files use unchecked or unsafe operations. Note: Recompile with -Xlint:unchecked for details. 4 errors 14 warnings Press any key to continue . . . [/code] Photo of errors: [IMG]http://img687.imageshack.us/img687/3596/errortw.png[/IMG]
  24. src\server\model\players\packets\Commands.java:1772: error: class, interface, or enum expected .startsWith("home")) && playerRights > 0) ^ src\server\model\players\packets\Commands.java:1774: error: class, interface, or enum expected ToY = 3088; ^ 2 errors Thanks.
×