Ticket #496 (closed defect: fixed)

Opened 5 months ago

Last modified 5 months ago

Purepubbot Arena Packet Bug

Reported by: dezmond Owned by: Dexter
Priority: normal Component: Bots - PubHub/PubBot
Version: Latest version from repository Severity: minor
Keywords: Cc:

Description (last modified by Maverick) (diff)

I was in dev zone and kept getting this error when !spawn purepubbot:

at twcore.bots.purepubbot.purepubbot.handleEvent(purepubbot.java:386)
	at twcore.core.net.GamePacketInterpreter.handleArenaList(GamePacketInterpreter.java:1144)
	at twcore.core.net.GamePacketInterpreter.translateNormalPacket(GamePacketInterpreter.java:335)
	at twcore.core.net.GamePacketInterpreter.translateGamePacket(GamePacketInterpreter.java:113)
	at twcore.core.net.ReliablePacketHandler.handleReliableMessage(ReliablePacketHandler.java:89)
	at twcore.core.net.GamePacketInterpreter.translateSpecialPacket(GamePacketInterpreter.java:405)
	at twcore.core.net.GamePacketInterpreter.translateGamePacket(GamePacketInterpreter.java:111)
	at twcore.core.net.GamePacketInterpreter.translateSpecialPacket(GamePacketInterpreter.java:456)
	at twcore.core.net.GamePacketInterpreter.translateGamePacket(GamePacketInterpreter.java:111)
	at twcore.core.Session.run(Session.java:421)
26 Feb 2010 18:39:46   Dezbot (purepubbot) is disconnecting: unhandled exception
java.lang.ArrayIndexOutOfBoundsException: -1
	at twcore.bots.purepubbot.purepubbot.handleEvent(purepubbot.java:386)
26 Feb 2010 18:40:16   Dezbot (purepubbot) disconnected gracefully.

	at twcore.core.net.GamePacketInterpreter.handleArenaList(GamePacketInterpreter.java:1144)
	at twcore.core.net.GamePacketInterpreter.translateNormalPacket(GamePacketInterpreter.java:335)
	at twcore.core.net.GamePacketInterpreter.translateGamePacket(GamePacketInterpreter.java:113)
	at twcore.core.net.ReliablePacketHandler.handleReliableMessage(ReliablePacketHandler.java:89)
	at twcore.core.net.GamePacketInterpreter.translateSpecialPacket(GamePacketInterpreter.java:405)
	at twcore.core.net.GamePacketInterpreter.translateGamePacket(GamePacketInterpreter.java:111)
	at twcore.core.net.GamePacketInterpreter.translateSpecialPacket(GamePacketInterpreter.java:456)
	at twcore.core.net.GamePacketInterpreter.translateGamePacket(GamePacketInterpreter.java:111)
	at twcore.core.Session.run(Session.java:421)
java.io.FileNotFoundException: \home\bots\exception.log (The system cannot find the path specified)
	at java.io.FileOutputStream.openAppend(Native Method)
	at java.io.FileOutputStream.<init>(Unknown Source)
	at java.io.FileOutputStream.<init>(Unknown Source)
	at java.io.FileWriter.<init>(Unknown Source)
	at twcore.core.util.Tools.printStackTrace(Tools.java:187)
	at twcore.core.Session.run(Session.java:440)

Attachments

Change History

  Changed 5 months ago by Maverick

  • description modified (diff)

in reply to: ↑ description   Changed 5 months ago by Dexter

Replying to dezmond:

I was in dev zone and kept getting this error when !spawn purepubbot:

{{{
at twcore.bots.purepubbot.purepubbot.handleEvent(purepubbot.java:386)
at twcore.core.net.GamePacketInterpreter.handleArenaList(GamePacketInterpreter.java:1144)
at twcore.core.net.GamePacketInterpreter.translateNormalPacket(GamePacketInterpreter.java:335)
at twcore.core.net.GamePacketInterpreter.translateGamePacket(GamePacketInterpreter.java:113)
at twcore.core.net.ReliablePacketHandler.handleReliableMessage(ReliablePacketHandler.java:89)
at twcore.core.net.GamePacketInterpreter.translateSpecialPacket(GamePacketInterpreter.java:405)
at twcore.core.net.GamePacketInterpreter.translateGamePacket(GamePacketInterpreter.java:111)
at twcore.core.net.GamePacketInterpreter.translateSpecialPacket(GamePacketInterpreter.java:456)
at twcore.core.net.GamePacketInterpreter.translateGamePacket(GamePacketInterpreter.java:111)
at twcore.core.Session.run(Session.java:421)
26 Feb 2010 18:39:46 Dezbot (purepubbot) is disconnecting: unhandled exception
java.lang.ArrayIndexOutOfBoundsException: -1
at twcore.bots.purepubbot.purepubbot.handleEvent(purepubbot.java:386)
26 Feb 2010 18:40:16 Dezbot (purepubbot) disconnected gracefully.

at twcore.core.net.GamePacketInterpreter.handleArenaList(GamePacketInterpreter.java:1144)
at twcore.core.net.GamePacketInterpreter.translateNormalPacket(GamePacketInterpreter.java:335)
at twcore.core.net.GamePacketInterpreter.translateGamePacket(GamePacketInterpreter.java:113)
at twcore.core.net.ReliablePacketHandler.handleReliableMessage(ReliablePacketHandler.java:89)
at twcore.core.net.GamePacketInterpreter.translateSpecialPacket(GamePacketInterpreter.java:405)
at twcore.core.net.GamePacketInterpreter.translateGamePacket(GamePacketInterpreter.java:111)
at twcore.core.net.GamePacketInterpreter.translateSpecialPacket(GamePacketInterpreter.java:456)
at twcore.core.net.GamePacketInterpreter.translateGamePacket(GamePacketInterpreter.java:111)
at twcore.core.Session.run(Session.java:421)
java.io.FileNotFoundException: \home\bots\exception.log (The system cannot find the path specified)
at java.io.FileOutputStream.openAppend(Native Method)
at java.io.FileOutputStream.<init>(Unknown Source)
at java.io.FileOutputStream.<init>(Unknown Source)
at java.io.FileWriter.<init>(Unknown Source)
at twcore.core.util.Tools.printStackTrace(Tools.java:187)
at twcore.core.Session.run(Session.java:440)
}}}

hey dezmond, to fix it, do this:

.go to purepubbot.java file
.go to the public void handleEvent(ArenaList event)..
.after Arrays.sort, you'll have
String arenaToJoin = arenaNames[initialPub];

change it to

String arenaToJoin = arenaNames[initialPub+1];

. yes, just +1 there and it'll go to your # arena.

cya

  Changed 5 months ago by Dexter

  • owner set to Dexter
  • status changed from new to assigned

  Changed 5 months ago by dezmond

thx dex

  Changed 5 months ago by Dexter

  • status changed from assigned to closed
  • resolution set to fixed

Add/Change #496 (Purepubbot Arena Packet Bug)

Author


E-mail address and user name can be saved in the Preferences.


Action
as closed
Next status will be 'reopened'
 
Note: See TracTickets for help on using tickets.