New function in animator

Raylectron (https://Raylectron.com) is a 3D rendering engine for Trimble Sketchup (https://sketchup.com)
User avatar
GateGirl86
Posts: 845
Joined: Mon Oct 03, 2022 8:32 pm

Re: New function in animator

Post by GateGirl86 »

like someone who has never driven a manual car before, you know, when they don't clutch it properly. That is just the movement. When I run it, it just disappears off the screen.

So, as I said before, 55m in 1min 16 seconds before turning. I think as the Video starts, it should sit there for at least 2 seconds.
Image
"Come with me if you want to live."
Sarah Connor
User avatar
Support
Site Admin
Posts: 2945
Joined: Sun Oct 02, 2011 10:49 am

Re: New function in animator

Post by Support »

I know what you mean. Can you send me a screen shot?

ok, so you want it to sit there at the start of the video for 2 seconds then, you want it to start going for 1 minute and 16 seconds and travel a total of 55 meters?
Your support team.
https://SoftByteLabs.com
User avatar
GateGirl86
Posts: 845
Joined: Mon Oct 03, 2022 8:32 pm

Re: New function in animator

Post by GateGirl86 »

A screen shot of the start? Or an empty airfield when it disappears? :lol:

exactly that! :mrgreen:

I do have a question though. What if I wanted to say, once it's arrived at the pause spot after turning, then sits waiting to take off. I wanted to change the camera angle to a side view and see it move down the runway from the starboard side?
Image
"Come with me if you want to live."
Sarah Connor
User avatar
GateGirl86
Posts: 845
Joined: Mon Oct 03, 2022 8:32 pm

Re: New function in animator

Post by GateGirl86 »

back at 12 midday :salute
Image
"Come with me if you want to live."
Sarah Connor
User avatar
Support
Site Admin
Posts: 2945
Joined: Sun Oct 02, 2011 10:49 am

Re: New function in animator

Post by Support »

a screen shot of the whole Raylectron window.

ok, but you're going way ahead, so lets start with the 55m run first.

py := Accelerate(0.0157, meters, 2, 78);

the 78 is 1 min 16 sec + the 2 seconds offset for the start.
Your support team.
https://SoftByteLabs.com
User avatar
Support
Site Admin
Posts: 2945
Joined: Sun Oct 02, 2011 10:49 am

Re: New function in animator

Post by Support »

GateGirl86 wrote: Tue May 09, 2023 7:38 pm back at 12 midday :salute
:salute
Your support team.
https://SoftByteLabs.com
User avatar
GateGirl86
Posts: 845
Joined: Mon Oct 03, 2022 8:32 pm

Re: New function in animator

Post by GateGirl86 »

Video 2.jpg
Video 2.jpg (303.9 KiB) Viewed 7532 times
I'll try that, thank you. :salute
Image
"Come with me if you want to live."
Sarah Connor
User avatar
GateGirl86
Posts: 845
Joined: Mon Oct 03, 2022 8:32 pm

Re: New function in animator

Post by GateGirl86 »

I don't know what is wrong, the measurement is correct according to the SKP measure tool, yet its still going off screen to the right?
Image
"Come with me if you want to live."
Sarah Connor
User avatar
Support
Site Admin
Posts: 2945
Joined: Sun Oct 02, 2011 10:49 am

Re: New function in animator

Post by Support »

Looks fine in the Window.

Can you step it using the forward button? the one to the right of the stop button and see how much it moves per frame.

oh, but it's normal that it still goes forever since we didn't start a new event to stop it!
Your support team.
https://SoftByteLabs.com
User avatar
Support
Site Admin
Posts: 2945
Joined: Sun Oct 02, 2011 10:49 am

Re: New function in animator

Post by Support »

But does it starts ok until the point where it needs to turn?
Your support team.
https://SoftByteLabs.com
User avatar
Support
Site Admin
Posts: 2945
Joined: Sun Oct 02, 2011 10:49 am

Re: New function in animator

Post by Support »

I've modified the engine so it's even easier. Download and install the new RBX, no need to re-export from Sketchup, just load back your ROF file.

https://Raylectron.com/files/Raylectron.rbz

Next post I'll explain...
Your support team.
https://SoftByteLabs.com
User avatar
Support
Site Admin
Posts: 2945
Joined: Sun Oct 02, 2011 10:49 am

Re: New function in animator

Post by Support »

So I've added the variable Units so you can set the units at the beginning of the code rather than always including it in the functions. So the very first line of code for you should be...

Units := Meters;

Now, I've created a new function that calculate the acceleration based on distance and time. Si from a stand still, if you want your 302 to move 55m in 76 sec, use the following to compute the acceleration...

acc := ComputeAcceleration(55, 76);

now you can use 'acc' in the Accelerate function...

py := Accelerate(acc, 2, 78);

so now let me ask for the second task, we have it accelerate for 76 sec but, don't we need to decelerate it before it starts to turn? So now, tell me when you want it to decelerate how the distance it will come to a stop. We will then change the timing of the first even.
Your support team.
https://SoftByteLabs.com
User avatar
GateGirl86
Posts: 845
Joined: Mon Oct 03, 2022 8:32 pm

Re: New function in animator

Post by GateGirl86 »

I'm totally buggered Michael. I haven't slept properly for days, as I've been doing multiple shifts. Right now I can barely see the screen, so I need to give this a break for a while. I did however send you the SKP file.
Image
"Come with me if you want to live."
Sarah Connor
User avatar
Support
Site Admin
Posts: 2945
Joined: Sun Oct 02, 2011 10:49 am

Re: New function in animator

Post by Support »

oh, take care of yourself now, and don't feel obligated to reply or anything, I'm not pressuring you in any ways. <3 :salute
Your support team.
https://SoftByteLabs.com
User avatar
GateGirl86
Posts: 845
Joined: Mon Oct 03, 2022 8:32 pm

Re: New function in animator

Post by GateGirl86 »

I managed to get some sleep. And since I don't have a shift now until 12 midday, other than a little more sleep, I can manage this I think.

I'd like to ask though Michael if you could give me a head start and write the first lines for me, from the start to the turning point. So that I am able to more understand how it functions.
At between 5 and 8 kmh, the taxiing speed, a fighter doesn't perceptibly slow down to make the turn.
Image
"Come with me if you want to live."
Sarah Connor
User avatar
Support
Site Admin
Posts: 2945
Joined: Sun Oct 02, 2011 10:49 am

Re: New function in animator

Post by Support »

You need to take it easy and have some rest. I'm working on a new set of functions that will make it way easier for you. Maybe tomorrow if you're up to it?
Your support team.
https://SoftByteLabs.com
User avatar
GateGirl86
Posts: 845
Joined: Mon Oct 03, 2022 8:32 pm

Re: New function in animator

Post by GateGirl86 »

I should be much more awake tomorrow, thank you Michael. I did add that new RBZ by the way. :salute
Image
"Come with me if you want to live."
Sarah Connor
User avatar
Support
Site Admin
Posts: 2945
Joined: Sun Oct 02, 2011 10:49 am

Re: New function in animator

Post by Support »

I hope you rested good and if you're up to it and have time, here is something that should work and here is a video to show it, the runway is 55m till the start of the other runway. But first, download and install the new RBZ...

https://raylectron.com/files/Raylectron.rbz

and here is the script, we'll talk about it when you run it and see what it does...

Code: Select all

Units := Meters;

Distance := 40.0;
Duration := 25.0;
StartAt  := 2.0;
EndAt    := Duration + StartAt;
py := Velocity(0, Distance, StartAt, EndAt);

Distance2 := 25.0;
Duration2 := 20.0;
StartAt2  := EndAt;
EndAt2    := Duration2 + StartAt2;
if (sec >= StartAt2) and (sec <= EndAt2) then begin
  d := Velocity(0, Distance2, StartAt2, EndAt2);
  py := py - d;
end;

TurnAngle := -90.0;
Duration3 := 10.0;
StartAt3  := EndAt2 - 17;
EndAt3    := Duration3 + StartAt3;
Yaw(TurnAngle, StartAt3, EndAt3);

if (sec >= EndAt2) then
  py := 0;
Your support team.
https://SoftByteLabs.com
User avatar
GateGirl86
Posts: 845
Joined: Mon Oct 03, 2022 8:32 pm

Re: New function in animator

Post by GateGirl86 »

I will have some time later this morning. And I am feeling much brighter, thank you so much Michael. :salute <3

And that is fantastic! :mrgreen:
Image
"Come with me if you want to live."
Sarah Connor
User avatar
Support
Site Admin
Posts: 2945
Joined: Sun Oct 02, 2011 10:49 am

Re: New function in animator

Post by Support »

:salute :salute :salute :salute :salute :salute
Your support team.
https://SoftByteLabs.com
User avatar
GateGirl86
Posts: 845
Joined: Mon Oct 03, 2022 8:32 pm

Re: New function in animator

Post by GateGirl86 »

27 hours 15 mins. Which is far, far better than 100+ hours :salute :mrgreen:
Image
"Come with me if you want to live."
Sarah Connor
User avatar
Support
Site Admin
Posts: 2945
Joined: Sun Oct 02, 2011 10:49 am

Re: New function in animator

Post by Support »

You mean video make time?
Your support team.
https://SoftByteLabs.com
User avatar
GateGirl86
Posts: 845
Joined: Mon Oct 03, 2022 8:32 pm

Re: New function in animator

Post by GateGirl86 »

Yes, and weirdly, it has gone up t0 28 hours, rather than down. :?:
Image
"Come with me if you want to live."
Sarah Connor
User avatar
Support
Site Admin
Posts: 2945
Joined: Sun Oct 02, 2011 10:49 am

Re: New function in animator

Post by Support »

That can happen, it depends on the current view, if there are more reflections exposed for example.
Your support team.
https://SoftByteLabs.com
User avatar
GateGirl86
Posts: 845
Joined: Mon Oct 03, 2022 8:32 pm

Re: New function in animator

Post by GateGirl86 »

Such as water?
Image
"Come with me if you want to live."
Sarah Connor
Post Reply