220hotwheels Geschrieben 12. April 2021 Geschrieben 12. April 2021 Hi everyone I am trying to introduce another element to my layout by adding a helicopter. Setting out a suitable flightpath is straightforward, the helicopter to follow said flightpath is also no problem. Where I am struggling is in getting the rotors to start and stop automatically. No matter what I have tried so far I just cannot get it right. If I use the "stop animation" as the helicopter comes into land then yes the rotors will stop but then the helicopter won't start up again. I am sure there is a very simple solution to this but so far it is escaping me so if anyone has the answer I would be most grateful. I have attached a small demo which I hope will show my problem. Cheers Pete Helicopter demo.mbp
Andy Geschrieben 12. April 2021 Geschrieben 12. April 2021 (bearbeitet) Hi Pete, take a look into the event protocol (in your layout). When you press the switch, things are going recursive. To avoid that, I used my little Trigger-Taster (it returns automatically in base position and has only a trigger-effect) and placed it over the old switch which has no function anymore. Then it really needs Animation Stop. Always use current animation position. That's it. cheers Andy p.s.: a condition for the presence of the stopped helicopter would be nice to avoid effects of the switch while the copter is flying. Helicopter demo Re.mbp Bearbeitet 12. April 2021 von Andy p.s.
220hotwheels Geschrieben 12. April 2021 Autor Geschrieben 12. April 2021 Hi Andy What can I say other than brilliant. As with so many things in this life the solution is often so simple. I've spent around 4 hours trying to solve what you have clearly sorted in a matter of minutes. I look forward to the time when my knowledge base of this hobby is even partly comparable to guys like you. Once again many thanks. Cheers Pete
Andy Geschrieben 12. April 2021 Geschrieben 12. April 2021 Hi Pete, that's all just a matter of time. And this little trigger-switch uses a special feature where I had a long time to fight for for being inplemented to MBS. So it's still unique in its function and because my very first steps in model creation not much of a graphical highlight, so it's surely not waving when you search for a fitting switch. Knowing it very well, that was not much of a solution. You could use your layout as well if you cut the direct connection of the switch and have a condition for the switch's position to avoid recursivity. Still, animation better always starts/stops/continues from the current position. cheers Andy
220hotwheels Geschrieben 12. April 2021 Autor Geschrieben 12. April 2021 Hi Andy Not too sure how to best understand your comment in the last paragraph, I'll just have to think about it a bit longer, that's the problem when your brain gets to 75 yrs, it slows down and need constant prodding or another beer!!! I have applied your suggestion though to my main layout and hey presto all works fine. Just one further thought. I have created quite a complex control panel in order to keep tabs on all moving objects with lights highlighting just where everything is, mainly car, trucks, busses, boats, cranes etc and now helicopters. So far I have used the switch that I added to my helicopter demo which seems to do the job of turning each thing on and off when required. Would you recommend that I consider changing these switches to your taster? Cheers Pete
Andy Geschrieben 12. April 2021 Geschrieben 12. April 2021 (bearbeitet) Hi Pete, what about this? It also solves the problem for a wrong click. There is a second (red) trigger now which does nothing. Visibility gets exchanged. If you need on/off, take the old switch, if you need a trigger, take the trigger. cheers Andy Helicopter demo Re2.mbp Bearbeitet 12. April 2021 von Andy
Goetz Geschrieben 12. April 2021 Geschrieben 12. April 2021 (bearbeitet) vor 21 Minuten schrieb 220hotwheels: Not too sure how to best understand your comment in the last paragraph Allow me, please ... The event is triggered whenever the switch is toggled. Regardless of it's new position (on or off) Your first action is that you set the switch anew. For what purpose, I don't know. But this causes the event to be triggered again! It also keeps you from ever turning the switch "off" again. What you actually want to do, is respond only when the switch is set to the "on" position. In other words: The position "on" is a condition which must be fulfilled in order for any action to take place use the + sign to add a condition. select the switch position condition set this condition to verify that your particular switch is in the "on" position With this basic understanding of logic, no "special switch" is required. Best regards Goetz Bearbeitet 12. April 2021 von Goetz typos
220hotwheels Geschrieben 12. April 2021 Autor Geschrieben 12. April 2021 Hi Andy & Goetz Apologies for taking time to respond. I had picked up your replies earlier but had to take a phone call from the Loss Adjusters appointed by our insurance company. I am in the process of concluding a settlement for Business Interruption caused by Covid-19 for our bookbinding company and typical of insurers they have a very large book of silly questions that require multiple answers before they make up their minds. I've lost count of the number of spreadsheets I have completed but I think I can now safely say that I have a result. Phew. Both of your solutions are great. I've already implemented yours Andy for the helicopters and will now utilise your suggestion Goetz with parts of the control panel. Having this forum with all you knowledgeable guys is a bit like having multiple yoda's. Cheers Pete
Empfohlene Beiträge
Erstelle ein Benutzerkonto oder melde dich an, um zu kommentieren
Du musst ein Benutzerkonto besitzen, um einen Kommentar verfassen zu können
Benutzerkonto erstellen
Neues Benutzerkonto für unsere Community erstellen.
Neues Benutzerkonto erstellenAnmelden
Du hast bereits ein Benutzerkonto? Melde dich hier an.
Jetzt anmelden