Ahh... Well lets try to do this with an normal momentary button then
Make an normal button.
Go to Clicked Script and enter this:
hsig, rc = mc.mcSignalGetHandle(inst, mc.OSIG_OUTPUT0);
local state = false;
local VarIamTestingFor = SomeThingIamWatchingOrSettingOrValue;
if VarIamTestingFor == WhatSetsTheOutputToOn then
state = true;
else
state = false;
end
mc.mcSignalSetState(hsig, state);
Now the button will set Output 0 to Active until you somehow deactivates it.
So if you want to deactivate it with an other button you wil do the same just enter the same script and invert the "true" to "false" and the "false" to "true"
As this:
hsig, rc = mc.mcSignalGetHandle(inst, mc.OSIG_OUTPUT0);
local state = true;
local VarIamTestingFor = SomeThingIamWatchingOrSettingOrValue;
if VarIamTestingFor == WhatSetsTheOutputToOn then
state = false;
else
state = true;
end
mc.mcSignalSetState(hsig, state);
This script is an example taken from a PDF made By Scott “Poppa Bear”
The PDF is easy to find on web. Google for Poppa Bear LUA.
1 step closer now ?
Sor