MW2.PRJ patching

General Mech2 related Developments go here. Discussions welcome!

Moderator: Skyfaller

Forum rules
If you are writing a guide please do not post it here! Post in the Dev FAQ section please.
User avatar
Sir MMPD Radick
Clan Nova Captain
Clan Nova Captain
Posts: 1625
Joined: Tue Jan 22, 2008 10:07 am

MW2.PRJ patching

Post by Sir MMPD Radick »

Unfortunately Kell, I think for most people interested in trying new maps it is unlikely they know how to run a hex editor or mechvm as it is can be quite confusing...
May I suggest that you package your maps with an auto patcher of some kind? I believe that kontza used a combination of .bat & vim to do this.
I am sure there are better automated solutions than that though.
James 3:5-10: My Reminder
And the tongue is a fire, a world of iniquity: so is the tongue among our members, that it defileth the whole body. Out of the same mouth proceedeth blessing and cursing. My brethren, these things ought not so to be.
User avatar
Skyfaller
Clan 1st MechWarrior
Clan 1st MechWarrior
Posts: 1017
Joined: Sat Apr 12, 2008 2:58 am
Location: Germany
Contact:

Re: Anyone want some new 31cc maps?

Post by Skyfaller »

It should not be too hard to extend MechVM with a little script processor to execute such patches. Possibly commands:

Select Target - Bring up file selection dialog to allow the user to select the target file (MW2.PRJ)
acd - Change directory in archive file (MW2.PRJ)
replace - Replace one file in the PRJ with another
add - Add file to PRJ, once I figure out how to do that
patch - Use some binary file as input to patch another file

Kell, if you want to create a new campaign rather than single missions, I could show you how to use MechVM to display the shell and have it call MW2 to run the actual missions, but it won't happen next week. It would require understanding mission objectives and somebody would have to write mission texts.
User avatar
Sir MMPD Radick
Clan Nova Captain
Clan Nova Captain
Posts: 1625
Joined: Tue Jan 22, 2008 10:07 am

Re: Anyone want some new 31cc maps?

Post by Sir MMPD Radick »

If you like I probably could write up a cheap little(NON-GUI) program that will do that. It will have to wait until after the finals though (next week & this week) .
It probably would work better if the automation was prescripted.... say for instance if it was a little program that was run automatically out of a rar extractable executable.
The program would not even really understand the PRJ I do not think.. I believe it could be done if it was told locations to modify. Admittedly I could not write one to add files, but for a short term solution it would work.

The only reason I think it should be down those lines is that I know if it is not automated and people have to click several steps there will be a flood of support requests......
James 3:5-10: My Reminder
And the tongue is a fire, a world of iniquity: so is the tongue among our members, that it defileth the whole body. Out of the same mouth proceedeth blessing and cursing. My brethren, these things ought not so to be.
User avatar
Skyfaller
Clan 1st MechWarrior
Clan 1st MechWarrior
Posts: 1017
Joined: Sat Apr 12, 2008 2:58 am
Location: Germany
Contact:

Re: Anyone want some new 31cc maps?

Post by Skyfaller »

My best wishes and good luck with your finals, MMPD! I hope when they are done, we all find more time to meet on IRC again, which may be better suited to discuss some things than this forum. If you need to discuss computer science related stuff or if there's something in the literature you don't understand, feel free to pm me. What kind of tests are you facing, oral or written?

I could show you how to use MechVM's sources to compile a standalone tool. It would have the advantage that no script processor would be needed. If that tool knows the structure of the PRJ, it can apply patches to different versions of the PRJ. If you use MechVM sources, the patch tool would have to be released under GPL, though. If you wish to distribute several Map Packs, Kell, do you know how to program in C/C++, and do you have Visual Studio?
User avatar
Sir MMPD Radick
Clan Nova Captain
Clan Nova Captain
Posts: 1625
Joined: Tue Jan 22, 2008 10:07 am

Re: Anyone want some new 31cc maps?

Post by Sir MMPD Radick »

Thanks, I definitely will need it today! Yep, I will be coming back on IRC after today probably. I have been off of there because I did not want any distractions.
BTW, I am sorry if I came off in my last post as pushy I really was not meaning to. Just wanted to help really, and it came out in the wrong way I think. :| I do not want to take over the project if you already have the design and such in mind, and want a crack at it.

I could show you how to use MechVM's sources to compile a standalone tool. It would have the advantage that no script processor would be needed. If that tool knows the structure of the PRJ, it can apply patches to different versions of the PRJ. If you use MechVM sources, the patch tool would have to be released under GPL, though.
That would be great, I would love to use what you have already as it certainly would save some time and be better in the long run.
I do not mind GPL, for this one I was planning to give away the source anyway. :)
James 3:5-10: My Reminder
And the tongue is a fire, a world of iniquity: so is the tongue among our members, that it defileth the whole body. Out of the same mouth proceedeth blessing and cursing. My brethren, these things ought not so to be.
User avatar
Skyfaller
Clan 1st MechWarrior
Clan 1st MechWarrior
Posts: 1017
Joined: Sat Apr 12, 2008 2:58 am
Location: Germany
Contact:

Re: Anyone want some new 31cc maps?

Post by Skyfaller »

Good luck again, and don't worry about us!
User avatar
Col.Kell
House Steiner Archon
House Steiner Archon
Posts: 868
Joined: Sat Sep 27, 2008 7:44 am
Location: An Isolated Tennessee Valley.

Re: Map #Include Automation

Post by Col.Kell »

Kell, do you know how to program in C/C++, and do you have Visual Studio?
Sadly, no. I don't know the C/C++ language, the only one I know is the BASIC language, and I'm still learning. And nor do I have "Visual Studio". :(
Unless this doesn't require learning a new computer language, if you or Radick would like to compose a patcher that will install the map pack(s), feel free.
Kell, if you want to create a new campaign rather than single missions, I could show you how to use MechVM to display the shell and have it call MW2 to run the actual missions, but it won't happen next week. It would require understanding mission objectives and somebody would have to write mission texts.
I do have some understanding of how to compose missions by just using a text editor, I've done it with Mercs, with the exeption of AI personalities 31cc works the same way. I do know how to create geometry in specific spots, make the PLT1 file, set a timer, mech bitmaps, the nav points, music, and even a few simple mission objectives such as destroying. I don't know how to make those complicated objectives such as what you may see on things like the last falcon mission and the like.
But sure, if you would like to show me how to make a new campaign, that would be cool. :)
MechWarrior 2: 31stCC
Image
User avatar
Sir MMPD Radick
Clan Nova Captain
Clan Nova Captain
Posts: 1625
Joined: Tue Jan 22, 2008 10:07 am

Re: Map #Include Automation

Post by Sir MMPD Radick »

Just wanted to apologize to everyone that i never got around to this.
Sorry!
James 3:5-10: My Reminder
And the tongue is a fire, a world of iniquity: so is the tongue among our members, that it defileth the whole body. Out of the same mouth proceedeth blessing and cursing. My brethren, these things ought not so to be.
User avatar
Skyfaller
Clan 1st MechWarrior
Clan 1st MechWarrior
Posts: 1017
Joined: Sat Apr 12, 2008 2:58 am
Location: Germany
Contact:

Re: Map #Include Automation

Post by Skyfaller »

No problem, MMPD, been busy with other things myself.

I'll see if I can make a patcher after adding files to the PRJ works (or if I give up). If the files would be added rather than replaced, the original campaigns would be left intact.

The patcher would include both Map Packs (1, 2). It applies to MW2 DOS, if I am not mistaken.

Does that sound workable, Kell?
User avatar
Col.Kell
House Steiner Archon
House Steiner Archon
Posts: 868
Joined: Sat Sep 27, 2008 7:44 am
Location: An Isolated Tennessee Valley.

Re: Map #Include Automation

Post by Col.Kell »

Sure! If you can come up with a patcher that will automaticaly install the map packs, that's fine with me.
I have no clue about C++, batch files, and all this other stuff. ;)

And that would be even GREATER if you can configure MVM to replace files with larger ones. In your 12-12-08 version of MVM, I tried this out, but only with .WTB files. Results came up negative. I'll need to look into other files such as BWDs...

If possible, please make sure the patcher does include TOG_MP2 (the flaming galuzza map), because that one is very special from the other skirmish maps, and I don't doubt someone will want to play it. :)
MechWarrior 2: 31stCC
Image
Post Reply