![]() |
SUBSIM: The Web's #1 resource for all submarine & naval simulations since 1997 |
![]() |
#1 |
Sonar Guy
![]() Join Date: Apr 2005
Location: Middlebury, VT, USA
Posts: 378
Downloads: 165
Uploads: 2
|
![]()
Hi everyone,
I have been thinking about how the malfunctions + sabotage (M+S) feature for SH3 Commander is implemented. When I leave port, I save and exit the game right after the first weather change. The reason is that I run two mods that need to run externally to the game and they both import information into SH3, namely my own "JFO!" Mod and SH3 Gen. So that got me thinking a little bit. ![]() I was looking through the Randomised events.cfg [sic] file for SH3 Commander and I was looking at how it is structured. I noticed for some of the M+S features, that they are randomized in mid-patrol, and some are not. I did some searching in the forum, and it appears that it was decided that some of the things that could go wrong would be severe enough to cause a return to port, and some things could just be dealt with, i.e. they are things that would happen as typical issues on patrol, and could be fixed. They would typically be fixed using resources on the boat and time, and this would theoretically be simulated by saving and reloading the game. Hopefully, the randomization would "make the problem go away." However, it could be randomized such that it would be worse. On the whole, I like the simulation and it has some good ideas. ![]() But I'm wondering if the format can be used to add something else to the game. ![]() What I am thinking about, if possible, is setting up the .cfg file to act in conjunction with an idea. That idea would be that the Kaleun would perform a shakedown at the beginning of the patrol to determine whether or not the boat was seaworthy and make a decision about returning to port. The shakedown procedure could be written out for players to follow. It could also include some indicator that lets them know if the level of problem they are experiencing is bad or not. At this point they would have to make a command decision. Do I go back to port or do I continue on with what I have? What it if gets worse? Will it get better? I'm still fleshing this out as an idea. However, I'm thinking about one aspect of how it works, and I'm curious if anyone has an answer for me. Say I have an entry that sets the time for reload on the flak guns. For this entry if I set RndMidPat=1 it means that it will randomize the condition in the middle of the patrol. What exactly does RndMidPat=0 mean? Does it mean that if the condition occurs, it stays with you throughout the patrol, or only until the first in-patrol reload? Let's assume it does apply throughout the patrol. If I have two entries in the file for the flak guns, one with RndMidPat=0 and RndMidPat=1, which one takes precedence? Can this even be done? If I have the answers to these, I might be able to flesh this out. I may have to run these experiments myself, but if anyone has answers, that would help a lot. Thanx in advance. ![]() |
![]() |
![]() |
![]() |
#2 | ||
Soundman
![]() Join Date: Nov 2012
Posts: 142
Downloads: 205
Uploads: 0
|
![]()
Hallo rudewarrior
Quote:
Damage only at the beginning of the Patrol. After you save and load game, these are repaired. I've also missing a damage report, or query from LI. Quote:
But they can RndMidPat=1 and ChooseFrom=2 ChooseFrom=2 RndMidPat=1 0_xxxxx=value; with failure. This is a chance of 50% damage or repair. You can ChooseFrom higher value and more entries on your taste. greeting La vache Last edited by La vache; 02-25-13 at 10:35 AM. |
||
![]() |
![]() |
![]() |
#3 |
Ace of the Deep
![]() Join Date: Mar 2006
Posts: 1,138
Downloads: 147
Uploads: 12
|
![]()
Hi rudewarrior,
here is an important post from JScones about how SH3 Commander works: When you press "Launch SH3!", SH3Cmdr performs the following steps in this order (for the sake of brevity, let's just assume that an existing career is being launched): 1. Removes previously installed files 2. Reads SH3Cmdr settings/options 3. Determines whether career will be retired (if option selected) 4. Determines next patrol start date 5. Copies into SH3 any Flotilla folder files 6. Copies into SH3 any U-boat folder files 7. Copies into SH3 any Date folder files 8. Copies into SH3 any Random folder files 9. Determines whether crewman will be retired (if option selected) 10. Writes Text Settings to **_menu.txt 11. Writes Menu variable text to **_menu.txt 12. Writes Days in Base value to Basic.cfg 13. Writes Crew fatigue model to Basic.cfg (if option selected) 14. Writes correct U-boat availability dates to Basic.cfg (if option selected) 15. Writes deck gun settings to GUNS_SUB.sim (if option selected) 16. Writes water density setting to scene.dat (if option selected) 17. Writes wave height setting to scene.dat (if option selected) 18. Writes random tonnage variations 19. Writes random crush depth 20. Writes random events 21. Writes static settings 22. Randomises Gramaphone tracks (if option selected) 23. Launches SH3!!!! This allows you to understand which settings can over-write other settings (e.g., entries in 'static settings.cfg' overwrite entries in 'randomised events.cfg')! During a patrol the 'RndMidPat=0' entry will be just ignored. Only the 'RndMidPat=1' for the flak gun will be considered. In general, you can have several entries for the same file / same parameter in randomised_events. However, these are applied successively, i.e., the last entry can over-write the previous ones. Regards, LGN1 |
![]() |
![]() |
![]() |
#4 | |
Sonar Guy
![]() Join Date: Apr 2005
Location: Middlebury, VT, USA
Posts: 378
Downloads: 165
Uploads: 2
|
![]()
Hi guys,
I'm starting to think my idea as conceived isn't going to work from some of the further research I've been doing on the boards. One of the posts I came across said: Quote:
![]() But another issue is the rollback option. It seems that if you automatically rollback upon exit, then there is actually no difference between the 0 and 1 condition. ![]() I can't find anything that indicates that SH3 Commander somehow retains info about your particular patrol other than a single line entry in SH3Cmdr.ini located in the main folder. It lists a series of dates and numbers. Although I can't say what they specifically are, they don't seem to correspond to the Randomised event.cfg file in any way. Unless, I can get this completely sorted out, I'm not really seeing much of a future for this, if any. I guess these are the questions that I need to have answered with absolute certainty.
It may just be a dead idea. ![]() |
|
![]() |
![]() |
![]() |
#5 |
XO
![]() Join Date: Jun 2008
Posts: 427
Downloads: 59
Uploads: 0
|
![]()
I worked on an external program that was called up by SH3 Commander.
There was a weather mod, think it was something to do with persistent bad weather when leaving port. Well that mod was called up by SH3 Commander, when the weather mod closed it passed back to Sh3 commander which launched the SH3. I don't know if the latest SH3 Commander still has that command in, but I'd bet it is. You can make an external program to collect data from the saved files and do anything you want with it, then update SH3 similar to how Commander does it. The possibilities of what a program like this can do is enormous using the collected saved game data. I know this works, as I tested it out. I even edited the weather name in SH3 Commander to my own program name and it worked, but leaving it as named is a lot easier for everybody. |
![]() |
![]() |
![]() |
#6 | |
Sea Lord
![]() Join Date: Nov 2007
Location: In sight of Stonehenge
Posts: 1,750
Downloads: 51
Uploads: 26
|
![]() Quote:
2. This particular entry in sabotage may be applied mid-patrol. 3. I believe this is to do with when you load the game. SH3 Commander is an external engine therefore should not be able to affect the game whilst you are playing it (SH3 loads all game data on first load, therefore it can't have an effect on the game files mid-play). If you are loading a new game in port then it will roll a dice for each RndMidPat=0 entry plus every RndMidPat=1 entry. If you're loading a mid-patrol save then it will only roll a dice for each RndMidPat=1 entry. 4. If you don't rollback SH3 Commander then the malfunction or sabotage remains in place... forever. This is because it has rewritten the game files and rollback prevents it from deleting the changes. 5. No - rollback deletes all previous changes to the files so I don't see how it can remember old problems. This is part of the 'save game and reload and your crew may have solved the problem' answer. Can anyone check me on these?
__________________
![]() All my mods are available at MediaFire: SH3 Mods Other modders SH3 mods SH4 Mods ...you can't please all of the people all of the time... |
|
![]() |
![]() |
![]() |
#7 | ||
Sonar Guy
![]() Join Date: Apr 2005
Location: Middlebury, VT, USA
Posts: 378
Downloads: 165
Uploads: 2
|
![]()
Just to check for understanding.
Quote:
![]() Quote:
![]() In light of your answer to #5, can anyone confirm this? From everything I can tell, it seems that how the rollback works would imply what you say. I'd also like to know if it applies between careers. For example, I'm in career #1 with a permanent condition. I save/exit and start playing career #2. If I go back to career #1, will the permanent condition still be in place? Generally, incorporating a mod that would explicitly require that you do not roll back SH3 Commander is a worrisome mod indeed. ![]() |
||
![]() |
![]() |
![]() |
#8 | ||
Sea Lord
![]() Join Date: Nov 2007
Location: In sight of Stonehenge
Posts: 1,750
Downloads: 51
Uploads: 26
|
![]() Quote:
Quote:
![]()
__________________
![]() All my mods are available at MediaFire: SH3 Mods Other modders SH3 mods SH4 Mods ...you can't please all of the people all of the time... |
||
![]() |
![]() |
![]() |
#9 |
Ace of the Deep
![]() Join Date: Mar 2006
Posts: 1,138
Downloads: 147
Uploads: 12
|
![]()
Hi all,
when I experimented with the randomized events file I was also confused by the old post from HEMISENT. I came to the conclusion that this post is simply wrong. From all my testings I concluded that SH3 Commander has no memory. As soon as you rollback or reload via SH3 Commander all previous settings are lost. If you choose not to rollback during a career you also must not launch the game via SH3 Commander anymore. This, however, makes the RndMidPat parameter somehow useless. In addition, you have to take care of this when calculating failure rates (because you basically throw the dice only once per patrol). You can easily check all these things by having an event with 'choosefrom=1' and a single case (i.e., 100% probability) with RndMidPat=0. You should always get the event when leaving port, but after reloading it should be gone and never come back during a patrol. Do the same with RndMidPat=1 and you should always have it. All these findings are in line with JScones post from above, especially, '1. Removes previously installed files'. Regards, LGN1 PS: Here is a link to an old discussion of this topic: http://www.subsim.com/radioroom/show...ge=28&langid=1 |
![]() |
![]() |
![]() |
#10 | |
Sea Lord
![]() Join Date: Nov 2007
Location: In sight of Stonehenge
Posts: 1,750
Downloads: 51
Uploads: 26
|
![]() Quote:
![]()
__________________
![]() All my mods are available at MediaFire: SH3 Mods Other modders SH3 mods SH4 Mods ...you can't please all of the people all of the time... |
|
![]() |
![]() |
![]() |
#11 |
Ace of the Deep
![]() Join Date: Mar 2006
Posts: 1,138
Downloads: 147
Uploads: 12
|
![]()
So my answers are:
I guess these are the questions that I need to have answered with absolute certainty.
|
![]() |
![]() |
![]() |
#12 |
Sonar Guy
![]() Join Date: Apr 2005
Location: Middlebury, VT, USA
Posts: 378
Downloads: 165
Uploads: 2
|
![]()
So yeah, certain statements in HEMISENT's post are incorrect and confusing.
![]() And it appears that SH3 Commander's RndMidPat feature really doesn't actually accomplish what it originally intended. ![]() It appears that it's original purpose was that an item with RndMidPat=0 would be a die roll at the beginning of the patrol. I assume at this point it was originally intended that whatever the outcome, it was supposed to stick with you throughout the patrol. Then an item with RndMidPat=1 would be something that would be temporary and (possibly) fixable by the crew. However, the way it seems to work, it is all dependent on rollback. If you don't roll back, you can get 0 and 1 conditions, which essentially treats a 1 condition as a 0 condition. If you do rollback, when you launch again on the same mission, you can only get 1 conditions, which also means a 0 condition is ruled out/removed altogether. This makes me think my mod idea won't work, and what I may do is turn all of my 0 conditions into 1 conditions. Normally, what I do is I only allow myself to save the game immediately after the weather changes, and I just deal with the problems that I have. This way, when I am engaging, it is as if I "just discovered the problem," and I just have to deal with it. Since we can't really really cause random malfunctions right in the middle of patrols, I try to find a way to make it such that I am forced into situations sometimes where the boat is not working at 100%, probably something that was a factor as the war progressed. Unless someone has some better suggestions? Ultimately, I think that's it for this idea. ![]() Thanx for the help guys! ![]() Last edited by rudewarrior; 02-27-13 at 09:28 AM. Reason: Forgot request for suggestions. |
![]() |
![]() |
![]() |
|
|