I'll give it a thought. Either extending UI_Sync (which feels wrong), or making a variant of it.Mine was just a sneaky attempt at a request...
You already have UI Sync that outputs things to the Atom in which it is loaded. Can't you make a similar plugin that "sipmly" make accessible POS and ROT to other plugins so that we can use UI Sync to show that values into an UIText?
Btw... your plugins are very useful! Thanks!
P.s. Yes, this is a shameless corruption attempt of my inner toady.
Maybe there are other atom's properties that may be usefull to show to other plugins... you can make a "Show me your's secrets" plugin!I'll give it a thought. Either extending UI_Sync (which feels wrong), or making a variant of it.
That's exactly the way to do it (and that's actually why I wrote that plugin in the first place).1) Add ValueMapRelay plugin to Audiosource - or any atom of choice, for ease here, let's just put it on the Audiosource
2) next, select ValueMapRelay "Value Actions" = (atom)Audiosource/(receiver)Audiosource/(target)Volume Start 0.000 -> End 1.000
3) ValueMapReplay variables settings:
a) "Value" controlled by external trigger - e.g. Timeline fading volume.
b) "Input From" set to 0.000
c) "Input To" set to 1.000
d) "Output From" set to 0.000
e) "Output To" controlled by external trigger - e.g. slider for volume.
Next:
3) Add slider trigger, name "Volume"
4) Slider trigger action = (atom)Audiosource/(receiver)ValueMapRelay/(target)"Output To" Start 0.000 -> End 1.000
External trigger e.g. Timeline for volume fade:
5) Trigger action - instant or timed = (atom)Audiosource/(receiver)ValueMapRelay/(target)"Value" 0.000 to fade out,
or 1.000 to fade-in/instantly make noise again
Multiply: Can do, easy, just might backfire if somebody has used range extension on the inputs and the result is outside of [0...1]Could I request the FloatOperator brick has a "Multiply" operation?
Could I also request a new brick for channel selection, where it is like a ValueRelay, but with 8 inputs and a dropdown to pick which one should be the output signal?
THIS UPDATE BREAKS PREVIOUS scenes that use FloatOperation!!!
- As requested by @Voithe, added a plugin that can display (but not change) the transformation (Position/Rotation) of an object in a UIText.
- As requested by @mechanimus, added a Multiplication operator to FloatOperation.
During that move, I removed the "Value 1" and "Value 2" operations I had introduced just before...
Hi! Yes, absolutely! Feel free just to rewrite it as your own. And thank you for the plugins - top work ?That's exactly the way to do it (and that's actually why I wrote that plugin in the first place).
Would you be OK if I link to this tutorial in the plugin page description as an example?
HAL9001 updated LogicBricks2 with a new update entry:
v7: (BREAKING CHANGE) FloatOperation Multiplication and UI_TransformSync plugin added
Read the rest of this update entry...
Hmmm, that idea of stating another atom as base, not the parent is something I did in another (soon to come) Plugin, so I can copy that code across at some point.Very interesting extension, but regarding the PerlinNoiseMovement section, can we further expand the functionality? For example, a butterfly needs to fly around a character's head, but the current function can only bind to one parent atom, not to the character's joints. There is also a small issue. When setting an atom (entity) to randomly move around its parent atom, it can penetrate any object, including the parent atom, walls, floors, etc., and has no control over its movable position (currently only suitable for torches). Can we change the upper and lower limits of the movement axis, such as Xmin to Xmax, instead of simply ± X, and add the parameter of the minimum distance from the parent atom? I think this is a very perfect idea.
That sounds more like a subscene thing in VaM to me. beyond my control.This goes far beyond my expectations. Very awesome! ?
I think there is just a little issue: When parenting the UIText like SUBSCENE => UIButton => UIText the VAM UI of the UIText doesn't show the parent atom (UIButton) (i mean in the field next to the button used to select a parent atom). The UIText is actually parented. It's just a "visual" problem.
Note that this maybe related to other things in my scene but you may want to take a look.
Seems fixed after a save-load.That sounds more like a subscene thing in VaM to me. beyond my control.
Big Thank You for the multiply change!Multiply: Can do, easy, just might backfire if somebody has used range extension on the inputs and the result is outside of [0...1]
Multiplexer: I was thinking about that already. At the moment, there's some kind of that in the BooleanOperator for 2 channels - I'll also add that to the FloatOperator for symmetry, but I can imagine you'd quickly need more than 2 channels ;-)
The functionality of the plugin is even better than expected,wonderful !!!Hmmm, that idea of stating another atom as base, not the parent is something I did in another (soon to come) Plugin, so I can copy that code across at some point.
The xMin/xMax can easily be addressed by offsetting your actual center to (xMin+xMax)/2. Unless you want dynamic control on each of the axes, but that could still be done with this mathematical trick.
The minimum distance thing is much trickier and would change the nature of the plugin, so probably not happening, sorry.
THIS UPDATE BREAKS SCENES THAT HAVE USED BinaryOperator.
- Again, for consistency purposes (sorry, I hope this is the last time), renamed BinaryOperator to BoolOperator. This is a breaking change, but can easily be fixed by opening a scene JSON file in a text editor (e.g., Notepad++) and replacing all "BinaryOperator" with "BoolOperator".
- As requested by...
MacGrubers set has "ValueRandom" to get a random number between 0 and 1 on a trigger. You could then use ValueMap to convert to any other range between 0 and 1. Outside of 0/1 is always tricky as the VaM event system doesn't really like that.Hey HAL, does such a logic brick exist (in your edition or the original) to generate a random number between two specified points? And if not do you think it could be a possible future logic brick in LogicBricks2? I can't actually remember why I want this now, since I'm pretty sure I found a hack job work around to do what I was trying to achieve - but I just remember spending a LONG time figuring it out, and thinking "this would be a useful logic brick for people like me" the whole time.
I use a combination of VUML, ActionGrouper and the LogicBricks plugins to achieve a lot of custom features in my scenes. Each are fantastic for their own reasons, but your expansion on LogicBricks has proven invaluable so far. Thank you!
Agree, that's part of a ValueMap extension I had in mind anyway: A curve applied to the unified value: Exponent, Sinusoidal, Log/PowI have another idea for an ExponentialValueMap, where you'd choose an exponent (e.g. between 0.1 and 10), and the output is just input^exponent. If you restrict the input range to 0-1 only, it means the output range is also 0-1.
It'd mean I can have triggers where smaller values mean more (exp < 1), and others where only the larger values actually matter (exp>1).