Graal Forums

Graal Forums (https://forums.graalonline.com/forums/index.php)
-   NPC Scripting (https://forums.graalonline.com/forums/forumdisplay.php?f=8)
-   -   ChatBar (https://forums.graalonline.com/forums/showthread.php?t=81577)

cbk1994 08-31-2008 03:54 PM

ChatBar
 
What's the best way to destroy the chat bar?

I use ChatBar.destroy() now, but it produces some annoying errors in the F2 window.

Is there a better way?

Inverness 08-31-2008 04:01 PM

Just move it outside of the screen? And make sure to do it again when the GraalControl is resized.

[email protected] 08-31-2008 04:03 PM

awww, you rock my world Inverness!! he he he ^^ ^^ ^^

xXziroXx 08-31-2008 04:25 PM

ChatBar.visible = false; in a timeout?

[email protected] 08-31-2008 04:47 PM

whats the point?

HTML Code:

function onCreated() {
  this.moveChatBar = function() {
    chatbar.y = GraalControl.height + 30;
  }
}

function GraalControl.onResize() {
  this.moveChatBar();
}


xXziroXx 08-31-2008 05:41 PM

It's still active though, thus stealing focus, right?

cbk1994 08-31-2008 05:50 PM

Yes, it would still be active, I would think.

And, visible = false in a timeout will not work. It still shows when you hit Tab. I need it to go to another source. I wasn't sure if there was some function like destroyChatBar() or anything.

DustyPorViva 08-31-2008 06:26 PM

Try this:
PHP Code:

function ChatBar.onShow() {
  
ChatBar.hide();



cbk1994 08-31-2008 06:32 PM

Quote:

Originally Posted by DustyPorViva (Post 1419370)
Try this:
PHP Code:

function ChatBar.onShow() {
  
ChatBar.hide();



I've done that before, it shows for a second, then hides.

DustyPorViva 08-31-2008 06:37 PM

Change the alpha of it to 0 :)

Inverness 08-31-2008 06:51 PM

Dusty beat me to it.

And its not stealing focus if you have something else take the focus when you push tab when GraalControl is focused.


All times are GMT +2. The time now is 09:47 AM.

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2026, vBulletin Solutions Inc.
Copyright (C) 1998-2019 Toonslab All Rights Reserved.