aliens

Author Topic: [SUGGESTION] Spawn crafts in hangars on base defense  (Read 1443 times)

Offline Finnik

  • Colonel
  • ****
  • Posts: 492
  • Finnik#0257
    • View Profile
[SUGGESTION] Spawn crafts in hangars on base defense
« on: November 26, 2022, 11:19:34 am »
I know that this topic has probably been discussed more than once in the OpenXcom community. And since there's nothing like that in the game so far, it's likely that such suggestions have been rejected repeatedly. However, I would very much like to get an up-to-date status from the OXCE developers, also to take this into account in planning my own activities. Like many (it seems to me) players, I wondered how it was possible to completely evacuate base personnel and crafts in such a swift alien assault. But after seeing these screenshots of the original game's modification recently, I can't stop thinking about a new game feature that would display the player's ships in the hangar.

(source: https://www.strategycore.co.uk/files/bbs-toolkit/)
Aside from the aesthetic component, this would provide aliens with additional cover in the hangars.
I think I can more or less imagine a significant amount of work to implement such an engine feature, there will be a lot of problems - you need to check the size of the kraft map, center it (of course, check if there is a map for it at all).
« Last Edit: November 27, 2022, 02:44:20 pm by Finnik »

Offline Yankes

  • Commander
  • *****
  • Posts: 3207
    • View Profile
Re: [QUESTION] Spawn crafts in hangars on base defense
« Reply #1 on: November 26, 2022, 01:05:34 pm »
And how it will handle multi craft hangars? Another thing is this will need some prepossessing of craft to remove exit tiles, or on other hand would be fun if you can quit base defense and transfer your solders to other base?

Offline Finnik

  • Colonel
  • ****
  • Posts: 492
  • Finnik#0257
    • View Profile
Re: [QUESTION] Spawn crafts in hangars on base defense
« Reply #2 on: November 26, 2022, 03:36:59 pm »
Right, multiple crafts can be an issue, that can be avoided with manually definition of rects, where craft maps can be placed. If modder did not provide enough rects to create all craft map - skip rest craft maps spawning. If rect is not large enough to spawn craft map - go to the next rect, if rects.end() - also skip the craft map spawning.
Yes, we shoulf preprocess maps to clear start-exit tiles and inventory tile, or in will corrupt base defense soldier-item placement. But AFAIK, all this info is related to map, but can be separated from pure map block placement.

Offline Meridian

  • Global Moderator
  • Commander
  • *****
  • Posts: 8616
    • View Profile
Re: [QUESTION] Spawn crafts in hangars on base defense
« Reply #3 on: November 27, 2022, 10:20:34 am »
I don't remember this being discussed, but I may just have forgotten.
Anyway, this is not on my "rejected list".

Personally, it is too low priority for me to be implemented in the near future... but if someone implements it, and the code is not too invasive, I wouldn't mind a PR.

Offline Finnik

  • Colonel
  • ****
  • Posts: 492
  • Finnik#0257
    • View Profile
Re: [QUESTION] Spawn crafts in hangars on base defense
« Reply #4 on: November 27, 2022, 02:43:53 pm »
Ok, and what do you think @Yankes?

Offline Yankes

  • Commander
  • *****
  • Posts: 3207
    • View Profile
Re: [SUGGESTION] Spawn crafts in hangars on base defense
« Reply #5 on: November 27, 2022, 02:57:48 pm »
I too not against, if code is clear and not unneededly complicated then I would be for inclusion to OXCE.
Only question is how it will be defined in ruleset, how it will handle multiple crafts and how handle crafts that do not have battlesapce mode?

Offline Finnik

  • Colonel
  • ****
  • Posts: 492
  • Finnik#0257
    • View Profile
Re: [SUGGESTION] Spawn crafts in hangars on base defense
« Reply #6 on: November 27, 2022, 04:08:00 pm »
I too not against, if code is clear and not unneededly complicated then I would be for inclusion to OXCE.
Only question is how it will be defined in ruleset, how it will handle multiple crafts and how handle crafts that do not have battlesapce mode?

well, obviously, crafts without battlescape data will be ignored. All this feature, IMO, should be locked under ruleset option, as vanilla does not have required date for interceptor and firestorm. Multiple crafts adds a layer of complexity. I personally dislike multiple crafts per hangar, as they even can't be shown in basescape. I know, some mods, like UNEXCOM uses this feature to have tens of crafts in wing formations.
From a game design perspective, if I would like to have many crafts launched in formation from the base I would rather expand the base frame in some way (like infinite base tiles, rejected at some point for both OXC and OXCE). Although, it's an off-topic...

Any way, as I personally don't need to handle many crafts in one hangar, I have to ask - since we display only a single craft image in base view, why we should add complexity to battlescape map? I mean, if the modder will keep new global option false (will be default value, of), they will have current behavior. If they don't care about not having it displayed in base view, why they would care about not shown crafts on battlescape? AFAIK, all mods with many crafts in hangar still use vanilla hangar assets, both basescape and battlescape.

So, I've presented possible solution with rects in message above, but I'd rather gather feedback from the community, if it ever needed. Even if no strong feedback presented, I'd rather make an MVP solution, that would work for 90% cases.

Offline Meridian

  • Global Moderator
  • Commander
  • *****
  • Posts: 8616
    • View Profile
Re: [SUGGESTION] Spawn crafts in hangars on base defense
« Reply #7 on: November 27, 2022, 04:15:32 pm »
I have to ask - since we display only a single craft image in base view, why we should add complexity to battlescape map?

This will change at some point, but you don't have to worry about it now.
You can make it under this assumption and I'll take care of the rest when the time comes.