PDA

View Full Version : Rather weird GUI problem


Codein
12-26-2007, 07:56 PM
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:

//#CLIENTSIDE

function onCreated() {
Message_Window.destroy();

new GuiControlProfile("MessageWindow") {
bitmap = "guiquian_messagewindow.png";
transparency = 0.5;
}

new GuiWindowCtrl("Message_Window") {
profile = "MessageWindow";
x = (screenwidth - screenwidth) + 180;
y = (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
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
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
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
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
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/showthread.php?t=77728&highlight=GUI

Crow
12-27-2007, 01:21 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/showthread.php?t=77728&highlight=GUI

Problem was already solved Dusty D:

Codein
12-27-2007, 01:35 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/showthread.php?t=77728&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.