aliens

Author Topic: [Solved] Crafts can't return if starting base coordinates defined  (Read 544 times)

Offline Nikita1221

  • Sergeant
  • **
  • Posts: 10
    • View Profile
I tested it in 7.13, but since it wasn't mentioned in Bugs fixed, i figured it could still be the case.
I define starting base coordinates. I send craft to random point. I command craft to return. It flies to base, but seem to fail to land, even after fuel runs out.
Not sure if the exact coords matter, but i used lon: -1.79 and lat: -0.66.
Also, not sure if it's intended or not, but if you also define name:, it will only work if coordinates also defined, otherwise it asking to enter name.
« Last Edit: November 03, 2024, 07:13:56 am by Nikita1221 »

Offline Nikita1221

  • Sergeant
  • **
  • Posts: 10
    • View Profile
Re: [Bug] Crafts can't return if starting base coordinates defined
« Reply #1 on: November 03, 2024, 07:13:17 am »
Also, if you define name: for base, when spawning mission with targetBaseOdds:100 in mission script, game seems to think your base is in Antarctic, no matter where it actually is. If you also define coordinates, you'll get segmentation fault.

Offline Meridian

  • Global Moderator
  • Commander
  • *****
  • Posts: 9133
    • View Profile
Re: [Solved] Crafts can't return if starting base coordinates defined
« Reply #2 on: November 03, 2024, 10:19:14 am »
Not sure if the exact coords matter, but i used lon: -1.79 and lat: -0.66.

Of course coords matter, they need to be on Earth.

Longitude goes from 0 to 2*PI, latitude goes from -PI/2 to +PI/2.

Also, not sure if it's intended or not, but if you also define name:, it will only work if coordinates also defined, otherwise it asking to enter name.

Modding:
- Added support for a fixed location/name starting base (Important: fix either location or location+name... never fix only the name, game will not work correctly if you fix only the name!!)

If you also define coordinates, you'll get segmentation fault.

Invalid coords.

Offline Nikita1221

  • Sergeant
  • **
  • Posts: 10
    • View Profile
Re: [Solved] Crafts can't return if starting base coordinates defined
« Reply #3 on: November 03, 2024, 12:25:57 pm »
Of course coords matter, they need to be on Earth.

Longitude goes from 0 to 2*PI, latitude goes from -PI/2 to +PI/2.

Invalid coords.
Thanks,  making longitude positive did solve issue.
I was confused, because there's no mentioning of this in ruleset reference.

Offline Meridian

  • Global Moderator
  • Commander
  • *****
  • Posts: 9133
    • View Profile
Re: [Solved] Crafts can't return if starting base coordinates defined
« Reply #4 on: November 03, 2024, 12:39:58 pm »
Longitude goes from 0 to 360 degrees (0 to 2*pi radians) and latitude goes from -90 to +90 degrees (-pi/2 to pi/2 radians).

More documentation here:
https://en.wikipedia.org/wiki/Longitude
https://en.wikipedia.org/wiki/Latitude

If you really need that in the ruleset reference, feel free to add it there.