Log in

View Full Version : [REL] Battle of Midway Campaign Layer Fix v0.5


tater
06-03-07, 04:32 PM
Version 0.7 cause it's (still) pretty beta :)

JSGME Ready.
http://www.mediafire.com/?f7wt2xutllx

Ver 0.7
My bad, I had the subchasers (part of the invasion forces) set to type=1 (as they are in my campaign) since this allows them to be escorts.

Fixed for general use now.

Ver 0.6
Notes:
Fixed a few things per Jace comments, dunno if I got all of them. Made a single mission version, and it worked until I torpedoed the Nagumo group leader which CTDed me. :/


README:
This is a fixed up Battle of Midway in the CAMPAIGN. This is not a single mission!

The mission is not changed from the layers in the stock SH4 game except for a few things, so don't expect perfect historical accuracy! I might work to make a better version, this is just a version better than the crappy stock version in terms of units used, timing, etc. I only changed IJN units since I don't expect to see the US units much. Except that they move way too far west... that bugs me, maybe I need to change the US stuff, too. I'd delete that, but I haven't gotten that far yet, wait for version 2, lol.

Changes from stock mission:

1. Massive changes in the exact Japanese units shown. All units are now named with their real names. Every DD. All ships except transports. Some substitutions are made. All Kageros Class DDs are subbed with the nearly identical Asashio, Fuso for Nagato, etc. The entire order of battle for the warships on the IJN side is now there. All of them save a few oilers since that would require modding people's tanker speeds and I wanted this vanilla.

2. Massive changes in the formations of the ships. The Kido Butai is set up somewhat properly in a 7-8000m box formation. The Guard DDs behind each CV may or may not leave station, unfortunately. The other groups are made up in terms of how they are arrayed. Anyone with a better idea for the formations of the Main BOdy, Invasion Force, etc, please let me know.

3. A few waypoint changes to get the timings at least somewhat right. Units were still set to start on january 1st in the stock Midway mission. this is now fixed, they start June 1st instead.

4. The stock layer has these ships at sea to start---so does this mod. A future version would back them up into port, but that fouls all the timings up, and this was a quick job for version 0.5, so they start at sea like they do in the stock game.

Enjoy!

tater

ReallyDedPoet
06-03-07, 04:35 PM
Nice to see you tightened this aspect of the game up ( at least the Midway stuff ), look forward to trying it out, nice work:up:

RDP

Jace11
06-03-07, 05:28 PM
Ok I've had a look at it.

I posted one of mine today too somwhere, very similar, though I haven't renamed every ship..

Anyway, watch-out for your larger task-forces running aground in empire waters, I ran the simulation and some destroyers cross land. Just have the task force disappear at an earlier waypoint instead of trying to get a 20k wide formation through a 15k channel.

Also..

Unit config dates.. I have found, by default the game sets units in scripted layers to 1 1938 config...

This is bad, they can then be without radar upgrades, weapon upgrades, airgroup changes, I noticed some of your ships are like this - havent checked all though..

BTW nearly all scripted layers by the dev time are like this... shame the "auto camp editor" cant auto update configs..

Jace11
06-03-07, 05:48 PM
Another thing, have you checked your Nagumo force will appear...? I should have mentioned this in the other thread..

http://www.subsim.com/radioroom/showthread.php?t=110797&highlight=Midway

The problem wasn't the date the layer was called, though it is good practice I think to call the layer first in campaign.cfg - then mission start date, then units spawn date - in chronological order - any other order can create problems...

The problem is the nagumo force spawn before the mission start date.. 06/01 whereas mission starts 06/04..

So it never appeared.. some guy called marky claimed he found the task force in vanilla, but he may have just found the shokaku in the invasion force, many many others reported the task force missing, his two threads devoted to Midway, showing he sank a carrier simply clouded the issue beyond resolve. I know there is something wrong with the layer though.

Though another guy was saying he ran vanilla and saw them on time, however many more people said they waited and never saw them.

Suggest you change your Nagumo force spawn date, or move mission start date earlier. You will then need to call the layer earlier in campaign.cfg..

Once done they appear on time..

tater
06-03-07, 05:56 PM
Ah, rgr. I ran it through time comprssion in the editor, but didn't catch that

tater
06-03-07, 11:24 PM
Version 0.6 up with some fixes per Jace11 (linky top of page)

Here too:

http://mpgtext.net/subshare/192Battle%20of%20Midway%20beta.rar

tater
06-04-07, 12:03 AM
I was hoping to be able to test it easily, but it's hard to do.

I tried changing the campaign.cfg to allow this mission to laod in single missions. Nothing (I made a mission with a tambor right on the path of the nagumo force).

When I made a copy of the mission with an added tabmor for player and made a single mission it worked, but CTDed if I attacked the lead ship in the nagumo force. Grrr.

tater
06-04-07, 12:34 AM
I figured out what the dates in Campaign.cfg are for, Jace.

They are the dates for your PATROL.

Ie: "Load this mission if a patrol starts between this date range."

For Midway it's 1942 02 02. If you start a patrol on/after Feb 2d, and stay out for months (refitting, presumably), you will still see the Midway layer load. If you went out in January, and never RTBed, Midway wouldn't ever load since at the time of your patrol's start, it wouldn't be told (by Campaign.cfg) to load it up.

This is how they get away with not having to load all the damn layers at the same time. You only load the layer you add between a date range to reduce overhead.

tater

tater
06-04-07, 12:46 AM
I tested this time by altering the campaign.cfg to allow this layer to load in Single Missions. Then I made a single mission with naught but a Tambor in the path of the Nagumo Force.

Worked like a charm.

Sank the lead ship, no CTD.

I think it works.

Worst thing is the damn CVs sink with 1 torpedo (shokaku, anyway) every single time for me.

Jace11
06-04-07, 06:43 AM
So you didn't change the mission start date or when the Nagumo Force appears?

Ok, maybe the campaign can cope with spawns before mission start date.

tater
06-04-07, 07:57 AM
I did move all the start dates inside the mission (including the mission itself) to the same date, 19420601.

What I didn't change was the date in the Campaign.cfg file once I realized what it was for.

kakemann
06-04-07, 08:01 AM
Thanks a lot tater! :yep:

dean_acheson
06-04-07, 08:09 AM
Tater,
is there a tutorial on how to mod into the campaign file?

I've been reading through Samuel Morison's History of United States Naval Operations in World War II and was thinking last night that I would love to work a bit on this, esp. some of the earlier stuff including the ABDA and Java campaigns.... as well as some of the stuff coming up the Slot.

That's it, sorry for the inexperience...

tater
06-04-07, 08:17 AM
You can open the files in the campaign folder with the editor and have a look.

If I was making a new battle, I would start over and make a new, scripted mission. You'd only have to add it tot he Campaign.cfg file for it to be added to the campaign. The only trick in that file (copy and paste another battle's entry as a model (make sure the name/number is changed to the new mission, and next number) is the dates. The dates in theat file are NOT the battle dates, but a window for patrols to bother loading the battla mission data.

As for the mission itself, that's simple finding the editor tutorial and messing around. http://www.subsim.com/radioroom/showthread.php?t=115221

Here's a campaign.cfg entry:
[Section 8]
FileName=data/Campaigns/Campaign/41a_Jap_Convoys.mis
StartDate=19390101
EndDate=19420401
GameModes=SingleMission,SinglePatrol,Career,Multip layer Cooperative
InclusionProbability=100
MinimumDifficultyRating=0
MinimumPlayerRating=-3
EntryFocalPointLong=0
EntryFocalPointLat=0
MaximumDistanceFromStartPoint=90000
ExclusiveLayer=No
ExclusiveLayerID=0

The start/end dates (red) are what I was talking about regading the patrols. You need to start your patrol on/after that start date. If you start before that date, the file won't be loaded (otherwise you'd be loading missions from the whole war every patrol, slowing things down). I think all the mission stuff loads at the same time, even if the mission doesn't start (and units appear) until later in the patrol.

The game modes (green) are important to show what type of game gets to load this layer. So if it only says "single mission" it would not load up in the campaign. Note that the random layers in there load up during single games, but not the scripted battle layers.

As an example, you could make my midway layer a single mission in an odd way (I did to test). Edit the Midway entry in campaign.cfg so that it also appears with "SingleMission" in the list. Then make a new single mission. In that mission place a player sub at the right spot NW midway on June 3 or 4 (can merge the mission to see where if you need to). Save the mission with nothing but that player sub there. Since the mission will now load into single missions like the traffic does, you will see my forces stream by.

dean_acheson
06-04-07, 08:25 AM
well, bare with me, I've never even messed around with the mission editor, except a bit in SH3, and was a bit less than successful....

I am a bit more excited about this though... :)

tater
06-04-07, 08:31 AM
Sorry, I edited my post, look up one above your last response!

tater
06-04-07, 08:32 AM
Feel free to bug the mission design forum with questions. I'm not even good at this, I do fairly vanilla stuff, others really grok triggers, etc.

dean_acheson
06-04-07, 10:39 AM
thanks tater.

I guess that this is something that I am super interested in, and need to work on, huh?

Thanks for the help, tonight I'll start seeing if I can't figure out how to minipulate the editor.

tater
06-04-07, 10:58 AM
It's really not that bad. the mission editor in this game is excellent, IMO.

The problem you will have with battles is that the ships just don't fight very well. The engagement ranges for surface combatants is too short, there are no ship-launched torpedos at all, and aircraft are a non-issue unless scripted (actually adding planes to the map one at a time).

I tried to make a Battle of Savo mission. It was pointless without type 93s. Really awful.

The best you can do is to make the right enemy targets follow a path during the right time period, the battles themselves are not worth the time it takes to get them to fight in the first place, IMO. At least in the CV battles you can make the planes fly to the enemy and attack.

tater

Jace11
06-04-07, 11:22 AM
Hmm, what layers ARE used in single missions at the moment?

When I run a single mission, I often run into other ships that are not in the mission you know... subhunters etc..

tater
06-04-07, 11:27 AM
Look at campaign.cfg. The random layers all seem to include "single missions" in their entry. The scripted missions are pretty much just campaign/war patrol.

Note that you could use an altered campaign.cfg as part of a single mission or war patrol if you did it as a JSGME mod. Ie: make your cool single mission. Include a Campaign.cfg with all the layers you don't want to mess with your mission turned off for single missions. Pack it all up JSGME ready.

To play your mission(s) the player installs your mission mod and plays, when done, he reverts to normal campaign mode.

BTW, has anyone tried my mod? I'm curious to know if the ships appear to everyone else, lol.

tater

dean_acheson
06-04-07, 03:33 PM
i guess you could put in some green american ships and some elite japanese ones?

tater
06-04-07, 04:31 PM
Yeah, I didn't mess with the skill levels too much, and the USN stuff I didn't touch at all. I will go ahead and put all the right US ships in next, and I think I will alter the waypoints more next rev to get the US fleet from steaming into a surface engagement with the IJN. I guess I could script a group of VBs to come and trash the Kido Butai as well, lol. It's such a pain to test though.

dean_acheson
06-05-07, 10:55 AM
I worked on SAVO for a few hours last night, mainly learning how to use the mission editor, and then the damn thing crashed on me.

ARRGGGHHH....

tater
06-05-07, 11:05 AM
Save frequently. Usually I've had the editor be pretty stable though.

vindex
06-12-07, 07:56 AM
Installed this and got a crash every time I loaded a saved game (I'm in March 1941). Luckily I backed up, so I restored the original campaign file and had no problems loading the same save files. Obviously the Midway file was causing the crash. Any ideas what's wrong?

tater
06-12-07, 08:13 AM
You can't use this (or any mod that changes the campaign) from a save file.

Argus00
06-12-07, 08:15 AM
@ vindex - load an in-base save game, not one in the middle of a patrol.

@ tater - applied, everything OK. Haven't seen any new traffic at Midway though - maybe because I WAS TOWARDS THE END OF 1943 WHEN I APPLIED THE MOD :rotfl: ... Will test on my new career :up:

tater
06-12-07, 08:38 AM
Yeah, I should have been more clear. The game uses the Campaign.cfg file to load all the appropriate missions you will see when you leave on patrol. So any saves after that point contain all the mission specifics from the moment you leave port.

Changing anything is a 100% CTD at that point, you need to be in port.

BTW, even though I set up this mission like every single other scripted battle mission in the game, and the dates are all right inside the mission, the game seems to have issues loading these layers right.

On the off chance elanaiba looks at this I'll add that like the other scripted battles in game I have the campaign.cfg start/end dates set up (like Coral Sea, 19420202 to 19420915). The Battle of Midway start date for the actual mission is 19420601, and all the units have enter dates of 19420601. None the less, I have loaded a new patrol from PH on June 11th, and seen the Nagumo force a few days later. I'm baffled.

Julius Caesar
06-12-07, 01:36 PM
hmmm. I get a CTD when I try to open your file with sh4 editor...

tater
06-12-07, 01:47 PM
I bet I know what the issue is with that. Doh!

The invasion force contained a few "patrol boats" to be left at Midway once they took it. I used subchasers. I might If I opened it with my subchaser/minelayer changes, it would have been placed as "type=1" which would blow up the editor.

I bet that is it. I will have a look in a little while.

Thanks!

tater

tater
06-12-07, 02:38 PM
^^^ yep, that was it.

http://www.mediafire.com/?f7wt2xutllx

Fixed.

Thanks for the heads up!

Julius Caesar
06-12-07, 02:55 PM
It's working now! :up:

What do you think: should we add a new message to "messages.txt".
Now we get a message on 1942.05.30:
BE ADVISED JAPANESE NAVAL FORCES STEAMING TOWARDS MIDWAY AREA X ALL PATROL VESSELS REQUESTED TO INTERCEPT X

We could change it to more precise orders (go to coordinates xy on date xy)

Even more, we could add a new mission to \Data\Campaigns\Campaign\PatrolObjectives
... similar to, let's say, Sink Celebes Sea. :hmm:

tater
06-12-07, 03:04 PM
Yeah, that would be a good idea.

Actually, that method would work for real ULTRA type stuff which was frequently VERY precise. Ie: "IJN CVE with 4 escorts to meet with CruDiv4 at Lat/Long midday October 15. Will proceed to Kavieng."

vindex
06-14-07, 07:05 AM
I am in port! I said that originally, because I know when the campaigns load. I still get crashes.

tater
06-14-07, 08:08 AM
If you aren't running the latest version it'll crash since it asks for
(my mistake) the subchasers to be "type=1"

r=tater