Add animation, commands and engine RPM?

AIN_002

Crawler crane specialist
Invited
Joined
Sep 8, 2018
Messages
44
Location
Sweden
Hey everyone, I'm just beginning to learn how to add animation to props, and can't figure out one thing. I want a prop to work in the following way:
Only be triggered when I press a command button (like F6) but also be affected by engine RPM. The prop in question will be a hoist winch on a crane, which obviously should only rotate when hoisting the hook, but also have variable speed just like the hook commands themselves. It must also have 360 degree rotation.

I first thought about adding an N/B rotator to rotate the winch prop, but would prefer to not use N/B just for that.

Using source: tacho to correspond to engine RPM together with event: COMMANDS_XX to only respond to command press didn't work. Whatever combination, it either spun according to the engine but constantly regardless of command press (autoanimate), or it did respond to commands, but wasn't affected by RPM and couldn't spin 360 degrees continuously. What combination should I use, or is this not possible? Thanks.
 

negativeice

Invited
Invited
Old-timer
Joined
Jan 14, 2018
Messages
170
Afaik like you stated it has to be one or the other, though the current devs could implement something for this, only time will tell.
 
OP
OP
AIN_002

AIN_002

Crawler crane specialist
Invited
Joined
Sep 8, 2018
Messages
44
Location
Sweden
Okey I see, hopefully it will come in the future :)
 

graysonk95

Member
Invited
Old-timer
Joined
Jan 15, 2018
Messages
11
Location
Alabama
Okey I see, hopefully it will come in the future :)
If I understand correctly, you're trying to animate the "drum" portion of a winch so it appears to respond to an increase/decrease in hydraulic pressure as RPMs fluctuate?
e.g. The drum spins fast at high RPM, slow at low RPM, but stops when the command is released?

That's crudely possible with some trickery:

The only way I can think to accomplish this is to use THREE "drums" that swap places when the winch command is triggered.
One drum would be fixed rotationally, but animated to "hide" inside the body of the crane when either COMMAND is depressed, and reset back when either COMMAND is released.
The second drum would be autoanimated by tacho at all times, but would be hidden inside the body of the crane, taking the place of drum #1 when COMMAND_01 is depressed, and resetting inside the body when COMMAND_01 is released.
The third drum would be reverse autoanimated by tacho at all times, also hidden inside the body of the crane, taking the place of drum #1 when COMMAND_02 is depressed, and resetting inside the body when COMMAND_02 is released.

Example animations would look something like this:
Code:
101, 102, 103, 0, 0.0, 0, 0, 0, 0, EX_winch_drum.mesh  // FIXED drum
add_animation, -0.5, 0, 0, source: event, mode: y-offset, event: COMMANDS_01
add_animation, -0.5, 0, 0, source: event, mode: y-offset, event: COMMANDS_02

101, 102, 103, 0, -0.5, 0, 0, 0, 0, EX_winch_drum.mesh  // UP spinning drum
add_animation 1, 0, 0, source: tacho, mode: y-rotation, autoanimate
add_animation, 0.5, 0, 0, source: event, mode: y-offset, event: COMMANDS_01

101, 102, 103, 0, -0.5, 0, 0, 0, 0, EX_winch_drum.mesh  // DOWN spinning drum
add_animation -1, 0, 0, source: tacho, mode: y-rotation, autoanimate
add_animation, 0.5, 0, 0, source: event, mode: y-offset, event: COMMANDS_02
Maybe this will get you thinking in the right direction.

I doubt it would be possible, but maybe you could experiment with using a tacho and reversed tacho animation to cancel each other out so you only had one drum prop to animate?
 
OP
OP
AIN_002

AIN_002

Crawler crane specialist
Invited
Joined
Sep 8, 2018
Messages
44
Location
Sweden
Hey! Yep I thought about this too actually and I might try it. Not optimal but hey, whatever works I guess :p
 
Top