Terrain munge error [Solved]

In this forum you will find and post information regarding the modding of Star Wars Battlefront 2. DO NOT POST MOD IDEAS/REQUESTS.

Moderator: Moderators

Post Reply
kiprobin
First Lance Corporal
First Lance Corporal
Posts: 120
Joined: Wed Dec 11, 2019 3:52 pm
Projects :: Trench War
Games I'm Playing :: Swbf2
xbox live or psn: No gamertag set

Terrain munge error [Solved]

Post by kiprobin »

I've been working on a new map and it's been going fine, but recently I've been getting this and I've no idea why:

Code: Select all

This application has requested the Runtime to terminate it in an unusual way.
Please contact the application's support team for more information.
ERROR[levelpack Y41.req]:Expecting bracket, but none was found.
File : munged\pc\y41.terrain.req(1)...

ucft <--
ERROR[levelpack Y41.req]:Expecting bracket, but none was found.
File : munged\pc\y41.terrain.req(1)...

ucft <--
 [continuing]
   2 Errors    0 Warnings

ERROR[levelpack Y41_conquest.mrq]:Could not open munged\pc\mz.files for input. DOS reports:
No such file or directory
ERROR[levelpack Y41_conquest.mrq]:Could not open munged\pc\mz.files for input. DOS reports:
No such file or directory
 [continuing]
   2 Errors    0 Warnings

ERROR[levelpack Y41.req]:Expecting bracket, but none was found.
File : munged\pc\y41.terrain.req(1)...

ucft <--
ERROR[levelpack Y41.req]:Expecting bracket, but none was found.
File : munged\pc\y41.terrain.req(1)...

ucft <--
 [continuing]
   2 Errors    0 Warnings
I'm pretty sure most of the subsequent errors are just the result of the initial terrain munge error. I've done a manual clean, and I didn't even change much of the terrain since last testing it, so I'm not sure why this is happening or what to do. I'd only really done command posts, planning, barriers, hintnodes, etc. since last testing it, with only very minor terrain alterations. I've seen other threads about this, but no one seems to have found a solution yet, or at least a cause so I can backtrack and fix
Last edited by kiprobin on Thu Jul 14, 2022 7:51 am, edited 1 time in total.
kiprobin
First Lance Corporal
First Lance Corporal
Posts: 120
Joined: Wed Dec 11, 2019 3:52 pm
Projects :: Trench War
Games I'm Playing :: Swbf2
xbox live or psn: No gamertag set

Re: Terrain munge error

Post by kiprobin »

UPDATE:
I tried the suggestions made here in 2008
Have a look at the terrain.req file located in data_HFP/_BUILD/Worlds/HFP/Munged/PC
It should look sort of like this but with your list of textures.


ucft
{
REQN
{
"texture"
"yav2_main_1"
"yav2_main_2"
"yav2_main_3"
"yav2_main_4"
"yav_detail"
}
}

If it does try doing a manual clean then remunge. If it doesn't try doing a save terrain in ZE, do a normal save but in the Save As Type selection at the bottom select terrain. Exit ZE and have a look at the file again and see if it looks normal.
I did not initially have the textures listed there, so I saved as a terrain file, manually cleaned, and munged, but afterword, it did not look normal and in fact did not appear at all. There was no terrain.req file there whatsoever. I ran the game and while it worked and I could spawn, there was no terrain of any kind and you just fell down infinitely. I munged a second time and while the terrain.req was present, it still did not display anything like this example with the textures listed
User avatar
Teancum
Jedi Admin
Jedi Admin
Posts: 11080
Joined: Wed Sep 07, 2005 11:42 pm
Projects :: No Mod project currently.
Games I'm Playing :: Destiny
xbox live or psn: No gamertag set
Location: Indiana

Re: Terrain munge error

Post by Teancum »

What are the dimensions of your terrain? It must be square and a power of 2, I.E. 256x256, 512x512 or 1024x1024. Don't go higher than that. If it's one of those you could try manually saving your terrain. In ZeroEdit you can save, then click the dropdown to save the terrain TER file.


Let me know if either of those things helps.
kiprobin
First Lance Corporal
First Lance Corporal
Posts: 120
Joined: Wed Dec 11, 2019 3:52 pm
Projects :: Trench War
Games I'm Playing :: Swbf2
xbox live or psn: No gamertag set

Re: Terrain munge error

Post by kiprobin »

Terrain has always been 1024 by 1024 for all my maps, which I know works and has never been an issue. I had already tried manually saving a .ter file, but it left no terrain.req whatsoever in the munged_pc folder, correct or otherwise. Also, did just kinda find a work around, though I still have no idea what caused it. I opened up the terrain.req in the munged pc file (which was empty - it just "ucft" and nothing else) and manually typed in the textures my map uses on the terrain following this example.

ucft
{
REQN
{
"texture"
"yav2_main_1"
"yav2_main_2"
"yav2_main_3"
"yav2_main_4"
"yav_detail"
}
}

I then deleted the messed up lvl files and stuff in the build and data_lvl folders (but leaving the munged_pc folders, bc I needed the modified terrain.req folder to stay), munged, and it worked. I hope I don't have to do that semi-manual clean every time to prevent this from happening, and I still have no idea what caused this, but I'll call it solved for now.
Post Reply