diff --git a/data/plugins/bootstrap.rb b/data/plugins/bootstrap.rb index b0e4a12f..907ac4dc 100644 --- a/data/plugins/bootstrap.rb +++ b/data/plugins/bootstrap.rb @@ -36,8 +36,7 @@ class String end end -# A CommandListener that executes a Proc object with two arguments: the player -# and the command. +# A CommandListener that executes a Proc object with two arguments: the player and the command. class ProcCommandListener < CommandListener def initialize(rights, block) super(rights) @@ -148,7 +147,7 @@ end def on(type, *args, &block) case type when :command then on_command(args, block) - when :message then on_message(args, block) + when :message then on_message(args, block) when :button then on_button(args, block) when :login then on_login(block) when :logout then on_logout(block) @@ -167,7 +166,7 @@ def on_button(args, proc) end end -# Defines an action to be taken upon an message. +# Defines an action to be taken upon a message. # The message can either be a symbol with the lower-case underscored class name, or the class itself. def on_message(args, proc) raise 'Message must have one or two arguments.' unless (1..2).include?(args.length) diff --git a/src/org/apollo/game/message/handler/MessageHandlerContext.java b/src/org/apollo/game/message/handler/MessageHandlerContext.java index 98af4de9..8658e1fa 100644 --- a/src/org/apollo/game/message/handler/MessageHandlerContext.java +++ b/src/org/apollo/game/message/handler/MessageHandlerContext.java @@ -1,8 +1,7 @@ package org.apollo.game.message.handler; - /** - * Provides operations specific to a {@link MessageHandler} in an {@link MessageHandlerChain}. + * Provides operations specific to a {@link MessageHandler} in a {@link MessageHandlerChain}. * * @author Graham */ diff --git a/src/org/apollo/game/message/impl/RegionChangeMessage.java b/src/org/apollo/game/message/impl/RegionChangeMessage.java index 7f5891a1..9f25e8bf 100644 --- a/src/org/apollo/game/message/impl/RegionChangeMessage.java +++ b/src/org/apollo/game/message/impl/RegionChangeMessage.java @@ -4,7 +4,7 @@ import org.apollo.game.message.Message; import org.apollo.game.model.Position; /** - * An {@link Message sent to the client instructing it to load the specified region. + * A {@link Message sent to the client instructing it to load the specified region. * * @author Graham */ diff --git a/src/org/apollo/game/model/entity/Player.java b/src/org/apollo/game/model/entity/Player.java index 5dc3bc2e..4e035737 100644 --- a/src/org/apollo/game/model/entity/Player.java +++ b/src/org/apollo/game/model/entity/Player.java @@ -674,7 +674,7 @@ public final class Player extends Mob { } /** - * Sends an {@link Message} to this player. + * Sends a {@link Message} to this player. * * @param message The message.. */ diff --git a/src/org/apollo/io/MessageHandlerChainParser.java b/src/org/apollo/io/MessageHandlerChainParser.java index fffeb1f4..49f3bbe9 100644 --- a/src/org/apollo/io/MessageHandlerChainParser.java +++ b/src/org/apollo/io/MessageHandlerChainParser.java @@ -30,7 +30,7 @@ public final class MessageHandlerChainParser { /** * The {@link XmlParser} instance. */ - private final XmlParser parser; + private final XmlParser parser = new XmlParser(); /** * Creates the message chain parser. @@ -40,7 +40,6 @@ public final class MessageHandlerChainParser { */ public MessageHandlerChainParser(InputStream is) throws SAXException { this.is = is; - parser = new XmlParser(); } /** @@ -51,7 +50,7 @@ public final class MessageHandlerChainParser { * @throws ClassNotFoundException If a class was not found. * @throws IllegalAccessException If a class was accessed illegally. * @throws InstantiationException If a class could not be instantiated. - * @return An {@link MessageHandlerChainGroup}. + * @return A {@link MessageHandlerChainGroup}. */ @SuppressWarnings("unchecked") public MessageHandlerChainGroup parse() throws IOException, SAXException, ClassNotFoundException, diff --git a/src/org/apollo/net/release/MessageDecoder.java b/src/org/apollo/net/release/MessageDecoder.java index 21221661..99f05202 100644 --- a/src/org/apollo/net/release/MessageDecoder.java +++ b/src/org/apollo/net/release/MessageDecoder.java @@ -4,7 +4,7 @@ import org.apollo.game.message.Message; import org.apollo.net.codec.game.GamePacket; /** - * A {@link MessageDecoder} decodes a {@link GamePacket} into an {@link Message} object which can be processed by the + * A {@link MessageDecoder} decodes a {@link GamePacket} into a {@link Message} object which can be processed by the * server. * * @author Graham