Editing Addon lua files for bigger armies?

Started by Antstafer, March 15, 2016, 07:11:37 PM

Previous topic - Next topic
I recently have been using BattlebelkToolBox for editing the reinforcement count and spawn count on the main maps, and I tried to see if there way a way to edit custom addon maps to make armies on them bigger also, but to no avail. Is there a way to do this?



It is possible, but it takes some work.

Since most modders never released their lua assets, you will either have to:

-reconstruct the lua based on your guess as to what the unit names (and other details) were

or

-hex edit in the new values into the existing mission.lvl file


Hex editing has a steeper learning curve, but ultimately will give you more flexibility to edit more mission.lvl files.

Quote from: Abraham Lincoln. on November 04, 1971, 12:34:40 PM
Don't believe everything you read on the internet


Quote from: Led on March 15, 2016, 07:45:44 PM
It is possible, but it takes some work.

Since most modders never released their lua assets, you will either have to:

-reconstruct the lua based on your guess as to what the unit names (and other details) were

or

-hex edit in the new values into the existing mission.lvl file


Hex editing has a steeper learning curve, but ultimately will give you more flexibility to edit more mission.lvl files.

Decided to revisit this. I've been looking around the website trying to find tutorials on hex editing, but any tutorial I find is either drastically different than what I'm trying to achieve, or the pictures that go with it are no longer available :/.

If anyone knows what I'd have to hex edit in a level's mission.lvl to make reinforcement and unit counts higher, I'd greatly appreciate it.

March 22, 2016, 05:46:07 PM #4 Last Edit: March 22, 2016, 05:50:14 PM by Led
This is what you need to do:

create a mission.lvl file for a map with a known reinforcement count
create a new mission.file for the same map with twice as many reinforcements and no other changes at all

use the "deep diff" program to search for the difference between the two files
(I will look for a link)  http://www.softpedia.com/get/System/File-Management/Deep-Diff.shtml

use xvi32 to open the file and change the reinforcement count now that you know where to look. 
http://www.chmaas.handshake.de/delphi/freeware/xvi32/xvi32.htm

Keep in mind that it will probably be a hexidecimal value. http://www.binaryhexconverter.com/hex-to-decimal-converter



Here is a link to a tutorial on CP changes to maps--gives you some idea what you will get in to
Quote from: Abraham Lincoln. on November 04, 1971, 12:34:40 PM
Don't believe everything you read on the internet

March 22, 2016, 06:33:54 PM #5 Last Edit: March 22, 2016, 06:40:06 PM by Dingo224
Quote from: Led on March 22, 2016, 05:46:07 PM
This is what you need to do:

create a mission.lvl file for a map with a known reinforcement count
create a new mission.file for the same map with twice as many reinforcements and no other changes at all

use the "deep diff" program to search for the difference between the two files
(I will look for a link)  http://www.softpedia.com/get/System/File-Management/Deep-Diff.shtml

use xvi32 to open the file and change the reinforcement count now that you know where to look. 
http://www.chmaas.handshake.de/delphi/freeware/xvi32/xvi32.htm

Keep in mind that it will probably be a hexidecimal value. http://www.binaryhexconverter.com/hex-to-decimal-converter



Here is a link to a tutorial on CP changes to maps--gives you some idea what you will get in to

Thanks for the help Led =). Directions are a little confusing for me to follow, but it's my fault for not explaining further.

I got this custom map I downloaded that's basically like the invasion of Omaha Beach but with Battlefront, lol. My only gripe with the level is that it could use a lot more units. 

So in order to increase the unit count/reinforcements, I'll have to do the following?-
1. Take the mission.lvl from some other map that has an already modified unit count (like my modded Geonosis).
2. Use the deep diff program to find differences between the geonosis mission.lvl and the custom map's mission.lvl.
3. Continue with xvi32 etc.

I have a feeling I got the wrong idea though. The hex values for the levels would be so different that it'd be impossible to find the right ones. I'm not even sure how to go about creating a mission.lvl for a map.

You need to find the location of the reinforcement count in mission.lvl.  The easiest way to do that is to work with a mission.lvl file that you can change using battlebelks misison builder.

Once you know what to look for then you can look for that location in the mission.lvl file you really want to edit.

Please attach the mission.lvl file you want to edit to this post and I will see what I can do.

Quote from: Abraham Lincoln. on November 04, 1971, 12:34:40 PM
Don't believe everything you read on the internet


Quote from: Led on March 22, 2016, 06:43:47 PM
You need to find the location of the reinforcement count in mission.lvl.  The easiest way to do that is to work with a mission.lvl file that you can change using battlebelks misison builder.

Once you know what to look for then you can look for that location in the mission.lvl file you really want to edit.

Please attach the mission.lvl file you want to edit to this post and I will see what I can do.

I'll give it a go myself, but here's the custom map's file anyway.

One more question--what was the original ticket count for this map?
Quote from: Abraham Lincoln. on November 04, 1971, 12:34:40 PM
Don't believe everything you read on the internet


Quote from: Led on March 22, 2016, 07:27:35 PM
One more question--what was the original ticket count for this map?

Not sure what you mean by ticket count, but I have a good guess.

Attacker- 325
Defender- 250

Yes, that is what I meant.  OK, try this file.  Be sure to back up your original, and then rename this one to mission.lvl.  If it works, I will show you a video of what I did :)

(this one should give the attacker 1002 tickets (reinforcements = tickets)
Quote from: Abraham Lincoln. on November 04, 1971, 12:34:40 PM
Don't believe everything you read on the internet

Worked like a charm! Thanks Led =). Simple, easy to follow tutorials as always.

The unit count should be pretty easy to change too following this method. I'll see what I can do on my own.

awesome.

The values were not in the spot that I thought they would be in your mission file, so this final video installment shows how I located them (and had a lucky guess)

https://youtu.be/_3glnEOW1Vs

Quote from: Abraham Lincoln. on November 04, 1971, 12:34:40 PM
Don't believe everything you read on the internet