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

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Old 01-07-21, 04:50 PM   #3
LGN1
Ace of the Deep
 
Join Date: Mar 2006
Posts: 1,135
Downloads: 147
Uploads: 12
Default

Hi John,


SH3 Commander chooses with equal probability one number between 0 and the number of choose from. If the number is higher than the numbers you have given values to, then nothing is changed. With this you can adjust the probabilities for the different events.


Here's an example: You have a variable xABCD that has a value of 1 in the game. Now you would like to have that the variable stays equal 1 with a 50% chance, but with 25% probability changes to 2 and with 25% probability to 3.



In this case you set 'ChooseFrom=4' (because then every event has a 25% probability) and


0_xABCD=2
1_xABCD=3


Given this SH3 Commander changes the value to 2 if 0 is chosen, to 3 if 1 is chosen and does nothing if 2 and 3 are chosen.


You could achieve the same with:


0_xABCD=2
1_xABCD=3
2_xABCD=1
3_xABCD=1


I hope this is clear. If not please ask.


Best, LGN1
LGN1 is offline   Reply With Quote
 


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 04:08 AM.


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