aliens

Author Topic: Re: TFTD depth  (Read 1573 times)

wcho035

  • Guest
Re: TFTD depth
« on: September 08, 2019, 02:22:38 pm »
Hi, I found this topic on the forum and I am trying to understand more of this Depth mechanic.

From reading it, https://openxcom.org/forum/index.php/topic,5069.msg75179.html#msg75179

It says some part it mimicked TFTD.

From the snippet of conversation.

- Flag the craft as "underwater" (can only dogfight USOs over polygons)

This code is not in the ruleset, is it possible?

for maxAltitude 0 to 4 indicate the height the craft can go, if it is underwater, would it be negative? For submersible only.

The documentation on the ruleset are not enough to explain it all.

Offline The Martian

  • Commander
  • *****
  • Posts: 754
  • "It implores you to listen to its arguments..."
    • View Profile
Re: TFTD depth
« Reply #1 on: September 08, 2019, 04:18:36 pm »
I'm not familiar enough with this mechanic to say anything definitive on the topic, so take what I say with a grain of salt.

I don't think that negative altitude comes into play but I could be wrong.

If I understand it correctly depth may also be used to effect the battlescape palettes in TFTD based on how deep the enemy sub crashed.

Also judging by the UFOpaedia the Crafts variable for maxAltitude can only be set to -1 or 0 through 4. Craft at a greater height than the X-Com crafts max cannot be engaged.
(I'm assuming -1 equals being able to engage a UFO at any height/depth.)


I think that TFTD is just using UFO's altitude system with the higher numbers being deeper instead of being higher.

Quote from: UFOpaedia - Ruleset Reference Nightly
maxAltitude    Maximum altitude (0-4) this craft can dogfight to.

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.

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.

Quote from: UFOpaedia - Battle Enviro Effects
paletteTransformations    A list of palette transformations (oldPaletteName: newPaletteName) to apply during the mission (or mission stage). New palettes should be similar to original palettes, they should only convey visual effects like pollution, underwater environment, etc. For UFO-based mods only one palette (PAL_BATTLESCAPE) needs to be changed, for TFTD-based mods up to 4 palettes (for each depth).






Edit:
After reading this I don't think there is a variable that assigns a craft as being "underwater" so much that when at X maxAltitude the craft is deemed as being in an "underwater" state automatically.

From the snippet of conversation.

- Flag the craft as "underwater" (can only dogfight USOs over polygons)

This code is not in the ruleset, is it possible?
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: September 08, 2019, 04:26:12 pm by The Martian »

wcho035

  • Guest
Re: TFTD depth
« Reply #2 on: September 08, 2019, 04:29:22 pm »
Hmm, then they should have a max depth in the coding for USO interception and flying craft can't intercept them. Oh well, have to plead to the OXCE team for the coding.. if they are willing to do it.