build interface

build interface

Discuss Lua based Spring scripts (LuaUI widgets, mission scripts, gaia scripts, mod-rules scripts, scripted keybindings, etc...)

Moderator: Moderators

Post Reply
User avatar
kiki
Posts: 859
Joined: 05 Nov 2007, 03:06

build interface

Post by kiki »

I would like to create a totally new control panel for all units in lua. I was just wondering if there was a way to hide the default control panel. If your wondering, the features are somewhat like the warzone 2100 control panel, only without the suck features, and with other stuff.. Ill explain later i need to know this first.


While im posting, i have a question, and that is how to get rid of the background texture for control panel buttons. I want the buttons to be transparent completely, but the build icons to still show up, with about .7 alpha.
User avatar
LordMatt
Posts: 3393
Joined: 15 May 2005, 04:26

Re: build interface

Post by LordMatt »

I'm pretty sure that is all possible to do. When my lua crashes the ctrlpanel disappears, and I know noize removed the texture around the buttons.
User avatar
kiki
Posts: 859
Joined: 05 Nov 2007, 03:06

Re: build interface

Post by kiki »

So, all i have to do is crash lua. What is the most effective way to do that? Here are my ideas:

divide by 0
take the square root of 0
render something in imaginary space
caculate the volume of a singularity
attempt to render chucknorris
Gnomre
Imperial Winter Developer
Posts: 1754
Joined: 06 Feb 2005, 13:42

Re: build interface

Post by Gnomre »

Make Spring load a different ctrlpanel.txt which makes the panel 0x0 in dimensions or moves it off the screen or something like that.
User avatar
kiki
Posts: 859
Joined: 05 Nov 2007, 03:06

Re: build interface

Post by kiki »

so can this loading situation be done with lua, or at least the moving? Because I want a backup in case of lua fail. THis is the proper design.
User avatar
Forboding Angel
Evolution RTS Developer
Posts: 14673
Joined: 17 Nov 2005, 02:43

Re: build interface

Post by Forboding Angel »

Look in evolution. THere are a few neat little gadgets in there that will make your life much easier.
User avatar
kiki
Posts: 859
Joined: 05 Nov 2007, 03:06

Re: build interface

Post by kiki »

im making a widget. However, if you are interested, i can make it a gadget...
User avatar
lurker
Posts: 3842
Joined: 08 Jan 2007, 06:13

Re: build interface

Post by lurker »

I believe forb's actually referring to the widgets there.
But look at the bottom of layout.lua. I think you can remove the control panel with a single call to that function.
User avatar
kiki
Posts: 859
Joined: 05 Nov 2007, 03:06

Re: build interface

Post by kiki »

man ms notepad sux. I need to start using notepad++ again.
User avatar
CarRepairer
Cursed Zero-K Developer
Posts: 3359
Joined: 07 Nov 2007, 21:48

Re: build interface

Post by CarRepairer »

kiki wrote:man ms notepad sux. I need to start using notepad++ again.
Sometimes I like to challenge myself and use notepad--, it's even worse than notepad.
User avatar
SinbadEV
Posts: 6475
Joined: 02 May 2005, 03:56

Re: build interface

Post by SinbadEV »

gVim?
User avatar
CarRepairer
Cursed Zero-K Developer
Posts: 3359
Joined: 07 Nov 2007, 21:48

Re: build interface

Post by CarRepairer »

win-vi
Post Reply

Return to “Lua Scripts”