This is wordy and heady. Sorry if hard to follow, but it makes sense I promise.
Hopefully just a “get the words out” to help me figure it out myself.
So I understand that OS7 may bring some things to make this easier, but for now, I am working some more on a dual blade control for an Inquisitor saber.
I have my prop controls set, and I use EFFECT_USER4 to trigger ignition and retraction in the blade style.
Using EffectSequence has its quirks, such as the first COLOR shown is actually the last one in the list until the trigger is…triggered, and that’s all well and good and understood.
Everything below works fine in the Style editor, but I have no idea why in real life, I can’t get the EFFECT_RETRACTION to show.
In plain english, here’s how this works:
Power button turns main blade on.
2nd blade is set to run EffectSequence as a toggle, and is initially hidden because it starts on Black, then EFFECT_USER4 triggers a Wipe to reveal a Layers<> containing all the blade layers, with a simultaneous pseudo EFFECT_IGNITION “power surge” TransitionEffectL that uses EFFECT_USER4.
The Wipe has a built in instant Black at first to conceal the sudden base blade reveal. Then the WipeIn has instant “base blade color” for the inverse effect, as well as a retraction surge “cool down”. This all works fine, as do the pseudo EFFECT_IGNITION and EFFECT_RETRACTION since it all uses USER4.
However, If the 2nd blade is on, and the POWER button is used to turn off ALL blades (I have a standard InOutTrL Wipe built to handle that for 2nd blade style), there is no pseudo EFFECT_RETRACTION effect on the 2nd blade since it’s built in as USER4, which did not initiate the retraction. So, for uniformity, I am trying to build in a standard EFFECT_RETRACTION to handle it (as I did with the WipeIn) for when POWER is used to power off all blades.
So, what’s happening is - I need to have another toggle now, one state for when 2nd blade is active, which would basically do nothing (like show a 100% transparent color), and the other state for when the 2nd blade is running, and have that one show the EFFECT_RETRACTION “cool down” surge.
I can’t use EffectSequence<EFFECT_USER4 again, because the 2 list "COLOR"s would be TransitionEffectL<. . . . . .EFFECT_RETRACTION> and do not respect the same EFFECT_trigger…however that should be worded.
So I used a Mix to toggle them, with a nested EffectIncrementF listening for USER4, inside IsGreaterThan 100 and set the values to run exactly 0/32768 and 16384.
This works!..in the Style Editor
But when uploaded, I get just black when it certainly should be showing the toggled state of EFFECT_RETRACTION.
Additionally, the 2nd weird thing is I can have 2 TransitionEffectL’s in the Mix<> and it’s happy, but if I try solid colors (to visually test easily), I get all sorts of RGBnod overdrive errors.
Even putting the default Mix<Int<16384>,Red,Blue> as a layer anywhere in the style, it chokes on compiling. Weird.
There are comments included on the style to point out what’s what.
Any idea why I am not seeing the actual EFFECT_RETRACTION effect on the board, but it works in Style Editor?
(NOTE - I use EFFECT_CLASH in lieu of EFFECT_USER4 when testing in Style Editor)
Also…The toggle of 2nd blade on/off resets to OFF automatically when turning off the blade (a good thing, but I don’t see how that could be). This might be due to my prop as It does not in the Editor, and will still be on if POWER is toggled without synced CLASH pressed.
StylePtr<Layers< EffectSequence<EFFECT_CLASH, // Used to toggle base color on-off. // The following COLOR can be replaced by a Layers<> containing your primary blade style stuff, // from the base blade color down to, but not including, the InOutTrL, and minus any EFFECT_RETRACTION layers. Layers< // on press Mix<SwingSpeed<300>,AudioFlicker<RotateColorsX<Variation,Red>,RotateColorsX<Variation,Rgb<128,0,0>>>,StaticFire<BrownNoiseFlicker<RotateColorsX<Variation,Red>,RandomPerLEDFlicker<RotateColorsX<Variation,Rgb<25,0,0>>,RotateColorsX<Variation,Rgb<60,0,0>>>,300>,RotateColorsX<Variation,Rgb<80,0,0>>,0,6,10,1000,2>>, TransitionEffectL<TrConcat<TrInstant,HumpFlickerL<White,50>,TrFade<1000>>,EFFECT_CLASH> // pseudo EFFECT_IGNITION >, Black // starts here at power on of main blade >, EffectSequence<EFFECT_CLASH, TransitionEffectL<TrConcat<TrInstant,Black,TrWipe<500>>,EFFECT_CLASH>, // pseudo extension wipe TransitionEffectL<TrConcat<TrInstant, // This color should be the same as the base blade color layer StaticFire<BrownNoiseFlicker<RotateColorsX<Variation,Red>,RandomPerLEDFlicker<RotateColorsX<Variation,Rgb<25,0,0>>,RotateColorsX<Variation,Rgb<60,0,0>>>,300>,RotateColorsX<Variation,Rgb<80,0,0>>,0,6,10,1000,2>, TrJoin< TrConcat<TrFadeX<WavLen<>>,AudioFlickerL<White>,TrInstant>, // pseudo EFFECT_RETRACTION TrWipeInX<WavLen<>>>>,EFFECT_CLASH>>, // pseudo retraction wipe (for 2nd blade discrete retraction before actual power off.) Mix<IsGreaterThan<EffectIncrementF<EFFECT_CLASH,Int<32768>,Int<16384>>,Int<100>>, // Used to toggle Actual power button EFFECT_RETRACTION (Don't show if 2nd blade already retracted). Int<100> could be anything up to 16383 AlphaL<Black,Int<0>>, // Invisible filler in sync with pseudo version already handled above TransitionEffectL<TrConcat<TrFadeX<WavLen<>>,AudioFlickerL<White>,TrInstant>,EFFECT_RETRACTION>>, InOutTrL< TrInstant, // In-Out: Instantly reveal because USER4 handles wipe and EFFECT_IGNITION TrWipeInX<WavLen<EFFECT_RETRACTION>>> // Covering both blades if alt blade left on >>(),