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 09-03-12, 09:59 AM   #1201
TheDarkWraith
Black Magic
 
Join Date: Jun 2007
Posts: 11,962
Downloads: 147
Uploads: 5


Default

Quote:
Originally Posted by Kalleblom View Post
Sorry,

I'm at my wits end.

Have sometimes similar problems, but didnīt recognize how to fit this exactly.

Last i try the tutorial and it works.
The biggest problem people have is not removing all previous patches with the old patcher first before trying to enable new patches. The easiest way to overcome this 'problem' is to make a new folder in your \MODS folder: \Patched Files. Copy sh5.exe, SHCollisions.act, and SHSim.act into the \MODS\Patched Files folder. Enable the mod with JSGME. Run the patcher app and point it to the \Silent Hunter 5 folder so it will patch those files. When new patcher version comes out deinstall Patched Files mod and then reinstall Patched Files mod. Repatch (now there's no need to disable all patches beforehand!)

As the patcher evolves and patches more files simply copy the needed files into your \Patched Files folder.


Just turned the hard coded data entries into menu.txt entries AND wrote a nice little function that will accept two arguments: start of entry in menu.txt file and number of entries (this will be used for random entries). This nifty little function takes start of entry in menu.txt file + (random number * number of entries) and returns the resultant string. Thus getting a random menu.txt file entry!
TheDarkWraith is offline   Reply With Quote
Old 09-03-12, 10:15 AM   #1202
Kalleblom
Lieutenant
 
Join Date: May 2012
Location: Waterkant
Posts: 252
Downloads: 74
Uploads: 0
Default

Thank you sir!

i copy my related files before patching (but after the 1.2.0 patch) in my personal "sh5 origininal file" folder.

And when a new patch comes out i use this files. So i have everytime a original version of the files.

The thing with the menu.txt, will there are problems using a "deutschmod" in the end of the mod list, which include a translation of all menu.txt lines.
Kalleblom is offline   Reply With Quote
Old 09-03-12, 10:30 AM   #1203
gap
Navy Seal
 
Join Date: Jan 2011
Location: CJ8937
Posts: 8,214
Downloads: 793
Uploads: 10
Default

Quote:
Originally Posted by TheDarkWraith View Post
The biggest problem people have is not removing all previous patches with the old patcher first before trying to enable new patches. The easiest way to overcome this 'problem' is to make a new folder in your \MODS folder: \Patched Files. Copy sh5.exe, SHCollisions.act, and SHSim.act into the \MODS\Patched Files folder. Enable the mod with JSGME. Run the patcher app and point it to the \Silent Hunter 5 folder so it will patch those files. When new patcher version comes out deinstall Patched Files mod and then reinstall Patched Files mod. Repatch (now there's no need to disable all patches beforehand!)

As the patcher evolves and patches more files simply copy the needed files into your \Patched Files folder.
A similar method has been explained several times on this forum, and Trevally started a whole thread about it, complete with pictures and step by step procedures that even complete computer illiterate could follow.

I wonder what makes installing your patches or using JSGME still so difficult for many people.

Anyway, I think you see now one of the reasons for me asking, a while back, whether you could have done your patcher to patch the game on the fly, instead of modifying the stored exe and act files.


Quote:
Originally Posted by TheDarkWraith View Post
Just turned the hard coded data entries into menu.txt entries AND wrote a nice little function that will accept two arguments: start of entry in menu.txt file and number of entries (this will be used for random entries). This nifty little function takes start of entry in menu.txt file + (random number * number of entries) and returns the resultant string. Thus getting a random menu.txt file entry!
gap is offline   Reply With Quote
Old 09-03-12, 10:43 AM   #1204
Kalleblom
Lieutenant
 
Join Date: May 2012
Location: Waterkant
Posts: 252
Downloads: 74
Uploads: 0
Default

gap

what does it mean with the menu.txt file. Canīt figure out and how itīs touch the german translation of the menu.txt. My english isnīt goog enough to understand it.
Kalleblom is offline   Reply With Quote
Old 09-03-12, 10:53 AM   #1205
TheDarkWraith
Black Magic
 
Join Date: Jun 2007
Posts: 11,962
Downloads: 147
Uploads: 5


Default

Quote:
Originally Posted by Kalleblom View Post
The thing with the menu.txt, will there are problems using a "deutschmod" in the end of the mod list, which include a translation of all menu.txt lines.
Should be no problems. I'm going to modify the patcher app so that it'll recognize entries that say to patch a txt file instead of a binary file. This will allow it to add/remove items from txt files


I added two new variables to the Contact report wolfpacks patch: start of random Bdu responses in menu.txt file (currently set at 10050) and number of random responses (currently set to 5). This means people can add/remove random responses as they wish (all are defined in the menu.txt file starting at 10050)
TheDarkWraith is offline   Reply With Quote
Old 09-03-12, 11:18 AM   #1206
Kalleblom
Lieutenant
 
Join Date: May 2012
Location: Waterkant
Posts: 252
Downloads: 74
Uploads: 0
Default

TDW and great thx,

now iīve understand.
Kalleblom is offline   Reply With Quote
Old 09-03-12, 11:30 AM   #1207
gap
Navy Seal
 
Join Date: Jan 2011
Location: CJ8937
Posts: 8,214
Downloads: 793
Uploads: 10
Default

Quote:
Originally Posted by TheDarkWraith View Post
Should be no problems. I'm going to modify the patcher app so that it'll recognize entries that say to patch a txt file instead of a binary file. This will allow it to add/remove items from txt files
Good idea, though I see a shortcoming to it: if people enable mods that modify menu.txt after having enabled your patch, or if they patch the game after having enabled a modded menu.txt, and then they remove that mod, the patched menu.txt would be overwritten or completely discarded.

I am sure UI mods and language packs will feature soon your new messages. In the meanwhile an esay trick for avoiding confusion, if only people could get accustomed to it, would be following the Tutorial by Trevally, by including the modded/localized menu.txt in the "patch mod" and by making sure to enable it at the end of the JSGME list.

Another solution that occurs to me though is to make your patch to look for a custom txt file, that should be enabled like a normal mod after installing the patch.



Quote:
Originally Posted by Kalleblom View Post
gap

what does it mean with the menu.txt file. Canīt figure out and how itīs touch the german translation of the menu.txt. My english isnīt goog enough to understand it.
Sorry Kalle: I see TDW was faster than me
gap is offline   Reply With Quote
Old 09-03-12, 11:39 AM   #1208
TheDarkWraith
Black Magic
 
Join Date: Jun 2007
Posts: 11,962
Downloads: 147
Uploads: 5


Default

Yes could be a minor problem if a mod is enabled that overwrites the patched menu.txt file. Just something user will have to be aware of.

I have the start of the random Bdu responses in the menu.txt file set at 10050...only my UIs mod even comes close to this number.

I built safeguards into the patch that will check to see what the max # of entries defined in the menu.txt is and if that number is less than the entries the patch is calling for then no message is displayed to user (it's actually built into the random menu.txt entries function I made)
TheDarkWraith is offline   Reply With Quote
Old 09-03-12, 12:01 PM   #1209
gap
Navy Seal
 
Join Date: Jan 2011
Location: CJ8937
Posts: 8,214
Downloads: 793
Uploads: 10
Default

Quote:
Originally Posted by TheDarkWraith View Post
I built safeguards into the patch that will check to see what the max # of entries defined in the menu.txt is and if that number is less than the entries the patch is calling for then no message is displayed to user (it's actually built into the random menu.txt entries function I made)
I see,
anyway, why not displaying a standard message stored into your code, instead of not displaying a message at all?
gap is offline   Reply With Quote
Old 09-03-12, 12:15 PM   #1210
TheDarkWraith
Black Magic
 
Join Date: Jun 2007
Posts: 11,962
Downloads: 147
Uploads: 5


Default

Quote:
Originally Posted by gap View Post
I see,
anyway, why not displaying a standard message stored into your code, instead of not displaying a message at all?
You make a good point What should the standard message be then?
TheDarkWraith is offline   Reply With Quote
Old 09-03-12, 01:09 PM   #1211
TheDarkWraith
Black Magic
 
Join Date: Jun 2007
Posts: 11,962
Downloads: 147
Uploads: 5


Default

Added a standard message in case the menu.txt file isn't patched or gets overwritten:

Shadow contact/convoy and remain undetected

So if you see this and it's in English you know your menu.txt isn't updated with the new entries for the Contact report wolfpack patch.

Also changed where the random Bdu messages for this patch are going to start in the menu.txt file to 11000. This will ensure noone will ever get close to these

I'll have revised version of patcher available here soon (though it will not be able to patch the menu.txt file yet - you'll have to manually add the required entries for now)
TheDarkWraith is offline   Reply With Quote
Old 09-03-12, 01:09 PM   #1212
SilentOtto
Engineer
 
Join Date: Mar 2002
Location: BF79
Posts: 209
Downloads: 71
Uploads: 0
Default

TDW, sorry to bug you with this again, but somewhere between version 1.60 and 1.69 it seems you've gone back to compile against .NET 3.5, as you know, some of us (well I think it might well be just me! ><) can't run it under linux... so please, when you have the time, would you be so kind...?

I didn't bug you before since I was quite happy with my patching, but I really want to try the wolfpack function!
SilentOtto is offline   Reply With Quote
Old 09-03-12, 01:10 PM   #1213
TheDarkWraith
Black Magic
 
Join Date: Jun 2007
Posts: 11,962
Downloads: 147
Uploads: 5


Default

Quote:
Originally Posted by SilentOtto View Post
TDW, sorry to bug you with this again, but somewhere between version 1.60 and 1.69 it seems you've gone back to compile against .NET 3.5, as you know, some of us (well I think it might well be just me! ><) can't run it under linux... so please, when you have the time, would you be so kind...?

I didn't bug you before since I was quite happy with my patching, but I really want to try the wolfpack function!
Thanks for bringing that to my attention. I wasn't aware that I switched back to using .NET 3.5
TheDarkWraith is offline   Reply With Quote
Old 09-03-12, 01:11 PM   #1214
gap
Navy Seal
 
Join Date: Jan 2011
Location: CJ8937
Posts: 8,214
Downloads: 793
Uploads: 10
Default

Quote:
Originally Posted by TheDarkWraith View Post
You make a good point What should the standard message be then?
You could pick any of the messages that you have planned to add to menu.txt. Indeed, it would be only in english, and it wouldn't been shuffled with other similar messages.

Ops... I didn't see your most recent post. I've just noticed that you did it yet
gap is offline   Reply With Quote
Old 09-03-12, 01:26 PM   #1215
TheDarkWraith
Black Magic
 
Join Date: Jun 2007
Posts: 11,962
Downloads: 147
Uploads: 5


Default

Quote:
Originally Posted by SilentOtto View Post
TDW, sorry to bug you with this again, but somewhere between version 1.60 and 1.69 it seems you've gone back to compile against .NET 3.5, as you know, some of us (well I think it might well be just me! ><) can't run it under linux... so please, when you have the time, would you be so kind...?

I didn't bug you before since I was quite happy with my patching, but I really want to try the wolfpack function!
Just checked and I've been compiling against .NET 2.0 for many versions now. What problems are you having?
TheDarkWraith 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 12:27 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.