Stormworks: Build and Rescue

Stormworks: Build and Rescue

Недостаточно оценок
Autopilot Coordinates System ACS
   
Наградить
В избранное
В избранном
Удалить
Vehicles: Air, Sea
Метки: v0.5.2
Размер файла
Добавлен
Изменён
18.477 KB
5 дек. 2018 г. в 12:55
5 дек. 2018 г. в 21:47
Обновлений: 2 (просмотреть)

Подпишитесь, чтобы загрузить
Autopilot Coordinates System ACS

Описание
Easy to use autopilot coordinates system. Connect it up as the nodes says.

Requires: A keyboard, a compass, a gps and a toggle button.

Specs:
-Size: 4*2
-Inputs: 6 (5 number, 1 on/off)
..-Target X Coordinate
..-Target Y Coordinate
..-Current X Coordinate
..-Current Y Coordinate
..-Heading(Compass)
..-On/Off toggle
-Outputs: 2 (2 number)
..-Autopilot Output
..-Length to target

Update:
-Added distance to target output.
-Fixed for the 0.5.2 verision.

Math Based on Tajin's Original Full Autopilot Example.

Please comment bugs or features.
Комментариев: 8
Maxwell Snow 20 янв. 2021 г. в 13:07 
Thank you! that super helpful. I'll have to go look up the modulo function!
iogic  [создатель] 20 янв. 2021 г. в 4:45 
I didn't write that last function on my own, but I know everything it does. Let's say you're creation is pointing towards 10 degrees, and you want to go heading 350 degrees. Instead of turning all the way around, to get to 350, it will just turn 20 degrees the other way. Hard to explain how it achieves this, but it uses the modulo (%) function a lot, which is super helpful in these cases and that you should learn if you haven't already.
Maxwell Snow 19 янв. 2021 г. в 19:32 
I'm trying to build my own, and I'm trying to figure out exactly what that last function does.
I realize the first function is calculating rise over run and using atan2 to avoid having to calculate the quadrants (though I could be wrong).
I'm just beginning to learn these things.
Rozoh 17 фев. 2020 г. в 18:52 
could you do a fx node that takes the pre-proccesed perfect heading readings?
"'fx' ( x +1) * 360 % 360"
iogic  [создатель] 12 мар. 2019 г. в 14:40 
DestructiveDiamonds, Well, it could, but planes are much more advanced, you can try.
el dorado 12 мар. 2019 г. в 8:56 
Can it work on planes?
iogic  [создатель] 15 дек. 2018 г. в 6:41 
aguirre27, Yes it works very well for my helicopter. It might be very sensitve so maybe divide the Autopilot output by 2,3 or 4.
aguirre27 14 дек. 2018 г. в 13:54 
it works with helicopters?