package NET.worlds.console; import NET.worlds.scape.FrameEvent; import NET.worlds.scape.Pilot; import java.awt.Container; public class ChatPart extends DuplexPart { private Window renderWindow; private DefaultConsole console; private static final String activateVCselfWhisper = "&|+debug= 0 && ii < s.length() - 1 && s.charAt(ii + 1) == 'u') { Pilot.sendText(Console.parseUnicode(s)); } else { Pilot.sendText(s); } } @Override public void activate(Console c, Container f, Console prev) { super.activate(c, f, prev); this.console = (DefaultConsole)c; } @Override public void deactivate() { super.deactivate(); this.renderWindow = null; this.console = null; } @Override public synchronized boolean handle(FrameEvent f) { boolean ret = super.handle(f); if (this.renderWindow == null && this.console != null) { RenderCanvas rc = this.console.getRender(); if (rc != null) { Window w = rc.getWindow(); if (w != null) { try { w.hookChatLine(this.line); this.renderWindow = w; } catch (WindowNotFoundException var6) { } } } } return ret; } private void triggerLocalDebug(String s) { if (s.startsWith("&|+debug