Jump to content

Program the rotation of a person on a virtual track


220hotwheels

Recommended Posts

Hello to all my fellow members.

I need to rotate a person on a virtual track by 180 degrees when he gets to each end of a virtual track, as can be seen in the attacked screenshot

The person on a virtual track moves from the side door of a van towards another person who walks out of a garage. The crate being carried by the delivery person is then handed over to the other person who returns to the garage. At that point I want to rotate the delivery person on the track by 180 degrees and send him back to the van. All other refinements I can manage but I cannot see how to rotate said person other than in "Positioning" - "Rotation" - and then set "X" to 180 degrees. If I can get this issue sorted then it will also simplify the movement of the guy from the garage and will allow greater flexibilty at other stops on this route

I'm sure this action will be possible using Lua script but my knowledge does not allow me to produce said script. Can anyone help or do you know of another way I can create this in my EM.

Ever hopeful

Pete

Delivery person.jpg

Link to comment
Share on other sites

Hello @220hotwheels ,

Use this Lua script where the person is the vehicle (trigger). 

-- Turn Pi radials
local Pi = math.pi
vehicle.transformation:rotateZ(Pi)

This one acts as the person stops, but you could trigger another event for it.

turnaround.jpg.6b675edf31da85a6db744aeb39297403.jpg

Does it help you ?

Regards, Herman

Edited by Herman
EV
Link to comment
Share on other sites

11 minutes ago, Herman said:

Hello 220hotwheels ,

Use this Lua script where the person is the vehicle (trigger). 

-- Turn Pi radials
local Pi = math.pi
vehicle.transformation:rotateZ(Pi)

This one acts as the person stops, but you could trigger another event for it.

turnaround.jpg.6b675edf31da85a6db744aeb39297403.jpg

Does it help you ?

Regards, Herman

Hi Herman

That would seem to solve my problem perfectly. I'm not at home right now but will give your suggestion a try early tomorrow morning. I'll let you know how I get on. Once again many thanks, your speedy reply is very much appreciated

Best regards

Pete  

Link to comment
Share on other sites

10 hours ago, Roter Brummer said:

A bit more fun.

Postman 2.mbp 6.08 kB · 9 downloads

HG
Brummi

Hi Brummi

What a brilliant solution, and love the sense of humour. Now I wonder if I will be able to modify it so that the driver can take the parcels round to the back, leave them there and then put a note through the letterbox to say what he has done!!! Or, as sometimes happens, drop them at the front door, take a photo and then pick them up and take them back to his van. Only very naughty drivers would consider this but it does happen on occasions. My house cameras have picked this up. 

Anyway this is a make believe world so perhaps I should always look on the good side and keep everything perfect!! Between this and the one from Herman I think I should be able to cover all possibilities in my layout so very many thanks for your solution.

All the best 

Pete

Link to comment
Share on other sites

1 hour ago, Roter Brummer said:

Also brilliant - brilliantly simple.

I made something here:

This can be seen in action here:

Running Postman.mbp 3.44 kB · 2 downloads

Do we need something like that?

I have made something:

Do we need something like this?

HG
Brummi

Well Brummi

As always you have out done yourself, another minor master piece, and yes most certainly we do need something like this. Brilliant, many thanks. I'll now have to start making a list of all other elements that would benefit from your ingenuity!!!

All the best

Pete

Link to comment
Share on other sites

Suggestion:

Put an identical stack of packages on the doorstep and make them invisible, then when the postman reachest the door, make the packages he's holding invisible and the ones on the doorstep visible.

Before he gets back to the van, the packages on the doorstep turn invisible again. If the house has a door that opens, so much the better; open the door to have a grumpy old man standing there, the packages disappear and the door closes. Then the postman reaches the van, and pauses, ther packages in his hands reappear and around we go again!

Link to comment
Share on other sites

Hallo zusammen  /  Hello everyone,

jene Hobby-Kollegen von Euch, die noch nicht so lange in der Community dabei sind, kennen vielleicht nicht die schönen Anlagen-Geschichten von @Koriander. Gerade was die "In-Szene-Setzung" der beweglichen Figuren angeht, hat sich @Koriander hier sehr viel Mühe gegeben und wundervolle Geschichten gestaltet - die insbesondere auch den hier betrachteten Paketboten beinhalten. Ich möchte Euch insbesondere die folgenden beiden Anlagen empfehlen, die nach dem Laden automatisch loslaufen und jeweils ihre eigene "Geschichte" erzählen.

Those of you hobby colleagues who have not been part of the community for so long may not be familiar with the beautiful layout stories by @Koriander. Especially when it comes to "setting the scene" for the moving figures, @Koriander has put a lot of effort into creating wonderful stories - including the parcel carrier in particular. I would particularly like to recommend the following two installations, which start automatically after loading and each tell their own "story".

CB7 - Eilpaket für Onkel Bartl  (Content-ID  C9C8D571-6AC6-423D-9CFA-D891A546C565)

FD3 - Mummelland  (Content-ID  5559C2E5-06B4-42BD-936C-F42428BBAC46)

Lehnt Euch nach dem Laden der jeweiligen Anlage einfach zurück und genießt die Geschichte, die vor Euch abläuft.

After loading the respective system, simply sit back and enjoy the story that proceeds before you.

Viele Grüße / many greetings
BahnLand

Link to comment
Share on other sites

14 hours ago, BahnLand said:

Hallo zusammen  /  Hello everyone,

jene Hobby-Kollegen von Euch, die noch nicht so lange in der Community dabei sind, kennen vielleicht nicht die schönen Anlagen-Geschichten von Koriander. Gerade was die "In-Szene-Setzung" der beweglichen Figuren angeht, hat sich Koriander hier sehr viel Mühe gegeben und wundervolle Geschichten gestaltet - die insbesondere auch den hier betrachteten Paketboten beinhalten. Ich möchte Euch insbesondere die folgenden beiden Anlagen empfehlen, die nach dem Laden automatisch loslaufen und jeweils ihre eigene "Geschichte" erzählen.

Those of you hobby colleagues who have not been part of the community for so long may not be familiar with the beautiful layout stories by Koriander. Especially when it comes to "setting the scene" for the moving figures, Koriander has put a lot of effort into creating wonderful stories - including the parcel carrier in particular. I would particularly like to recommend the following two installations, which start automatically after loading and each tell their own "story".

CB7 - Eilpaket für Onkel Bartl  (Content-ID  C9C8D571-6AC6-423D-9CFA-D891A546C565)

FD3 - Mummelland  (Content-ID  5559C2E5-06B4-42BD-936C-F42428BBAC46)

Lehnt Euch nach dem Laden der jeweiligen Anlage einfach zurück und genießt die Geschichte, die vor Euch abläuft.

After loading the respective system, simply sit back and enjoy the story that proceeds before you.

Viele Grüße / many greetings
BahnLand

Hi BahnLand

Silly question but how do I install both of these. 

Baffled Pete

Link to comment
Share on other sites

15 hours ago, simonjackson1964 said:

Suggestion:

Put an identical stack of packages on the doorstep and make them invisible, then when the postman reachest the door, make the packages he's holding invisible and the ones on the doorstep visible.

Before he gets back to the van, the packages on the doorstep turn invisible again. If the house has a door that opens, so much the better; open the door to have a grumpy old man standing there, the packages disappear and the door closes. Then the postman reaches the van, and pauses, ther packages in his hands reappear and around we go again!

Hi Simon

I've already set up something similar. The delivery guy leaves the van and takes it to another guy who appears from the garage bay. As one, theoretically hands over the package the one carriedd by the delivery guy disappears and the one receiving the package appears. He then takes it back into the garage and places it on a workbench.

Timing is key so still fine tuning but it looks OK so far.

Cheers 

Pete

Link to comment
Share on other sites

vor 1 Stunde schrieb 220hotwheels:

how do I install both of these. 

You don't.
Instead, you just go to the online catalogue and open the layouts.
Use the name or the layout ID to find them. Or search all layouts from the creator Koriander

Link to comment
Share on other sites

2 hours ago, Goetz said:

You don't.
Instead, you just go to the online catalogue and open the layouts.
Use the name or the layout ID to find them. Or search all layouts from the creator Koriander

Thanks for that Goetz. I've now been able to open both items. Having watch both I have to admit that the use of moving figures is genious. Definitely something to aspire to.

Best regards

Pete

Link to comment
Share on other sites

18 hours ago, BahnLand said:

Hallo zusammen  /  Hello everyone,

jene Hobby-Kollegen von Euch, die noch nicht so lange in der Community dabei sind, kennen vielleicht nicht die schönen Anlagen-Geschichten von Koriander. Gerade was die "In-Szene-Setzung" der beweglichen Figuren angeht, hat sich Koriander hier sehr viel Mühe gegeben und wundervolle Geschichten gestaltet - die insbesondere auch den hier betrachteten Paketboten beinhalten. Ich möchte Euch insbesondere die folgenden beiden Anlagen empfehlen, die nach dem Laden automatisch loslaufen und jeweils ihre eigene "Geschichte" erzählen.

Those of you hobby colleagues who have not been part of the community for so long may not be familiar with the beautiful layout stories by Koriander. Especially when it comes to "setting the scene" for the moving figures, Koriander has put a lot of effort into creating wonderful stories - including the parcel carrier in particular. I would particularly like to recommend the following two installations, which start automatically after loading and each tell their own "story".

CB7 - Eilpaket für Onkel Bartl  (Content-ID  C9C8D571-6AC6-423D-9CFA-D891A546C565)

FD3 - Mummelland  (Content-ID  5559C2E5-06B4-42BD-936C-F42428BBAC46)

Lehnt Euch nach dem Laden der jeweiligen Anlage einfach zurück und genießt die Geschichte, die vor Euch abläuft.

After loading the respective system, simply sit back and enjoy the story that proceeds before you.

Viele Grüße / many greetings
BahnLand

Hi BahnLand

OK, so I eventually found out how to open and view both video's, thanks to Goetz, and yes I have to say that the use of moving figures is brilliant. I must definitely up my game, so to speak, but it does give me plenty to work towards so many thanks.

Best regards

Pete

Link to comment
Share on other sites

On 12/6/2023 at 5:41 PM, Herman said:

Hello 220hotwheels ,

Use this Lua script where the person is the vehicle (trigger). 

-- Turn Pi radials
local Pi = math.pi
vehicle.transformation:rotateZ(Pi)

This one acts as the person stops, but you could trigger another event for it.

turnaround.jpg.6b675edf31da85a6db744aeb39297403.jpg

Does it help you ?

Regards, Herman

Hi Herman

I've been trying to get my man to rotate using your Lua formula but without success. No doubt I'm not getting something right so I've attached a copy of my script. Brummi's solution would certainly be simple but the only problem is that by using that particular alternative in this situation means that the poor guy rotates through the bed of the van or through the table in the garage once he has delivered the case. Not really ideal even If I choose to set invisibilty early because then the case does not reach the table or the guy does not make it completely back to the van.

Best regards

Pete

Rotate person.jpg

Link to comment
Share on other sites

  • 2 weeks later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...