SUBSIM Radio Room Forums

SUBSIM Radio Room Forums (https://www.subsim.com/radioroom/index.php)
-   SH5 Mods Workshop (https://www.subsim.com/radioroom/forumdisplay.php?f=249)
-   -   [REL] Multiple UIs for SH5 with TDC (https://www.subsim.com/radioroom/showthread.php?t=166093)

Vanilla 12-19-10 07:28 AM

Quote:

Originally Posted by TheDarkWraith (Post 1556059)
True true. But I still can't get Antar's formula to work correctly. Comparing the values it returns to the torp line's time doesn't even come close :hmmm:

Here's the code I have for it:

Code:

  # get the target's speed
  ts = Menu.GuiDials.GetValue( GuiDialsWrapper.DialTypes.SOL_SPEED )
  if ts == 0:
  ts = 0.000001
  # get the distance to target
  td = Menu.GuiDials.GetValue( GuiDialsWrapper.DialTypes.SOL_RANGE )
  # get the target's AOB from the TDC dial
  taob = abs( Menu.GuiDials.GetValue( GuiDialsWrapper.DialTypes.SOL_ANGONBOW ) )
  # get the track angle
  tangle = abs( Menu.GuiDials.GetValue( GuiDialsWrapper.DialTypes.SOL_TRACKANGLE ) )
  # calculate 3rd angle of triangle
  auxangle = radians( 180 - taob - ( 180 - tangle ) )
  s_ship = td * ( sin( auxangle ) / sin( radians( 180 - tangle ) ) )
  s_torp = td * ( sin( radians( taob ) ) / sin( radians( 180 - tangle ) ) )
  #to hit torp.time = ship.time
  impacttime = int( round( s_ship / ts ) )
  impacttimemins = impacttime / 60
  impacttimesecs = impacttime - ( impacttimemins * 60 )

I don't understand why we're calculating s_torp when we never use it :06:

Using the TDW_Torp_Tutorial single mission when I set up the shot the torp line says ~2:33 to impact and the caculated values above say 0:35

I guess we forgot to convert knots to m/s. :) Do you get knots from the speed dial? if yes - multiply it by 0.514444 to get m/s.
Another thing: impacttimemins is int or float/double? If float - then you will always get zero seconds.

TheDarkWraith 12-19-10 08:33 AM

Quote:

Originally Posted by Vanilla (Post 1556461)
I guess we forgot to convert knots to m/s. :) Do you get knots from the speed dial? if yes - multiply it by 0.514444 to get m/s.
Another thing: impacttimemins is int or float/double? If float - then you will always get zero seconds.

No we didn't. Pulled torp speed from dial in knots and multiplied by 0.5145 to convert to m/s. impacttime is an int and integer division used to find impacttimemins so we're all good there also :up:

TheDarkWraith 12-19-10 08:35 AM

Quote:

Originally Posted by Vanilla (Post 1556452)
Did you have a target locked? AFAIR you need a target for those to appear but I can be wrong on that.
By the way it is funny to see those buttons working still after your target has already sunk. :)

now that sounds like a bug that needs to be fixed. You have to have either a target selected or locked for those buttons to appear. I'll have to correct them being visible when target is destroyed :yep:

EDIT:

updated menu.txt file for v5.7.2 for French uses by pfeillant: http://www.filefront.com/17670290/v5...-pfeillant.7z/

mobucks 12-19-10 01:11 PM

Good day gentleman. A quick question if I may?

Must i disable the mod in JSGME to make changes to TDWuseroptions.py?

I know, i know, i should search, but I'm bad at that.

TheDarkWraith 12-19-10 01:15 PM

Quote:

Originally Posted by mobucks (Post 1556589)
Good day gentleman. A quick question if I may?

Must i disable the mod in JSGME to make changes to TDWuseroptions.py?

I know, i know, i should search, but I'm bad at that.

if you don't then changes will be temporary and will be deleted when you disable the mod via JSGME. If you want them to be permanent then yes you need to disable first then edit.

TheDarkWraith 12-19-10 03:14 PM

just finishing up v5.8.0. This version adds the ability to add supermarks to the navigation map. Supermarks are identical to navigation fixes except that no navigation information is stored in them (you have the whole thing to add text to). They are also different in that they can be used without real navigation enabled. As with navigation fixes, supermarks can only be placed and viewed on the navigation map. Supermarks are like the regular map tools marker except that you get to add text to it. I've also included a small 'X' to the navigation fixes and supermarks so you can definitively see where the actual position of it is:
http://www.subsim.com/radioroom/pict...pictureid=3429

If toolhelper is enabled then supermarks are available (if navigation map is open).

v5.8.0 will be releasing here soon :|\\

Sammi79 12-19-10 04:18 PM

Real Navigation questions
 
Hi TDW,

I noticed something curious whilst using the real nav mod in your NewUI 5.7.2. The digital clock top right shows updated local time yes? This is very cool but in reality our ability to fix longitude would be the only way to guess exact local time - in fact knowing exact local time is unimportant unless trying to guess when local noon is to make a sun fix.

What I noticed however was that the stopwatch also keeps time, but it is seemingly set to GMT. I loaded a saved game and the Navigator fixes my position at start, showing my longitude to be 1.5 degrees East or 1 degree, 2 minutes East, roughly. (for longitude 1 degree = 4 minutes or 240 seconds of arc) Therefore my local time should be 6 minutes ahead of GMT and sure enough, the digital clock reads 16:48 while the stopwatch reads 16:42

Here is a screenshot to describe it better :

http://img255.imageshack.us/img255/3...1012191828.jpg

So is the stopwatch actually keeping GMT, or is this just a coincidence? I hope it is though, the stopwatch has a second hand (small dial bottom) for accuracy of seconds and longitude measurements are commonly made east or west from 0 degrees (Greenwich Meridian)

I think if this is the case then the digital clock should keep Base Time while the stopwatch should keep GMT. Having the clock update itself to local time constantly makes it hard to time long journeys. The digital clock is currently not suitable for measurements as no seconds are displayed. It should remain purely as a quick travelling time reference.

Anyway, I hope that explains my query. Other thoughts on real navigation :-

Sun and moon angular size should be 0.5 degrees rather than 2.5 or whatever they are at now. The trouble is they will look very small so perhaps decrease the angular value of the camera to offset. The bonus would be that the sunrise sunset times (time from start to rise - end to rise and start to set - end to set) would be accurate and sun measurements could be tested.

Navigator could have an extra 'dead reckoning' style fix with no weather or time limits, smaller errors (+-500m?) but always works from last fixed position including any error.

Phew I bet you wish you never added that real nav mod!:D but I gotta tell you it is totally making the game for me, SH4 inadequacies in this department were frustrating. Thankyou TDW and contributors for your outstanding work.

Regards,

Sam.

Trevally. 12-19-10 04:36 PM

Hi TDW

I am using the following in a tutorial file to check user TDC setting on multipule target AOB using the TDC dial:-


Operation|mov|<<aob_delta>>|15.0f|0|0|0
;blah blah (whole tutorial here)
; Functions:
Label|SetTargetAOB|0|0|0|0|0
GetAngle|3|None|0|0|0|0
Operation|mov|<<aob_min>>|<g_TR1>|0|0|0
Operation|-|<<aob_min>>|<aob_delta>|1|0|0
Operation|int|<<aob_min>>|<aob_min>|0|0|0
Operation|mov|<<aob_max>>|<g_TR1>|0|0|0
Operation|+|<<aob_max>>|<aob_delta>|1|0|0
Operation|int|<<aob_max>>|<aob_max>|0|0|0
CheckGUIDialValueInRange|SOL_ANGONBOW|<aob_min>|<a ob_max>|None|0|0
Operation|rtrue|None|0|0|0|0
DisplayText|Your AOB is more than 15 Deg out!|0|0|0|0|5
Jump|WrongAOB|0|0|0|0|0

I have set the + - operations to 1 for dials 180 to -180.

Some target check work fine and others dont.
The ones that dont are out by 180 deg.:hmmm:

Any ideas:06:

TheDarkWraith 12-19-10 04:36 PM

Quote:

Originally Posted by Sammi79 (Post 1556679)
Hi TDW,

I noticed something curious whilst using the real nav mod in your NewUI 5.7.2. The digital clock top right shows updated local time yes? This is very cool but in reality our ability to fix longitude would be the only way to guess exact local time - in fact knowing exact local time is unimportant unless trying to guess when local noon is to make a sun fix.

Digital clock does indeed show updated local time. The reason the digital clock does and not the analog stopwatch is that I have control of the digital clock. The game, via hardcode, controls the updating of the stopwatch. As I can't set the stopwatch's time the only way I could show local time was via the digital clock. Do I need to add seconds display to the digital clock?

What I noticed however was that the stopwatch also keeps time, but it is seemingly set to GMT. I loaded a saved game and the Navigator fixes my position at start, showing my longitude to be 1.5 degrees East or 1 degree, 2 minutes East, roughly. (for longitude 1 degree = 4 minutes or 240 seconds of arc) Therefore my local time should be 6 minutes ahead of GMT and sure enough, the digital clock reads 16:48 while the stopwatch reads 16:42

Stopwatch will always read GMT time.

So is the stopwatch actually keeping GMT, or is this just a coincidence? I hope it is though, the stopwatch has a second hand (small dial bottom) for accuracy of seconds and longitude measurements are commonly made east or west from 0 degrees (Greenwich Meridian)

I think if this is the case then the digital clock should keep Base Time while the stopwatch should keep GMT. Having the clock update itself to local time constantly makes it hard to time long journeys. The digital clock is currently not suitable for measurements as no seconds are displayed. It should remain purely as a quick travelling time reference.

What I'll do is let you be able to select the digital clock to display GMT time or local time. How's that? :D I was just about to release v5.8.0 but that's ok, I'll incorportate this change :up:

Anyway, I hope that explains my query. Other thoughts on real navigation :-

Sun and moon angular size should be 0.5 degrees rather than 2.5 or whatever they are at now. The trouble is they will look very small so perhaps decrease the angular value of the camera to offset. The bonus would be that the sunrise sunset times (time from start to rise - end to rise and start to set - end to set) would be accurate and sun measurements could be tested.

Wouldn't this be suited more to the environment mod (or an environment mod)? Sorry but I'm not well versed in celestial navigation. How are you getting the sun and moon angular sizes? :hmmm:

Navigator could have an extra 'dead reckoning' style fix with no weather or time limits, smaller errors (+-500m?) but always works from last fixed position including any error.

Hmm...I'll think about it :hmmm:

Phew I bet you wish you never added that real nav mod!:D but I gotta tell you it is totally making the game for me, SH4 inadequacies in this department were frustrating. Thankyou TDW and contributors for your outstanding work.

I think you'll find the addition of supermarks in v5.8.0 a welcome addition. The regular marker tool that makes X's on the map is useless. It needed an overhaul :yep: I still left that map tool available though as I see some uses for it.

See above in yellow.

Dissaray 12-19-10 04:47 PM

I've been flaowing your mod here for some time and have been enjoying it very much when I find the time to play. One thing I noticed in the mod is the in-scope targeting wheels; like those form the OLC and MaGUI mods from SH3. I realy liked these tools from those mods and was wondering if they worked in the same way in your mod? As it stands now I have trubble hiting things useing the tools provided in the game, it is mostly a speed and AOB thing and that in-scope wheel is marvolus for figureing that stuf out.

TheDarkWraith 12-19-10 04:49 PM

Quote:

Originally Posted by Dissaray (Post 1556690)
I've been flaowing your mod here for some time and have been enjoying it very much when I find the time to play. One thing I noticed in the mod is the in-scope targeting wheels; like those form the OLC and MaGUI mods from SH3. I realy liked these tools from those mods and was wondering if they worked in the same way in your mod? As it stands now I have trubble hiting things useing the tools provided in the game, it is mostly a speed and AOB thing and that in-scope wheel is marvolus for figureing that stuf out.

if you're taking about the RAOBF then yes, it's in the mod. There's a button in the torpedo box on the left bottom that says RAOBF. Click it to display the RAOBF on the scope.

Dissaray 12-19-10 04:56 PM

Yep that sounds like the thing. Now all I have to do is remember exactly how to use the damn thing :haha: But I am sure I can figure that out.

Trevally. 12-19-10 04:58 PM

Quote:

Originally Posted by Trevally. (Post 1556686)
Hi TDW

I am using the following in a tutorial file to check user TDC setting on multipule target AOB using the TDC dial:-


Operation|mov|<<aob_delta>>|15.0f|0|0|0
;blah blah (whole tutorial here)
; Functions:
Label|SetTargetAOB|0|0|0|0|0
GetAngle|3|None|0|0|0|0
Operation|mov|<<aob_min>>|<g_TR1>|0|0|0
Operation|-|<<aob_min>>|<aob_delta>|1|0|0
Operation|int|<<aob_min>>|<aob_min>|0|0|0
Operation|mov|<<aob_max>>|<g_TR1>|0|0|0
Operation|+|<<aob_max>>|<aob_delta>|1|0|0
Operation|int|<<aob_max>>|<aob_max>|0|0|0
CheckGUIDialValueInRange|SOL_ANGONBOW|<aob_min>|<a ob_max>|None|0|0
Operation|rtrue|None|0|0|0|0
DisplayText|Your AOB is more than 15 Deg out!|0|0|0|0|5
Jump|WrongAOB|0|0|0|0|0

I have set the + - operations to 1 for dials 180 to -180.

Some target check work fine and others dont.
The ones that dont are out by 180 deg.:hmmm:

Any ideas:06:

I have also tried setting the yellow numbers to 0 and 2 - as in your speed tutorial.

It also only works with some targets.

Sammi79 12-19-10 04:58 PM

Quote:

Originally Posted by TheDarkWraith (Post 1556687)
What I'll do is let you be able to select the digital clock to display GMT time or local time. How's that? :D I was just about to release v5.8.0 but that's ok, I'll incorportate this change :up:

Fantastic! but have selection between Base time / Local time + don't worry about seconds display, timing would be done on the stopwatch anyhow (GMT)

Quote:

Originally Posted by TheDarkWraith (Post 1556687)
Wouldn't this be suited more to the environment mod (or an environment mod)? Sorry but I'm not well versed in celestial navigation. How are you getting the sun and moon angular sizes?

0.5 is the real angular value of the sun, the moon would be 0.499 (but this is only noticeable during total solar eclipse) The angular size of the sun in game can be measured with the RAOBF in the OBS scope providing the sun is low enough to be viewed. It was fairly easy to change in SH4 sky object radius increase or something. I shall have a look in the files myself :03:

Quote:

Originally Posted by TheDarkWraith (Post 1556687)
I think you'll find the addition of supermarks in v5.8.0 a welcome addition.

wow :o speechless :o Is there really only one of you? :yeah:

Jaeger 12-19-10 05:26 PM

Quote:

Originally Posted by TheDarkWraith (Post 1556644)
just finishing up v5.8.0. This version adds the ability to add supermarks to the navigation map. Supermarks are identical to navigation fixes except that no navigation information is stored in them (you have the whole thing to add text to). They are also different in that they can be used without real navigation enabled. As with navigation fixes, supermarks can only be placed and viewed on the navigation map. Supermarks are like the regular map tools marker except that you get to add text to it. I've also included a small 'X' to the navigation fixes and supermarks so you can definitively see where the actual position of it is:
http://www.subsim.com/radioroom/pict...pictureid=3429

If toolhelper is enabled then supermarks are available (if navigation map is open).

v5.8.0 will be releasing here soon :|\\

TDW, you made my day:rock:


All times are GMT -5. The time now is 12:52 AM.

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