SUBSIM Radio Room Forums



SUBSIM: The Web's #1 resource for all submarine & naval simulations since 1997

Go Back   SUBSIM Radio Room Forums > Silent Hunter 3 - 4 - 5 > SH4 Mods Workshop
Forget password? Reset here

Reply
 
Thread Tools Display Modes
Old 11-28-23, 02:43 PM   #1021
propbeanie
CTD - it's not just a job
 
propbeanie's Avatar
 
Join Date: May 2016
Location: One hour from Music City USA!
Posts: 9,749
Downloads: 439
Uploads: 2


Default

Quote:
Originally Posted by LuckyCapitan View Post
Hello. There is a problem. Tell me why, after creating a new base in Flotillas.upc and Patrol Object.upc, when you try to start a campaign, the game crashes to the desktop? I'm trying to make a base in Rabaul, but it's not working
It is next to impossible to tell you what is wrong, but you have to edit the NavalBase.mis file to have a naval base at Rabaul. Then the Flotillas.upc file to put the flotilla, base and boat(s) there. Be careful of the "DepartureDescription" lines, which is the location of where your boat will spawn-in when using that particular flotilla. You do not want to spawn into a dock or dry land, because that will cause a CTD, as would other mistakes in any of the following. Flotillas are numbered consecutively, as are the boats, and the boat "name" for the flotilla will use that flotilla number in its "definition", such as "F1JyunsenB" for the 1st Flotialla, or "F23JyunsenB" for the 23rd Flotilla (if you have that many). Be careful of date ranges for the boats also. You cannot be outside of the SunName.upc file's Availability range. The rest of the definition would be very similar to the other boats of the same type. You then have to have mission entries for the new boat, following the same consecutively numbered scheme of the previous boats. Then you probably want to add some "starts" to the CareerStart.upc file, so that you can start there.
__________________

"...and bollocks to the naysayer/s" - Jimbuna
propbeanie is offline   Reply With Quote
Old 11-28-23, 03:51 PM   #1022
LuckyCapitan
Watch
 
Join Date: Jun 2022
Posts: 30
Downloads: 172
Uploads: 0
Default

Quote:
Originally Posted by propbeanie View Post
It is next to impossible to tell you what is wrong, but you have to edit the NavalBase.mis file to have a naval base at Rabaul. Then the Flotillas.upc file to put the flotilla, base and boat(s) there. Be careful of the "DepartureDescription" lines, which is the location of where your boat will spawn-in when using that particular flotilla. You do not want to spawn into a dock or dry land, because that will cause a CTD, as would other mistakes in any of the following. Flotillas are numbered consecutively, as are the boats, and the boat "name" for the flotilla will use that flotilla number in its "definition", such as "F1JyunsenB" for the 1st Flotialla, or "F23JyunsenB" for the 23rd Flotilla (if you have that many). Be careful of date ranges for the boats also. You cannot be outside of the SunName.upc file's Availability range. The rest of the definition would be very similar to the other boats of the same type. You then have to have mission entries for the new boat, following the same consecutively numbered scheme of the previous boats. Then you probably want to add some "starts" to the CareerStart.upc file, so that you can start there.

The problem is that I did it all. But even so, I can't even log into CaptainRoom. I will, of course, check everything again. I hope that I just made a mistake somewhere or didn’t finish writing
LuckyCapitan is offline   Reply With Quote
Old 11-29-23, 11:48 AM   #1023
mazzi
Mate
 
Join Date: Mar 2018
Posts: 56
Downloads: 551
Uploads: 0
Default

Quote:
Originally Posted by LuckyCapitan View Post
The problem is that I did it all. But even so, I can't even log into CaptainRoom. I will, of course, check everything again. I hope that I just made a mistake somewhere or didn’t finish writing
Perhaps in the sh4 game universe there is no 3D object for the port of Rabaul.
I need to learn how to place 3D objects of new ports on the map, unfortunately I don’t know how to do this.
mazzi is offline   Reply With Quote
Old 11-29-23, 12:41 PM   #1024
KaleunMarco
Silent Hunter
 
KaleunMarco's Avatar
 
Join Date: Sep 2007
Location: Chicago area, which is more dangerous than Omaha Beach.
Posts: 3,917
Downloads: 436
Uploads: 27


Default

Quote:
Originally Posted by mazzi View Post
Perhaps in the sh4 game universe there is no 3D object for the port of Rabaul.
I need to learn how to place 3D objects of new ports on the map, unfortunately I don’t know how to do this.
i believe some "ports" or "bases" in SH4 use standard definitions (port or base) and some have specific definitions. check out the Terrain folder for specifics.
__________________
there are only two things in the world: submarines and targets.
Fortis et stabilis et fidelis, semper


------------------------------------------------------------
Silent Hunter 4 1.5 Gold Edition on CDROM
LAA enabled
Dell XPS with 32 GB Ram running Win10
KaleunMarco is offline   Reply With Quote
Old 11-29-23, 01:12 PM   #1025
mazzi
Mate
 
Join Date: Mar 2018
Posts: 56
Downloads: 551
Uploads: 0
Default

Quote:
Originally Posted by KaleunMarco View Post
i believe some "ports" or "bases" in SH4 use standard definitions (port or base) and some have specific definitions. check out the Terrain folder for specifics.
Everything is correct, the question is how to make, for example, Kure Naval Base, which is not in sh4 at all?
mazzi is offline   Reply With Quote
Old 11-29-23, 04:34 PM   #1026
KaleunMarco
Silent Hunter
 
KaleunMarco's Avatar
 
Join Date: Sep 2007
Location: Chicago area, which is more dangerous than Omaha Beach.
Posts: 3,917
Downloads: 436
Uploads: 27


Default

Quote:
Originally Posted by mazzi View Post
Everything is correct, the question is how to make, for example, Kure Naval Base, which is not in sh4 at all?
caveat: i am no expert at what you are attempting but i have some suggestions.

it appears that cities/ports that have a physical/geographical appearance in SH4 have some things in common.
a. they have .DAT files in \Data\Terrain\Locations. you can use one as a model for Kure and then use skwas' S3Ditor to edit the new Kure file.
b. once you have created the .DAT, add that new file name as an entry to the \Data\Campaigns\Campaign\Campaign_LOC.mis file, using the existing entries as a model.

you should probably create a separate mod folder under JSGME for these changes so that you can keep things separated and by using JSGME you can apply them and remove them at will.

apply the mod and go look at your creation.

as i led off with, i have never done this but there appears to be a path to success.

good luck!
__________________
there are only two things in the world: submarines and targets.
Fortis et stabilis et fidelis, semper


------------------------------------------------------------
Silent Hunter 4 1.5 Gold Edition on CDROM
LAA enabled
Dell XPS with 32 GB Ram running Win10
KaleunMarco is offline   Reply With Quote
Old 11-30-23, 06:17 AM   #1027
propbeanie
CTD - it's not just a job
 
propbeanie's Avatar
 
Join Date: May 2016
Location: One hour from Music City USA!
Posts: 9,749
Downloads: 439
Uploads: 2


Default

Quote:
Originally Posted by mazzi View Post
Perhaps in the sh4 game universe there is no 3D object for the port of Rabaul.
I need to learn how to place 3D objects of new ports on the map, unfortunately I don’t know how to do this.
Using the SH4 Mission Editor to open the "\Game \Data \Campaigns \CampaignGE \CampaignData \Axis_NavalBases.mis" file, which is what the Japanese campaign uses as its "base", we see all of the NavalBases available in that side of the game:




In this image, I zoomed in a little closer, and "merged" without Save the Campaign_LOC.mis file, which when editing the German side of SH4, uses the "\Game \Data \Campaigns \Campaign" file, we see the "physical" representation of the "dock" there, which is a 3D and 2D "Map Location", edited by enabling the "Tools - Map location edit mode" menu item in the SH4 Mission Editor:



Note that the "NavalBase" is in the same location as previous, from the Axis_NavalBase file, and it on "land". Technically, you don't need the dock, only the NavalBase from the Land folder, and you have a working Naval Base. The dock is just the visual reinforcement for the players eyes of a working sea port...
__________________

"...and bollocks to the naysayer/s" - Jimbuna
propbeanie is offline   Reply With Quote
Old 11-30-23, 06:44 AM   #1028
propbeanie
CTD - it's not just a job
 
propbeanie's Avatar
 
Join Date: May 2016
Location: One hour from Music City USA!
Posts: 9,749
Downloads: 439
Uploads: 2


Default

Quote:
Originally Posted by mazzi View Post
Everything is correct, the question is how to make, for example, Kure Naval Base, which is not in sh4 at all?
Kure, like Rabaul, already has a "physical" representation of docks, as found in the Campaign_LOC.mis file:




To make that a Japanese Naval Base, you first open the Axis_NavalBase.mis file first, and then "Merge without Save" with the Campaign_LOC.mis file, so that you can "see" where you are placing your base. You then open the "Land" tab on the "Tools Pannel" (yes, they made a typo in the ME). Find the Japanese Roster, then click and drag the "-NB Naval Base" item with your mouse, and then drage and drop it where you want to place it. You probably want to change the "name" of the new naval base, but genereally, it is not necessary, since the ME will track how many items of that Class you have on the map already, usually rather well. The modder has to be careful with later text edits, of course. Anyway, when finished, you should have similar to this:



Most of the default settings for NavalBase items are good as they are, and some if edited will cause trouble. You can change the Crew Rating, as well as the Game Entry Date and Time, as well as the Game Exit Date and Time, of course, but do not alter the Cfg Date. The "Height" figure is auto-generated by the ME for the terrain on which the NavalBase is placed. The Heading is basically useless for the item.
__________________

"...and bollocks to the naysayer/s" - Jimbuna
propbeanie is offline   Reply With Quote
Old 12-04-23, 02:07 AM   #1029
LuckyCapitan
Watch
 
Join Date: Jun 2022
Posts: 30
Downloads: 172
Uploads: 0
Default

Quote:
Originally Posted by propbeanie View Post
Kure, like Rabaul, already has a "physical" representation of docks, as found in the Campaign_LOC.mis file:




To make that a Japanese Naval Base, you first open the Axis_NavalBase.mis file first, and then "Merge without Save" with the Campaign_LOC.mis file, so that you can "see" where you are placing your base. You then open the "Land" tab on the "Tools Pannel" (yes, they made a typo in the ME). Find the Japanese Roster, then click and drag the "-NB Naval Base" item with your mouse, and then drage and drop it where you want to place it. You probably want to change the "name" of the new naval base, but genereally, it is not necessary, since the ME will track how many items of that Class you have on the map already, usually rather well. The modder has to be careful with later text edits, of course. Anyway, when finished, you should have similar to this:



Most of the default settings for NavalBase items are good as they are, and some if edited will cause trouble. You can change the Crew Rating, as well as the Game Entry Date and Time, as well as the Game Exit Date and Time, of course, but do not alter the Cfg Date. The "Height" figure is auto-generated by the ME for the terrain on which the NavalBase is placed. The Heading is basically useless for the item.
What do I need to create a base in Kura? I created a "Naval Base". Now do I need to write this down in the UPC?
And another question. The Japanese campaign uses German bases. Shouldn't these be German bases?
LuckyCapitan is offline   Reply With Quote
Old 12-04-23, 10:59 AM   #1030
propbeanie
CTD - it's not just a job
 
propbeanie's Avatar
 
Join Date: May 2016
Location: One hour from Music City USA!
Posts: 9,749
Downloads: 439
Uploads: 2


Default

It wouldn't matter which nation you use, so long as it is an Axis power, such as Germany or Japan. Since you are on a Japanese home island, I would use Japanese. Some of the Java and Malaysia bases were in fact Japanese bases that they loaned space to the Germans for shops and docking. Also, you are using Japanese subs in that mod. I do know that keltos01 made the boats "German", so if using Japanese fails, swap it to "German" in a text editor on the "Origin-" line, from Japan to German... :wink:

You do need to incrementally add a flotilla to the "Data \UPCDataGE \UPCCampaignData \Flotillas.upc" file. In the stock game, the last Flotilla is 4. You would then add a new Flotilla 5 after the end of the Flotilla 4 Objectives listings. The "easy" thing to do is to copy all of the Flotilla 4 data, and paste it into a new text file. I use Notepad++ for work like this, since it is much more powerful than the Windows Notepad app. If you want to spend the money, the 010 Editor is even better, but not necessary for this task. If you first paste the data into a "New" file in Notepad++, you can use the "Replace" function under the "Search" menu, and replace all of the "Flotilla 4" entries with "Flotiilla 5" (or whatever number is the next in sequence for your file). Then copy that edited data over into the existing Flotillas file. You would also have to change the "ID=" to "Kure" (or whatever base you are creating), "NameDisplayable-" to "IJN Kure" or whatever you want, and the "AvailabilityInterval=" to fit, such as "1938-01-01, NULL", or similar.

Your new "Flotilla 5.Base 1" would then change "ID=F5Kure" (or whatever you want to name it, but the "F5" portion must match what the "Flotilla X" number above is. Again, the "NameDisplayable=" should be unique, such as "Kure NB", but only to help you discern the differences in the on-screen displays when you play the game, as to which displays in the various aspects of the game. I never remember which name shows where... sorry. The "Info=" line can be set to "NULL", or you can make an entry in the "UPCLocalization.tsr" file in the "UPCLocalization" folder, and then link to that name. Use the Flotilla 4 entries as an example. The "ExternalBaseName=" line must match the spelling in the NavalBases.mis file exactly. Notice that the Flotilla 4 entry has a leading space for " Surabaya"? Look in the NavalBase file, and there is a leading space in the name there also. It must be ~exactly~ the same between the two. This will cause a CTD if not correct. The "AvailabilityInterval=" does not have to match the Flotilla's dates, since you can have more than one base associated with a given Flotilla. In this case though, you could set the Kure base's dates to "NULL, NULL", which then assumes the Flotilla's dates. The slightly complicated part comes with the "DepartureDescription1=" and "DepartureDescriptionOut1=" numbers. What they signify is the Longitude and Latitude coordinates in the decimal system. So an overview of the Kure area with the Jap_HarborTraffic.mis file merged into the Campaign_LOC.mis file, "Without Save" looks like this:



... when zoomed to a mid-level. Note that I placed a stock Sen Taka to assist in finding a relatively accurate set of figures. To get those numbers though, you zoom in as close as you can, place your temporary submarine, and hold the mouse cursor over the middle of the boat's icon, as such:



Those numbers in the bottom-left could be used for your "DepartureDescription1=" figures. Use the Flotilla 4 figures only as an example of the formatting. Using the screen grab in this case, you would use "15906197.000000, 4109181.000000, 180.000000". However, doing the screen grab did destroy the good figures on my display, so get your own, more accurate numbers. That third number, the 180.000000 is the heading for your submarine. If you are placing the departure by a dock, you do need extremely accurate numbers for the coordinates and heading. The DepartureDescriptionOut1= does not need quite as much accuracy, unless again, you are placing it near something else, such as a ship. In this case:



I have placed the submarine outside of Kure in the Inland Sea, on a 215.000000 degree heading, so I would use "15903068.000000, 4058922.000000, 215.000000". Again though, doing the screen grab did ruin the "detail" of the placement, so get your own accurate numbers. Notice that there is a "1" in use with those two DepartureDescription lines. You can have several of each of those. My memory tells me you can have a total of six of them, with 3 each - but I might be incorrect there... Experiment might be required... Just change the number though, and the location coordinates, and the game will choose them at random.

The next section for the UnitTypes would follow the same structure, just changing the lines to match your particular submarines. The Flotilla number of course, must match in all of these new entries, and the "ID=" line here would start with the "F5" for this example, and then the boat name. NameDisplayable would be what you want, such as "JyunsenB Type". The AvailabilityInterval= again would be the actual dates this particular submarine is available at the new base. The I-15 was completed on 30th September, 1940, and could then be "1940-09-30, NULL". The IDLinkUserPlayerUnitType= points to the actual "Data \Submarine \NSS_SubName \NSS_SubName.upcge file's "ID=" line. They must match ~exactly~... The UnitTypeCommonality= line is one of those Silent Hunter mystery entries. Generally speaking an entry of "1" will almost always work, but do not exceed the total number of submarines in the Class. I used to think it would help in the actual boat selection in the Roster file, but it does not actually seem to do that. The IDFlotillaLinkTransferTo= is the ID of the Flotilla you want your boat to transfer to, if desired. You could also leave it NULL. If you do want to have a TransferTo, there has to be a same-named boat at that Flotilla, such a Flotilla 4, you would need an F4JyunsenB entry at that Flotilla. I generally leave this set to "NULL" for ease of implementation initially. Get it working first, then try to blow it up...

Add how ever many boats you want to use at the new base, just be sure they are number sequentially. Then you have to have missions for them all, which is where "Flotilla X.UserPlayerUnitType X.Objective X" entries come into play. You need at least one entry for each boat, and the "Flotilla X" must match your Flotilla number (such as "5" in this example), the "UserPlayerUnitType X" must match the number of the boat, such as 1, 2, 3, etc., and the "Objective X" would start at "1" and end at however many assignments you have. Note that each assignment "calls" (usually) as set of files via the PatrolObjectives.cfg file in the same folder as the Flotillas.upc file. They work together with the "ObjectiveCode=" line in Flotillas.upc matching a corresponding "AllMatch=" entry in the PatrolObjectives.cfg file. There might be one, there might be 10 or more actual mis files that the "AllMatch" can call from PatrolObjectives. It is generally easier to call existing files. First though, the "ID=" line for each of the Flotillas.upc Objective assignments must be unique. If they are not, then when you get a duplicate call, the game will crash without an error message. This can happen upon your boat returning to base after a mission, or when first starting a patrol and getting the assignment. Notice that the stock game is using "MB41OBj1" as the ID for the first Objective in Flotilla 4? I do not know the significance of the "MB" in that, but the "4" is the Flotilla number, the "1" is the boat number, and then "Obj1" is the Objective number. You could use any convention you want, so long as it is unique, and relatively "small", such as the stock game's example. You could use "KNB51Obj1", for "Kure Naval Base, Flotilla 5, Boat 1, Objective 1. Increment Boat 1 to "2" for next boat, and increment "Objective 1" for each unique assignment. The same holds true for the "header" of each Objective. The NameDisplayable= line was something that apparently was never implemented in the game, and can be set to NULL, or any simple phrase to help you remember the assignment. The AvailabilityInterval, like all other dating conventions thus far, is just the time period you want the assignment available for the particular boat. The Objective assignments can overlap dates, if you desire, and the game will 'randomly' choose between them. However, consult the PatrolObjectives.cfg and find the AllMatch entries for the call, and make certain you do not exceed those dates, which should not exceed the dates in the actual mis files either. Surely those are all correct in the stock game, right?... lol

That finishes that, except anything I neglected to mention... If you want the boat and base to show on the CareerStart menu, then you need to add it to the CareeStart.upc file. Use the existing entries again, as a "model" for a new entry. Notice the dates for each of the "[CareerStart X]" entries, making a note of the "X" number. It is easiest to add your new entry to the end of each start you want, such as "[CareerStart 1.Flotilla 5]" (this "Flotilla" numbering just follows the CareerStart entry, NOT the actual Flotilla number). So you would have
[CareerStart 1.Flotilla 5]
ID= C1Flotilla5
NameDisplayable= Kure
IDLinkFlotilla= Kure
IDLinkUserPlayerUnits= F5JyunsenB Type, 1
FlotillaBriefingText=
FlotillaCommonality= 1
Notice the correlation to previous entries in the Flotillas file. The "F5" of the IDLinkUserPlayerUnits= liine must match the actual Flotilla number from Flotillas.upc, and the name must be exactly the same. The Briefing text is not used, and FlotillaCommonality at "1" almost always works correctly. This is another of those "unknown" variables that has had several explanations over the years...

Good luck! Copy all of that, print it out, read it at your leisure, and take your time doing the build! I have most of this info in a file that someday I'll "publish" as a pdf and/or addendum to the ME documentation Flotille 17 did years ago. I probably forgot something important, but generally speaking, just be certain you match entries exactly as they are in the associated files. That is where most trouble comes from.

btw - all typos are not my fault. It is ALL Martin's fault! (inside joke there - lol)
__________________

"...and bollocks to the naysayer/s" - Jimbuna

Last edited by propbeanie; 12-04-23 at 11:07 AM.
propbeanie is offline   Reply With Quote
Old 12-04-23, 11:57 AM   #1031
LuckyCapitan
Watch
 
Join Date: Jun 2022
Posts: 30
Downloads: 172
Uploads: 0
Default

Oh thank you. I noticed an error and corrected it. Everything works, the boat appears in Rabaul. Oh yeah! You can now work on having the player's boat based in Kure or Sasebo in 1944
LuckyCapitan is offline   Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -5. The time now is 02:56 AM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright © 1995- 2024 Subsim®
"Subsim" is a registered trademark, all rights reserved.