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

Map made in blender export using plugin doesn't work despite having similar / same map file #140

Open
babypandabear3 opened this issue Oct 12, 2021 · 5 comments

Comments

@babypandabear3
Copy link

Make a simple test map using Blender and export to .map using https://github.com/c-d-a/io_export_qmap
Qodot can't load it
but same file loads in trenchbroom, and after saved by trenchbroom the map file works
map.zip

@babypandabear3
Copy link
Author

if I add an empty line at the end of blender exported map file then qodot would be able to read it

@DeerTears
Copy link
Member

DeerTears commented Oct 15, 2021

Thanks for the two .map files. What version of Qodot are you using? (Version number + where you downloaded it from)

I don't have a full answer, but I have more information:

Checking the diff between these two files reveals that it's basically just the way this blender plugin chooses to not name brushes. It doesn't seem like any change in curly brace depth or anything. The important thing is that Trenchbroom knows how to parse un-named and give them names, while Qodot is expecting named brushes.
image

Also, it seems that something's going on where the material assignments are changing, but if it works fine (materials and all) when you go Blender -> io_export_qmap -> Trench -> Qodot then hopefully this should be fine if we can solve the named brush issue.
image

Trenchbroom's doc of the .map file format doesn't seem to indicate much about why it names these brushes, I'm guessing it's a quake thing but some engines don't have/need it. https://trenchbroom.github.io/manual/latest/index.html#preliminaries

I can't say much else with certainty cause I've still got to dig into the Qodot parsing code to know how doable it'd be to parse brushes without names. Trenchbroom can do it, hopefully Qodot could too. If not, I could see if there's a way to insert placeholder brush names into the .map export of that blender plugin so it fits what Qodot expects.

@babypandabear3
Copy link
Author

It's version 1.7.1 and I downloaded from github

Most interesting part is, if I add empty space at the end of blender generated file then Qodot can import the map so changing blender export script and simply adding \n to the end of file fix it

@DeerTears
Copy link
Member

Oh, literally just an EOF newline issue 😅 that's a thing with a lot of different programs. I could add that to the blender script faster than I could change qodot's parsing.

@DeerTears
Copy link
Member

@babypandabear3 See if this alternative script fixes it: https://github.com/DeerTears/io_export_qmap

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

No branches or pull requests

2 participants