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 > SH5 Mods Workshop
Forget password? Reset here

Reply
 
Thread Tools Display Modes
Old 01-16-17, 06:21 PM   #376
THEBERBSTER
Growing Old Disgracefully
 
THEBERBSTER's Avatar
 
Join Date: Dec 2012
Location: Dibden Purlieu - Southampton
Posts: 9,605
Downloads: 1123
Uploads: 0


Default

Hi TJ
Tonnage=true means that your objective is get a certain amount of tonnage.
Tonnage=false means that your objective is to sink a number of ships.
Tonnage and Ships comes under the guise of CRTAmount and Amount.
Peter
THEBERBSTER is offline   Reply With Quote
Old 01-16-17, 08:36 PM   #377
Aktungbby
Gefallen Engel U-666
 
Aktungbby's Avatar
 
Join Date: Jul 2013
Location: On a tilted, overheated, overpopulated spinning mudball on Collision course with Andromeda Galaxy
Posts: 27,822
Downloads: 22
Uploads: 0


Default Welcome aboard!

dennisthefish!
__________________

"Only two things are infinite; The Universe and human squirrelyness; and I'm not too sure about the Universe"
Aktungbby is offline   Reply With Quote
Old 01-17-17, 06:59 AM   #378
OldCoder
Soundman
 
Join Date: Mar 2016
Posts: 142
Downloads: 24
Uploads: 0
Default

Quote:
Originally Posted by Toby-Jazz View Post
Hi Guys.
Since there was a LOT of pages on here to go through I thought I will give my input whether or not it was stated already - incase anyone is still playing SH5 that is -

I fixed a tonnage not showing manually by watching the progress of tonnage sunk through the captain's log and then changing the values in the campaign.cfg files in the Documents\SH5 folders\data\users\'campaign name'\'campaign start date'
and the campaign.cfg files in the Documents\SH5 folders\data\cfg\savedGames\000000001 (Or last saved game ID)\'campaign start date'\campaign.cfg

the lines edited are located under the mission name :
[Campaign.CampObj.MacroObj 4.PersObj 1.CrtAmount]
IsTonnage=false
Tonnage=0
NumOfShips=0

Tonnage would then be set to the appropriate number for each of the two campaign.csf files.
I have found instances where it is correctly saved under one or the other files, but not the other one and so it probably doesnt read it correctly
I do not know if 'IsTonnage=true' would fix it by default. Will try once I get a change to play again.

Hope this helps or gives some mdder an idea of how to fix this

Kind regards
Tobias 'tip the apple cart' Jazz
So is it just a case of monitoring changes in one file and syncing them to the other file? Or do I misunderstand?
OldCoder is offline   Reply With Quote
Old 01-17-17, 07:20 AM   #379
THEBERBSTER
Growing Old Disgracefully
 
THEBERBSTER's Avatar
 
Join Date: Dec 2012
Location: Dibden Purlieu - Southampton
Posts: 9,605
Downloads: 1123
Uploads: 0


Default

Hi OC
Making those changes does not guarantee anything.
Tonnage bar and campaign icons are broken and will work sometimes and not at other times.

Quote:
the lines edited are located under the mission name :
[Campaign.CampObj.MacroObj 4.PersObj 1.CrtAmount]
IsTonnage=false
Tonnage=0
NumOfShips=0
This means that there is no tonnage in this mission only ships.
Tonnage=0
For ships you would go to 'Amount' and it will show you the number of ships required to complete the mission.
Here you have a problem because not all ships sunk count towards the objective.
Peter
THEBERBSTER is offline   Reply With Quote
Old 01-17-17, 07:41 AM   #380
OldCoder
Soundman
 
Join Date: Mar 2016
Posts: 142
Downloads: 24
Uploads: 0
Default

Sorry yes, I did some more reading and latterly found http://www.subsim.com/radioroom/show...&postcount=233 .

I guess with the workaround/fix of changing the OSI task priority this is a system resources/timing issue between the sh5 and osi communication protocol.
OldCoder is offline   Reply With Quote
Old 01-17-17, 10:44 AM   #381
OldCoder
Soundman
 
Join Date: Mar 2016
Posts: 142
Downloads: 24
Uploads: 0
Default

Ok taking MaMa's fix one tiny step further (unless it's already been covered in the the forum) I've found a tool allowing us to set the priority of osi.exe just one time and thereafter forget about it.

Background:
http://www.subsim.com/radioroom/show...&postcount=233
http://www.subsim.com/radioroom/show...&postcount=188

The theory being (at least as I understand it) that SH5 is a highly demanding process (particularly with the megamods installed) and that the osi.exe which it communicates with does not respond correctly or somehow quickly enough. By running the osi.exe process at a higher priority, it responds to the incoming requests.

Ok so now for the automation tool. I'm not sure that I'm allowed to link to external file resources so I'll just say google SystemExplorer, install that (Win 7->10 compatible), choose custom install, choose the default Task Manager style view and say no to the security check as it's irrelevant to what we're doing.

It'll install itself, and by default runs at startup and minimises to the task tray which is fine. Run Silent Hunter V and as expected the osi.exe process spawns (and latterly dies when SH5 is closed). So when SH is running, open System Explorer from the task tray, type in osi in the top right filter. The osi.exe process should appear within the main pane, so right click on that and set Process Priority to Real Time and check the Permanent option.

That's all needed. Next time you boot up or run SHV, System Explorer will automatically set the osi to real time priority. Hopefully this works and simplifies the process if tonnage bar is wanted or required.
OldCoder is offline   Reply With Quote
Old 01-17-17, 11:13 AM   #382
vdr1981
Navy Seal
 
Join Date: May 2010
Location: Србија
Posts: 6,078
Downloads: 581
Uploads: 13


Default

To bad because the Windows it self doesn't have similar option...

An interesting and practical solution indeed, but again, this is close to a "rocket science" procedure for an average "I just wanna shoot ships and fill tonnage baaa" gamer...

Can you confirm that it actually works?

Last edited by vdr1981; 01-17-17 at 11:25 AM.
vdr1981 is offline   Reply With Quote
Old 01-17-17, 11:54 AM   #383
OldCoder
Soundman
 
Join Date: Mar 2016
Posts: 142
Downloads: 24
Uploads: 0
Default

Quote:
Can you actually confirm that it actually works?
It should work since it is effectively the same as MaMa method #1 here http://www.subsim.com/radioroom/show...&postcount=188

I see the expected output in DbgView and cross-referencing with Windows Task Manager confirms the adjusted priority.

I may have a simpler method, will let you know. Meanwhile it would be helpful if somebody with the issue could test the above.
OldCoder is offline   Reply With Quote
Old 01-17-17, 12:16 PM   #384
Toby-Jazz
Nub
 
Join Date: Sep 2016
Posts: 3
Downloads: 71
Uploads: 0
Default

Quote:
Originally Posted by THEBERBSTER View Post
Hi OC
Making those changes does not guarantee anything.
Tonnage bar and campaign icons are broken and will work sometimes and not at other times.

This means that there is no tonnage in this mission only ships.
Tonnage=0
For ships you would go to 'Amount' and it will show you the number of ships required to complete the mission.
Here you have a problem because not all ships sunk count towards the objective.
Peter
Oh for sure Peter, it's definitely not a solution I agree, Just something I noticed hoping it may point a modder to a resolution.

I have merely noticed that the crtamount portion of the .cfg file does change the tonnage in the game (Noticed to-day that one actually only need to change the value in the campaign.cfg found in the savedgame folder) and have actually completed some missions in the total Germany campain getting the iron crosses by changing the crtamount without leaving the harbour at all, but yes, it is not a solution and impractical
Toby-Jazz is offline   Reply With Quote
Old 01-17-17, 12:21 PM   #385
Aktungbby
Gefallen Engel U-666
 
Aktungbby's Avatar
 
Join Date: Jul 2013
Location: On a tilted, overheated, overpopulated spinning mudball on Collision course with Andromeda Galaxy
Posts: 27,822
Downloads: 22
Uploads: 0


Default Welcome aboard!

Toby-Jazz!
__________________

"Only two things are infinite; The Universe and human squirrelyness; and I'm not too sure about the Universe"
Aktungbby is offline   Reply With Quote
Old 01-17-17, 12:27 PM   #386
Toby-Jazz
Nub
 
Join Date: Sep 2016
Posts: 3
Downloads: 71
Uploads: 0
Default

Quote:
Originally Posted by OldCoder View Post
So is it just a case of monitoring changes in one file and syncing them to the other file? Or do I misunderstand?
yes, in a way.
From my observations (Which is NOT extensive) the tonnage sometimes shows in
Documents\SH5 folders\data\users\'campaign name'\'campaign start date'
but not in
Documents\SH5 folders\data\cfg\savedGames\000000001 (Or last saved game ID)\'campaign start date'\campaign.cfg
All I noticed that when it stays 0 in the savedGames folder it shows a blank non progressive bar in game. and changing it in SavedGames shows it in game as changed to whatever I changed it to
Toby-Jazz is offline   Reply With Quote
Old 01-18-17, 10:12 AM   #387
OldCoder
Soundman
 
Join Date: Mar 2016
Posts: 142
Downloads: 24
Uploads: 0
Default

Hi,

I've made an exe to try out, which spawns the ubisoft osi.exe at the realtime priority. If it works and the install steps could be automated by the patcher, it would simplify the fix process so no steps required by the user.

Manual steps that would need automating:
1. Rename the original osi.exe to osi_ubisoft.exe
2. Copy my replacement osi.exe into the same folder as osi_ubisoft.exe, along with a file called subsim.args

Then when SH5 starts, it runs my osi.exe instead of theirs.

My exe spawns the exe that we renamed and creates the task at the priority specified by a line in the subsim.args file (by default real time).

The comm pipe between SH5 and the listener still works (verified with DbgView).

One caveat is that I've compiled it and tested it on Windows 7 64 bit. It would need some testing on other platforms and also by users who aren't by default 'administrator'.

I don't know how to attach files to the forum, so guidance needed if this is something that people would like to try.
OldCoder is offline   Reply With Quote
Old 01-20-17, 11:00 AM   #388
OldCoder
Soundman
 
Join Date: Mar 2016
Posts: 142
Downloads: 24
Uploads: 0
Default

Anyone still have this tonnage bar issue want to try this? Somebody who can easily reproduce the problem I mean.
OldCoder is offline   Reply With Quote
Old 01-20-17, 11:54 AM   #389
vdr1981
Navy Seal
 
Join Date: May 2010
Location: Србија
Posts: 6,078
Downloads: 581
Uploads: 13


Default

Work with the Man people! His solution can also solve sporadically problematic campaign transfers which are caused by the same issue...

Hi is trying ti give you the simplest solution so far for the long standing issue , yet no one seems to care.

Last edited by vdr1981; 01-20-17 at 12:03 PM.
vdr1981 is offline   Reply With Quote
Old 01-21-17, 08:21 AM   #390
gap
Navy Seal
 
Join Date: Jan 2011
Location: CJ8937
Posts: 8,214
Downloads: 793
Uploads: 10
Default

Quote:
Originally Posted by OldCoder View Post
Hi,

I've made an exe to try out, which spawns the ubisoft osi.exe at the realtime priority. If it works and the install steps could be automated by the patcher, it would simplify the fix process so no steps required by the user.

Manual steps that would need automating:
1. Rename the original osi.exe to osi_ubisoft.exe
2. Copy my replacement osi.exe into the same folder as osi_ubisoft.exe, along with a file called subsim.args

Then when SH5 starts, it runs my osi.exe instead of theirs.

My exe spawns the exe that we renamed and creates the task at the priority specified by a line in the subsim.args file (by default real time).

The comm pipe between SH5 and the listener still works (verified with DbgView).
Brilliant

Quote:
Originally Posted by OldCoder View Post
One caveat is that I've compiled it and tested it on Windows 7 64 bit. It would need some testing on other platforms and also by users who aren't by default 'administrator'.
I run SH5 on Winodws 8 as administrator, but I don't have time to play the game. If there is a quick way to check that your method is working on my system (one which doesn't require starting a campaign), I will be glad to help

Quote:
Originally Posted by OldCoder View Post
I don't know how to attach files to the forum, so guidance needed if this is something that people would like to try.
You need uploading privileges for hosting mods on subsim. If you want, I can upload your tweak for you, or you can PM Neal Stevens asking your profile to be upgraded for mod uploading, but most users here use Mediafire for sharing their WIP stuff
__________________
_____________________
|May the Force be with you!|
...\/
gap 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 01:21 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.