[Closed] Wiring reactor objects' properties – possible?
Hi everyone
I’m now working on my degree project and I’m working on script for 3DS Max9.
Now my question – is there a way to wire Reactor object’s parameter? To be more precise I want to wire ‘gain’ from CarWheel to Slider’s ‘value’. Ofc simple
paramWire.connect gainSlider[#value] newWheel[#gain] "value"
doesn’t work… Only gives me error:
Runtime error: connect requires subAnims
Can anyone explain this to me?
Is there a way to make it this way or any other (I must use 3DSM9 and MaxScript)?
Ok, maybe I’ll ask it other way – I’ve seen people making interactive car models.
How is the speed-up/brake and turning the wheels done?
Simple answer is you can’t wire to it as it isn’t an animateable parameter. You would need to write code to explicitly set the value. Look up the “How do I change the text in a Text Shape dynamically?” FAQ item to find out about animating non-animateable parameters. Basically create a float script on a parameter you aren’t using on the gainslider and then use that to set “newWheel.gain = gainslider.value”.
On your other question, you could look at the example from Paul Neale here, which is based around the math of making a wheel spin based on the distance traveled.
-Eric
Thanks a lot
I’ve searched the documentation for Reactor-regarding stuff and found nothing – didn’t think the solution to this may be about text animating xD I hope it’ll help. I’ll check it as soon as I get to my desktop again.
The second thing is not for me – I have to use the Reactor for the model. But maybe it’ll be helpful some other time.
Thanks once more
I wound use reactor car to make this work. I would just set it all up with script controllers and ca defs.
Sure, that would be the easiest way, but my degree project forces me to do it other way (using springs etc.)
Unfortunately, there’s an issue that carwheel has no ‘animatable’ properties, to which the floating script can be assigned…
Check up “text : shape” and “carwheel : helper”:
http://www.kxcad.net/autodesk/Autodesk_MAXScript_Reference_9/
I’ ve forgotten to add: and have to use Reactor…
So still the same: anyone have any idea if I can manipulate the carwheel properties like gain/velocity and its turns?
using only Reactor controllers you can’t cover any situation… for example there will be a problem to set it up when the wheel changes its radius in time.
Then, create a dummy object or Custom Attribute to drive it.
-Eric
Sorry, I don’t get it – how can some object help me animate other objects parameter, which I can’t link to it?.. Sorry for (probably) stupid questions, but it’s my first project using Maxscript.
Not working – the targeted property (gain) seems to ignore changes in slider bound to it through the artificial attribute…
So then… crap…
Thanks to all of you for helping – maybe u didn’t help me solve this unsolvable issue, but u helped me learn a lot, really
Yet it IS working O.O
I don’t know how did I check it yesterday, but it actually works!!!
Oh my… Guys, I love u all! Thanks soooooo much