Stormworks: Build and Rescue

Stormworks: Build and Rescue

Недостаточно оценок
Waypoint-Queue
   
Наградить
В избранное
В избранном
Удалить
Vehicles: Creative
Метки: v0.9.31
Размер файла
Добавлен
Изменён
32.905 KB
17 янв. 2019 г. в 6:21
30 янв. 2020 г. в 6:59
Обновлений: 4 (просмотреть)

Подпишитесь, чтобы загрузить
Waypoint-Queue

Описание
If you want the autopilot to follow a route of several waypoints, this is the controller for you. Just add waypoints (from a large keypad) and they will be fed to your autopilot - one after the other. It's a queue, so the first waypoint you put in is the first which will be pulled out. It's even possible to add more waypoints to the queue when the autopilot pulled some out.

This could be usefull:
- the composite output shows the first 15 waypoints but the controller handles more.
- The Waypoint Controller can calculate additional data to the first waypoint of the queue.
- The Total Distance ist the distance between the first waypoint, following the legs to the last waypoint.
- The controller shows you the total amount of stored waypoints. If this reaches zero, you could automatically turn off the autopilot.
- Link the Pulse of the Large Keypad to automatically add the waypoint to the queue.
- Composite output #31 is the amount of waypoints
- Composite output #32 is the total distance between the waypoints

Controller size: 5x2

Inputs:
- Waypoint X, Waypoint Y (number) - The waypoint coordinatess which will be stored when "Push" is aktivated.
- Push (on/off) - The Waypoint will be stored to the queue
- Pop (on/off) - The first Waypoint from queue will be deleted and the next will be shown at the Waypoint output.
- Reset - Clears the queue

Outputs:
- Waypoint X, Waypoint Y (number) - The coordinates of the first waypoint in the queue
- Waypoints Quantity (number) - The amount of stored waypoints
- Total Distance (number) - The DIstance between the waypoints in the queue.
- Waypoint Queue (composite): The first 15 waypoints (X1,Y1,X2,Y2,X3,Y3,...), #31= quantity, #32=total distance
Комментариев: 13
TBF 25 апр. 2023 г. в 7:04 
can you make it recycle way points so it goes through say 100 way points and back to way point 1 again?
Jackthedragonkiller [Chirch] 21 мар. 2022 г. в 12:24 
Oh ok, so the limit is as many as my PC can handle before imploding. Got it. Thank you! This MC is great and I'm definitely gonna be using it in future builds.
sengir_vampire  [создатель] 21 мар. 2022 г. в 10:51 
the controller (lua) could handle billions of waypoints (theoretically). But at some point, the game will definitly get laggy. I never tried but I think 10,000 should be no problem.
Jackthedragonkiller [Chirch] 20 мар. 2022 г. в 13:31 
So I just found this and am using it on a plane that I am working on currently, and I'm in love with this. Works fantastically!

One question, how many waypoints can the controller actually hold?
Slofi 20 окт. 2021 г. в 4:02 
Hehe, ok, never mind, my mistake, missing nod connection :) it works perfectly!
Slofi 20 окт. 2021 г. в 3:54 
Hi! I have a proble, when I clear the queue, new waypoints can't be added, or at least my AP doesn't recognise them and boats just starts to spin around last WP. Any idea what I am doing wrong?

So the queue works fine for first set of WP, but if I clear it and add new WP it does not recognize them. Or my AP doesn't..
Slofi 19 окт. 2021 г. в 8:07 
Great controller! Big thank you, sir!
sengir_vampire  [создатель] 31 янв. 2020 г. в 8:54 
you have to hook the "waypoint reached" signal of the waypoint controller to the pop input of the queue controller
SamuelPepys 31 янв. 2020 г. в 6:06 
Ah, cool. And that works with every waypoint, and not just the first, right? Like, if you have it hooked up to a digital display, it will output the distance to the first waypoint, then when that's reached, it will automatically move on to output the distance to the second waypoint and the same for the next 13 waypoints on the same digital display?
sengir_vampire  [создатель] 31 янв. 2020 г. в 0:33 
The queue doesn't handle the GPS-Signal. If you want to calculate some data between your ship and the target use my Target Controller or my new Waypoint Controller with Composite Input for the queue.