Author Topic: TFTD depth  (Read 5856 times)

Offline Nord

  • Commander
  • *****
  • Posts: 1637
  • The Gate is open.
    • View Profile
TFTD depth
« on: November 18, 2016, 09:22:57 am »
As it seems, depth mechanic in TFTD does not work. Airborne USO not get status "airborne", downed or landed at seabottom gets status "touched down" and maxdepth rules for xcom crafts just ignored. Am i right?

Offline Hobbes

  • Commander
  • *****
  • Posts: 2101
  • Infiltration subroutine in progress
    • View Profile
Re: TFTD depth
« Reply #1 on: November 18, 2016, 07:57:57 pm »
As it seems, depth mechanic in TFTD does not work. Airborne USO not get status "airborne", downed or landed at seabottom gets status "touched down" and maxdepth rules for xcom crafts just ignored. Am i right?

Depth is used to determine the palette/sound during tactical missions. As for interceptions and the 'site is too deep' message I just asked Warboy and he told me to ask SupSuper.

Offline Warboy1982

  • Administrator
  • Commander
  • *****
  • Posts: 2333
  • Developer
    • View Profile
Re: TFTD depth
« Reply #2 on: November 18, 2016, 08:02:10 pm »
it's not "ignored" it's "vestigial"
the values ARE compared, but all the vanilla craft have a max depth of 3, so the check is moot, because nothing really goes below that.

mods, on the other hand...

Offline Nord

  • Commander
  • *****
  • Posts: 1637
  • The Gate is open.
    • View Profile
Re: TFTD depth
« Reply #3 on: November 18, 2016, 08:17:11 pm »
Always thinked, that barracuda originally has max depth 2?
Anyway, values compared and what after? I mean, i manually changed maxdepth of triton to 1 and spot no difference.
« Last Edit: November 18, 2016, 08:19:18 pm by Nord »

Offline Hobbes

  • Commander
  • *****
  • Posts: 2101
  • Infiltration subroutine in progress
    • View Profile
Re: TFTD depth
« Reply #4 on: November 18, 2016, 08:38:26 pm »
Always thinked, that barracuda originally has max depth 2?
Anyway, values compared and what after? I mean, i manually changed maxdepth of triton to 1 and spot no difference.

Me and Warboy have been discussing this issue on the irc channel today since I'm also curious about if and when this feature works. You can read the discussion here: https://colabti.org/irclogger/irclogger_log/openxcom?date=2016-11-18, although the person to ask is SupSuper since he was the one who implemented it.

Offline Nord

  • Commander
  • *****
  • Posts: 1637
  • The Gate is open.
    • View Profile
Re: TFTD depth
« Reply #5 on: November 18, 2016, 10:17:32 pm »
Ok, i am close to understand how it all works, and, well, a bit sad about it. Of course,  i  can write how i want to see this, but i'm not coder, so you pretty sure knows better. Hope SupSuper will answer something encouraging.

Offline AMX

  • Sergeant
  • **
  • Posts: 35
    • View Profile
Re: TFTD depth
« Reply #6 on: November 20, 2016, 12:36:28 pm »
ISTR the only time the "too deep" message came up in the original was when a Barracuda tried to engage a Very Small USO that was moving at max speed.

Offline Nord

  • Commander
  • *****
  • Posts: 1637
  • The Gate is open.
    • View Profile
Re: TFTD depth
« Reply #7 on: November 23, 2016, 04:58:27 pm »
By the way, max hight in xcom1 may be also useful for aircraft mods.

Offline SupSuper

  • Lazy Developer
  • Administrator
  • Commander
  • *****
  • Posts: 2159
    • View Profile
Re: TFTD depth
« Reply #8 on: November 27, 2016, 12:07:32 am »
The only "craft depth" restriction in the original TFTD was that Barracudas couldn't dogfight USOs at Very Deep depth (which is rare). That's it. There were no Battlescape limitations, no transport craft limitations, no site limitations, no polygon limitations, or whatever else you imagined. It's all just flavour, depth is just altitude with a different name.

Therefore, all that "maxDepth" "maxAltitude" does in OpenXcom crafts is:
- Flag the craft as "underwater" (can only dogfight USOs over polygons)
- Can't dogfight USOs with depth (altitude) higher than the value.

So you can theoretically use it in X-COM 1 but it will likely not work as you expect.
« Last Edit: November 27, 2016, 05:47:51 pm by SupSuper »

Offline Nord

  • Commander
  • *****
  • Posts: 1637
  • The Gate is open.
    • View Profile
Re: TFTD depth
« Reply #9 on: November 27, 2016, 07:36:25 am »
- Can't dogfight USOs with depth (altitude) higher than the value.
Exactly that part do not work, as i can see. And that is a problem for me.

Offline SupSuper

  • Lazy Developer
  • Administrator
  • Commander
  • *****
  • Posts: 2159
    • View Profile
Re: TFTD depth
« Reply #10 on: November 27, 2016, 05:50:59 pm »
Well joke's on me, turns out the code only pretended to work when it actually didn't. :P It was mixing site depths and UFO altitudes (which are entirely different things), that's what happens when you overload terms...
I've rewritten the whole dogfight checks to mimic TFTD and renamed the property to "maxAltitude" to avoid confusion.

Offline Nord

  • Commander
  • *****
  • Posts: 1637
  • The Gate is open.
    • View Profile
Re: TFTD depth
« Reply #11 on: November 27, 2016, 06:37:00 pm »
Sorry, it is late evening and i am not native english speaker, so i did not understand nothing. You found a bug? Or you explain how this feature works?

Offline SupSuper

  • Lazy Developer
  • Administrator
  • Commander
  • *****
  • Posts: 2159
    • View Profile
Re: TFTD depth
« Reply #12 on: November 27, 2016, 06:58:01 pm »
You were correct, it was a bug, I fixed it. Now it works same as TFTD. :)

Offline Nord

  • Commander
  • *****
  • Posts: 1637
  • The Gate is open.
    • View Profile
Re: TFTD depth
« Reply #13 on: November 27, 2016, 07:07:00 pm »
Oh, and i see new downloadable build. Thank you very much.