Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ImportGen2Map: Fix imports of malformed maps Fixes #21126 #21150

Merged
merged 1 commit into from Nov 15, 2023

Conversation

tinix0
Copy link
Contributor

@tinix0 tinix0 commented Oct 24, 2023

Fixes #21126
Some of the maps in the bug have unmarked comments before the first section in the map INI file, so we need to skip everything beforehand.

Other maps have invalid bottom bounds. The importer checks if we can correctly unproject the bottom bound, and if not, we reduce it, until it is valid.

@teinarss teinarss requested a review from penev92 October 24, 2023 16:22
OpenRA.Game/Map/Map.cs Outdated Show resolved Hide resolved
OpenRA.Mods.Common/FileFormats/IniFile.cs Outdated Show resolved Hide resolved
Copy link
Member

@PunkPun PunkPun left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overall LGTM, but I'd just really like the unprojection logic to be reused. Could it be extracted into a function inside Map?

Copy link
Member

@PunkPun PunkPun left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@PunkPun PunkPun merged commit 91802e6 into OpenRA:bleed Nov 15, 2023
3 checks passed
@PunkPun
Copy link
Member

PunkPun commented Nov 15, 2023

Changelog

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

A list of TS maps that fail to import
4 participants