Graal Forums

Graal Forums (https://forums.graalonline.com/forums/index.php)
-   NPC Scripting (https://forums.graalonline.com/forums/forumdisplay.php?f=8)
-   -   Rather weird GUI problem (https://forums.graalonline.com/forums/showthread.php?t=78078)

Codein 12-26-2007 07:56 PM

Rather weird GUI problem
 
2 Attachment(s)
I've having a really strange problem with setting a custom gui bitmap.

I'm using a 24-bit PNG with transparency.

This is the code I'm using:

PHP Code:

//#CLIENTSIDE

function onCreated() {
  
Message_Window.destroy();
  
  new 
GuiControlProfile("MessageWindow") {
    
bitmap "guiquian_messagewindow.png";
    
transparency 0.5;
  }

  new 
GuiWindowCtrl("Message_Window") {
    
profile "MessageWindow";
    
= (screenwidth screenwidth) + 180;
    
= (screenheight screenheight) + 20;
    
width screenwidth 200;
    
height 100;
    
text "message bar";
    
//No Control
    
canresize 0;
    
canclose 0;
    
canmove 0;
    
canmaximize 0;
    
canminimize 1;
  }
 


I've attached the image I've used and a screenshot of what's going on.

cbk1994 12-26-2007 08:17 PM

Where are the red lines in the gui image?

Crow 12-26-2007 08:22 PM

Good question. Just incase you didnt know, the red lines are totally needed.

Codein 12-26-2007 08:26 PM

Aye, I just figured this out and got it working. Problem solved :)

Thanks for quick reply.

Might aswell put this here aswell:

How do you make the ENTIRE guiwindow semi transparent rather than the fill in the middle?

cbk1994 12-26-2007 09:52 PM

Quote:

Originally Posted by Codein (Post 1365958)
Aye, I just figured this out and got it working. Problem solved :)

Thanks for quick reply.

Might aswell put this here aswell:

How do you make the ENTIRE guiwindow semi transparent rather than the fill in the middle?

Im pretty sure that this was asked bejore and steefan said its not posible

My fingers are too big for this stupid phone!

Codein 12-26-2007 10:02 PM

Blah, what a waste of time. Images it is then.

coreys 12-26-2007 10:17 PM

You could always use the Gui Controls alpha variable, you know...

bscharff 12-26-2007 10:59 PM

Who's steefan?

cbk1994 12-26-2007 11:01 PM

Quote:

Originally Posted by coreys (Post 1365986)
You could always use the Gui Controls alpha variable, you know...

Doesn't that only change the background of the window?

cbk1994 12-26-2007 11:05 PM

Quote:

Originally Posted by bscharff (Post 1365997)
Who's steefan?

Obviously you have never tried typing on the car on an iPhone.

Sorry for double post, can't copy and paste on iPhone.

coreys 12-26-2007 11:10 PM

Quote:

Originally Posted by cbkbud (Post 1365999)
Doesn't that only change the background of the window?

o.o nope
Changes the alpha of the entire window, and it's child controls (unless you change the alpha in those child controls as well)

Codein 12-27-2007 12:41 AM

Quote:

Originally Posted by coreys (Post 1366006)
o.o nope
Changes the alpha of the entire window, and it's child controls (unless you change the alpha in those child controls as well)

Ah, it wouldn't mattered to me anyway. I had other major problems with it. I've scripted, fully working, with images and showtext() now.

Thanks for the responses anyway, much appreciated <3.

DustyPorViva 12-27-2007 01:18 AM

I've had this similar problem before. It means your layout of the GUI is wrong somehow(even a wrong pixel in a place can mess it up). Check out:
http://forums.graalonline.com/forums...&highlight=GUI

Crow 12-27-2007 01:21 AM

Quote:

Originally Posted by DustyPorViva (Post 1366059)
I've had this similar problem before. It means your layout of the GUI is wrong somehow(even a wrong pixel in a place can mess it up). Check out:
http://forums.graalonline.com/forums...&highlight=GUI

Problem was already solved Dusty D:

Codein 12-27-2007 01:35 AM

Quote:

Originally Posted by DustyPorViva (Post 1366059)
I've had this similar problem before. It means your layout of the GUI is wrong somehow(even a wrong pixel in a place can mess it up). Check out:
http://forums.graalonline.com/forums...&highlight=GUI

Aye, I realised this. However, using GUI controls created other problems aswell. I've used showimg/showtext. I've achieved the effect I wanted, without the headaches.


All times are GMT +2. The time now is 12:29 PM.

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