Toggle Buttons for units with LUS?

Toggle Buttons for units with LUS?

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

Moderator: Moderators

Post Reply
User avatar
bobthedinosaur
Blood & Steel Developer
Posts: 2702
Joined: 25 Aug 2004, 13:31

Toggle Buttons for units with LUS?

Post by bobthedinosaur »

I'm looking for a version of the toggle button but that work for units that use LUS. Am I imagining that this was done once before, because I can't seem to find it?
User avatar
FLOZi
MC: Legacy & Spring 1944 Developer
Posts: 6242
Joined: 29 Apr 2005, 01:14

Re: Toggle Buttons for units with LUS?

Post by FLOZi »

?

You can add as many toggle buttons as you like in a gadget. I'm guessing you then want LUS to be informed of the change or something??
User avatar
smoth
Posts: 22309
Joined: 13 Jan 2005, 00:46

Re: Toggle Buttons for units with LUS?

Post by smoth »

toggle button?
User avatar
knorke
Posts: 7971
Joined: 22 Feb 2006, 01:02

Re: Toggle Buttons for units with LUS?

Post by knorke »

On the wiki is an example that allows you turn toggle movement of flash tanks between "drive slow, turn fast" and "drive fast, turn slow."
Did not find it now though.
You could just add a CallAsUnit() to notify the unit script about the change of the toggle button.
Post Reply

Return to “Lua Scripts”