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 12-01-10, 09:55 AM   #1
Trevally.
Navy Seal
 
Join Date: Apr 2007
Location: AN1536 (Orkney)
Posts: 5,448
Downloads: 166
Uploads: 28


Default

Quote:
Originally Posted by TheDarkWraith View Post
Do I need to add a command to be able to resize the tutorial box?
No its ok as is thanks

I came across this when describing the stations. I just kept the text to within what would be shown. The rest appears when clicking next.

I think this is better as it is not too much text to read in one go and a bigger box would need more moving about the screen.
__________________
Trevally Mods for SH5
Trevally. is offline   Reply With Quote
Old 12-01-10, 10:17 AM   #2
TheDarkWraith
Black Magic
 
Join Date: Jun 2007
Posts: 11,959
Downloads: 147
Uploads: 5


Default

Quote:
Originally Posted by Trevally. View Post
No its ok as is thanks

I came across this when describing the stations. I just kept the text to within what would be shown. The rest appears when clicking next.

I think this is better as it is not too much text to read in one go and a bigger box would need more moving about the screen.
exactly. That is why I sized it the way I did and didn't include a command to be able to resize it. It's not so big that you have to move it out of the way and it's not too small that you can't fit a decent amount of text in it

Were you able to understand my speed finder tutorial (script wise)? It makes use of pointers (and pointer arithmetic) and variables which would be hard for someone to understrand that isn't used to programming in C++

I forgot to include the single mission for that speed finder tutorial. I can send it to you if you'd like it.
TheDarkWraith is offline   Reply With Quote
Old 12-01-10, 10:54 AM   #3
Trevally.
Navy Seal
 
Join Date: Apr 2007
Location: AN1536 (Orkney)
Posts: 5,448
Downloads: 166
Uploads: 28


Default

Quote:
Were you able to understand my speed finder tutorial (script wise)? It makes use of pointers (and pointer arithmetic) and variables which would be hard for someone to understrand that isn't used to programming in C++
I am going through the one I had written for a fast 90 attack. This is allowing me to use some operations and call points.

Between reading the "tutorial notes" and your "how_to_use_speed_finder" I am getting most of it. Wiki is helping too


What I cant find is this:-

Operation|mov|<<range_min>>|600.0f|0|0|0
Operation|mov|<<range_max>>|2600.0f|0|0|0

CheckGUIDialValueInRange|SOL_RANGE|<range_min>|<ra nge_max>|None|0|0

I want to use <<heading_min>> and <<heading_max>> but not sure how to do it. Im guessing it needs to be in "GUIDialValue" and im not sure if it is.

Quote:
I forgot to include the single mission for that speed finder tutorial. I can send it to you if you'd like it.
Yes please. I used one of mine when I tried it last night. As my range etc was for a different mission, I was having to re-do to data to fit within your limits set. (very good for ensuring someone is getting it right)
__________________
Trevally Mods for SH5
Trevally. is offline   Reply With Quote
Old 12-01-10, 11:15 AM   #4
TheDarkWraith
Black Magic
 
Join Date: Jun 2007
Posts: 11,959
Downloads: 147
Uploads: 5


Default

Quote:
Originally Posted by Trevally. View Post
I am going through the one I had written for a fast 90 attack. This is allowing me to use some operations and call points.

Between reading the "tutorial notes" and your "how_to_use_speed_finder" I am getting most of it. Wiki is helping too


What I cant find is this:-

Operation|mov|<<range_min>>|600.0f|0|0|0
Operation|mov|<<range_max>>|2600.0f|0|0|0

CheckGUIDialValueInRange|SOL_RANGE|<range_min>|<ra nge_max>|None|0|0

I want to use <<heading_min>> and <<heading_max>> but not sure how to do it. Im guessing it needs to be in "GUIDialValue" and im not sure if it is.
these two commands:

Operation|mov|<<range_min>>|600.0f|0|0|0
Operation|mov|<<range_max>>|2600.0f|0|0|0

create two global variables named range_min and range_max. The << >> mean to use the variable name itself and not to dereference it (get it's value) - required for mov operations. range_min has the value 600.0 (f meaning a float value) stored (mov) into it. range_max has the value 2600.0 (f meaning a float value) stored (mov) into it. The next command:

CheckGUIDialValueInRange|SOL_RANGE|<range_min>|<ra nge_max>|None|0|0

the < > mean dereference (or get the variable's/pointer's vaue). So what the command is doing is getting the value of range_min and range_max and passing them to the CheckGUIDialValueInRange. That command is going to look up the SOL_RANGE dial's value and ensure it's within value of range_min and value of range_max. The None means I want the result of that range check stored in g_TR1 (it will store True or False in it). The None could be a variable name if you want to store the result in one of your variables/pointers.

So to do what you're wanting would be:

Operation|mov|<<heading_min>>|some_valuef|0|0|0
Operation|mov|<<heading_max>>|some_valuef|0|0|0

I just noticed that you cannot get heading from the GUI dials. I'll have to include that. I'll code it in and send you revised files But after I code it this is how you'll be able to check heading in range:

CheckGUIDialValueInRange|Current_Heading|<heading_ min>|<heading_max>|None or your variable|0|0

I'll send you the single mission for the speed finder tutorial also.
TheDarkWraith is offline   Reply With Quote
Old 12-01-10, 11:32 AM   #5
TheDarkWraith
Black Magic
 
Join Date: Jun 2007
Posts: 11,959
Downloads: 147
Uploads: 5


Default

in v5.3.0 if you select a tutorial from the list of available tutorials in the main menu page and the historic mission required for that tutorial isn't 'Any' then when you click on Historic Missions from the main menu page the historic mission needed for the tutorial will be highlighted and brought into view. This makes selecting the correct historic mission for the tutorial much easier to find. You still have to click on the historic mission highlighted to activate it as I cannot do this in code. If the required historic mission is 'Any' then no historic mission will be highlighted (as any of them can be used):
TheDarkWraith is offline   Reply With Quote
Old 12-01-10, 12:03 PM   #6
Trevally.
Navy Seal
 
Join Date: Apr 2007
Location: AN1536 (Orkney)
Posts: 5,448
Downloads: 166
Uploads: 28


Default

Quote:
Originally Posted by TheDarkWraith View Post
these two commands:

Operation|mov|<<range_min>>|600.0f|0|0|0
Operation|mov|<<range_max>>|2600.0f|0|0|0

create two global variables named range_min and range_max. The << >> mean to use the variable name itself and not to dereference it (get it's value) - required for mov operations. range_min has the value 600.0 (f meaning a float value) stored (mov) into it. range_max has the value 2600.0 (f meaning a float value) stored (mov) into it. The next command:

CheckGUIDialValueInRange|SOL_RANGE|<range_min>|<ra nge_max>|None|0|0

the < > mean dereference (or get the variable's/pointer's vaue). So what the command is doing is getting the value of range_min and range_max and passing them to the CheckGUIDialValueInRange. That command is going to look up the SOL_RANGE dial's value and ensure it's within value of range_min and value of range_max. The None means I want the result of that range check stored in g_TR1 (it will store True or False in it). The None could be a variable name if you want to store the result in one of your variables/pointers.

So to do what you're wanting would be:

Operation|mov|<<heading_min>>|some_valuef|0|0|0
Operation|mov|<<heading_max>>|some_valuef|0|0|0

I just noticed that you cannot get heading from the GUI dials. I'll have to include that. I'll code it in and send you revised files But after I code it this is how you'll be able to check heading in range:

CheckGUIDialValueInRange|Current_Heading|<heading_ min>|<heading_max>|None or your variable|0|0

I'll send you the single mission for the speed finder tutorial also.
Thanks TDW

Could I trouble you with one more, "gyroangle". This one should be in the GUI dials.

Would this work if I wanted someone to have "zero" gyroangle:-

Operation|mov|<<gyroangle_min>>|-350|0|0|0 (not sure if i need the "-")
Operation|mov|<<gyroangle_max>>|10|0|0|0

CheckGUIDialValueInRange|GyroAngle|<gyroangle_min> |<gyroangle_max>|None|0|0
__________________
Trevally Mods for SH5
Trevally. is offline   Reply With Quote
Old 12-01-10, 12:13 PM   #7
TheDarkWraith
Black Magic
 
Join Date: Jun 2007
Posts: 11,959
Downloads: 147
Uploads: 5


Default

Quote:
Originally Posted by Trevally. View Post
Thanks TDW

Could I trouble you with one more, "gyroangle". This one should be in the GUI dials.

Would this work if I wanted someone to have "zero" gyroangle:-

Operation|mov|<<gyroangle_min>>|-350|0|0|0 (not sure if i need the "-")
Operation|mov|<<gyroangle_max>>|10|0|0|0

CheckGUIDialValueInRange|GyroAngle|<gyroangle_min> |<gyroangle_max>|None|0|0

Operation|mov|<<gyroangle_min>>|358.0f|0|0|0
Operation|mov|<<gyroangle_max>>|2.0f|0|0|0

this will look for a 0 gyro angle with +- 2 degrees spread. If you want to tighten the spread use 359.0f and 1.0f for a +- 1 degree spread or to go even tighter use 359.5f and 0.5f for a +- 0.5 degree spread. the f is required on the end of the numbers to signify they are a float value (a value with a decimal part)

CheckGUIDialValueInRange|SOL_GYROANGLE|<gyroangle_ min>|<gyroangle_max>|None|0|0

The result of this check will be stored in g_TR1 since you have None as the 4th parameter.

TheDarkWraith is offline   Reply With Quote
Old 12-01-10, 12:44 PM   #8
PL_Andrev
Grey Wolf
 
Join Date: Feb 2009
Posts: 995
Downloads: 91
Uploads: 0
Default

Quote:
Originally Posted by TheDarkWraith View Post
Should it be "Multiple UI tutorial" ?
__________________

PL_Andrev is offline   Reply With Quote
Old 12-01-10, 05:22 PM   #9
col_Kurtz
XO
 
Join Date: Mar 2008
Posts: 424
Downloads: 341
Uploads: 0
Default

Quote:
Originally Posted by TheDarkWraith View Post
in v5.3.0 if you select a tutorial from the list of available tutorials in the main menu page and the historic mission required for that tutorial isn't 'Any' then when you click on Historic Missions from the main menu page the historic mission needed for the tutorial will be highlighted and brought into view. This makes selecting the correct historic mission for the tutorial much easier to find. You still have to click on the historic mission highlighted to activate it as I cannot do this in code. If the required historic mission is 'Any' then no historic mission will be highlighted (as any of them can be used):
Love it
__________________


DRM it`s a horror, horror... col. Kurtz Apocalypse Now
WinXP Pro SP3 2x1GB Geil 800Mhz DDR2, ATI 4850 Asus Top, E2160 1.80 Ghz overlocked to 2.79Ghz MoBo Asus P5b
col_Kurtz is offline   Reply With Quote
Old 12-01-10, 08:03 PM   #10
TheDarkWraith
Black Magic
 
Join Date: Jun 2007
Posts: 11,959
Downloads: 147
Uploads: 5


Default

added a new feature to v5.3.0. This feature will set the TC level to a pre-determined level when the current TC level is greater than or equal to a pre-determined TC level AND a contact is within a pre-determined radius of the sub. This should prevent those surprise you're dead at high TC levels because your crew failed to spot a highly visible contact. The three new user options and their default values are:

# the TC level at which the TCx on contact distance is enabled (this will change the TC level to a pre-determined level when a contact gets inside a specified
radius around the sub if the current TC level is greater than or equal to this value)
# below in powers of 2 only!
TCxOnContactDistanceEnabledTCLevel = 1024

# when at TC > 1 and TCxOnContactDistanceEnabled is enabled (True) then this is the radius around your sub to determine when to set TC level to
TCxOnContactDistanceTCLevel
# below in meters
TCxOnContactDistanceRadius = 8000.0

# the TC level to set when TCxOnContactDistanceEnabled is enabled (True) and contact is inside the TCxOnContactDistanceRadius
# below in powers of 2 only!
TCxOnContactDistanceTCLevel = 1

this is checked every 0.25 seconds of regular time (not game time!)
TheDarkWraith is offline   Reply With Quote
Reply

Tags
dbrn, favorite, new ui

Thread Tools
Display Modes

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:19 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.