I've tried every which way I can, but it never shows up in the client.
Should server:createPanel work?
- h0tw1r3
- Closed
-
-
It should work, this is the syntax for the function: createPanel(positionx, positiony, width, height, color [0xRRGGBBAA]);
Note that the width and height are absolute (pixel) values, while positionx and -y are relative values (0-1). Perhaps we should change this mixture of absolute and relative values in the future^^
Example:
[lua]-- create a new panel
local panel = Gui:createPanel(0.1, 0.1, 200, 100, 0xFF0000AA);
-- display the panel on the player's screen
event.player:addGuiElement(panel);[/lua] -
Thanks. I'll try it again tomorrow. Was using relative values like 0.1 and 0.9.
Not sure how useful it will be without relative values though.
-
[...]Not sure how useful it will be without relative values though.
Yes, we will most likely change that in the future.
Participate now!
Don’t have an account yet? Create a new account now and be part of our community!