UBOAT
[DEPRECATED] UBOAT SOP: Turn On Red Light
50 Comments
marLeo 17 Jul @ 2:08pm 
Thanks for this mod. It was really nice, when the mechanic wasn't in the base game.
PriLLi 23 Feb @ 9:33pm 
Da man diesen Mod nun nicht mehr braucht,
möchte ich trotzdem "Danke" für deine tolle Arbeit sagen.
Und ich hoffe du läßt dir noch viele andere tolle kleine Änderungen einfallen ...
Mach weiter so ... :steamthumbsup:
andargor  [author] 23 Feb @ 7:21am 
@Royal Raven Confirmed! I will mark this mod as deprecated
Royal Raven 23 Feb @ 7:05am 
Sounds like this and Compressor mod, was added to base game.
andargor  [author] 22 Feb @ 7:17pm 
UPDATE: Skipper is now silenced when at highest time compression, hopefully that will alleviate the annoyance factor
andargor  [author] 17 Feb @ 4:30pm 
@Mongoloid I have no plans for that, but the source code is available for any one willing to make a variant (link in description)
Mongoloid 17 Feb @ 10:27am 
Any plans to make this compatible with the Realistic Lighting Mod?
andargor  [author] 16 Feb @ 6:49am 
@CottonCuddle If only I knew how, I would silence the captain when at high compression. Right now, I interrupt him if I can but can't always catch him, it was worse before. If anyone can look at my code and indicate how to silence the captain, let me know (link in description)
CottonCuddle 16 Feb @ 2:34am 
I keep getting that audio 'Night Lights!' repetitive command in audio. Every minute it says 'Night lights'. How do i stop the crew repeating that over and over and over? :(
Zero 16 Feb @ 1:34am 
This works on 2025.1
Bender 15 Feb @ 7:35am 
@andargor that does seem to fix it somehow! but it returned again when i launched the game later in the day, it does get fixed when i unsubscribe and subscribe again though.. weird, but thanks anyway!
andargor  [author] 13 Feb @ 9:47pm 
@Bender Just tested and I'm not getting that. Close game, unsubscribe, delete the mod if it isn't already from %USERPROFILE%\AppData\LocalLow\Deep Water Studio\UBOAT\Mods , then subscribe again?
Bender 13 Feb @ 9:33pm 
doesn't seem to be working for me in the latest version on a clean install, have activated the mods and checked the output_log.txt file and I saw this:

UBOATSOP_TurnOnPump Version 2024.1.14.27
UBOATSOP_TurnOnRedLight Version 2024.1.14.19
UBOATSOP_LeavePortButton Version 2025.1.14.74
UBOATSOP_TurnOnCompressor Version 2024.1.14.18

Slot "Conning Tower" is defined for entity type "Type VIIB (Player)" in game data, but it's missing in the entity prefab.
System.NullReferenceException: Object reference not set to an instance of an object
at UBOATSOP_LeavePortButton.AddListeners () [0x00000] in <68a5d35045da4c4ea40ff4b3d54ce060>:0
System.NullReferenceException: Object reference not set to an instance of an object
at UBOATSOP_TurnOnRedLight.DoUpdate () [0x00000] in <a7d00320fedf4df5879802799e2d6394>:0
andargor  [author] 24 Jan @ 10:22am 
Verified still working with 2025.1
Niinox 20 Jan @ 12:55pm 
SOP set playing nice with the new 2025.1?
kingofallmuffins 10 Jan @ 4:39pm 
do i have to do something for it to work
andargor  [author] 6 Jan @ 12:13pm 
Friedrich 4 Jan @ 5:33pm 
The mod isn't working for me. Was it broken by an update?
andargor  [author] 18 Dec, 2024 @ 11:47am 
@Airplayn I tried to tone it down, but on high compression I haven't found a way to mute him completely.
Airplayn 17 Dec, 2024 @ 6:26pm 
Captain keeps saying " night lights" over and over. I had to delete the phrase "night light" from the XLXS files
SlyRedGuy 30 Nov, 2024 @ 3:47pm 
@andargor. Experiment done, achievements are still intact. MOD seems to be running flawlessly. Thanks
andargor  [author] 30 Nov, 2024 @ 9:07am 
@SlyRedGuy I mention that because usually using mod disable achievements in other games, and I can't be totally sure with UBOAT, so I don't want to screw people over inadvertently. However, I personally still get achievements with my mods in this game. To be 100% certain, what you could do is wait until you get an achievement, save, go to your previous save, load the mod, check if you get the achievement with the mod.

Sorry if my disclaimer is confusing, but I would rather err on the side of caution.
SlyRedGuy 28 Nov, 2024 @ 12:08am 
Note
Does not require a new game. May disable achievements (I don't really know)..... Has anyone had any troubles loading this in a saved game??....2nd, what does it mean to "disable achievements"?
This sounds like a good quality of life mod, but I don't want to mess up where I'm at in the game
Groucho Marx 9 Nov, 2024 @ 1:05am 
Not calling this mod Roxanne was a mistake
houghs 25 Sep, 2024 @ 8:44pm 
I do get what your saying being a navy vet. just observing
andargor  [author] 25 Sep, 2024 @ 6:26pm 
@houghs It uses the game's definition of "light" and "dark", and the time can vary by latitude
houghs 25 Sep, 2024 @ 3:14pm 
would it be possible to come on at or near sunrise and or sunset instead of 9 am
Eridano2013 20 Sep, 2024 @ 9:52am 
[warning: off topic]
if I may ask, I would like a mod SOP called "Battle stations!" where, in case of alarm, each Officer would have his pre-assigned place. For example, this would be my typical stations:
- captain: attack periscope;
- deputy: TDC;
- hydrophonist: to hydrophone;
- radio operator: to radio;
- first engineer: to engines
- second engineer: to leveling planes;
- torpedo operator: to damage control.
Each position should be selectable via a mini excel sheet - or a text file - to be attached to the Mod.
andargor  [author] 20 Sep, 2024 @ 9:18am 
It's not perfect though, it depends if there are other things going on, like a dive schedule every hour. At high compression, you'll hear the captain once and a while. I might try something when I have more time.
Eridano2013 20 Sep, 2024 @ 9:13am 
Thank you. Very welcomed.

> Version update; The captain is now mostly silent when giving lighting orders
andargor  [author] 20 Sep, 2024 @ 9:10am 
UPDATE: Version update; The captain is now mostly silent when giving lighting orders
TychoBrahe208 14 Sep, 2024 @ 12:05am 
I like these SOP-mods.
Have a suggestion for another: could you make one so that they remove the flag out-of-port? Always find it annoying/unrealistic that a warship is openly flagging its allegiance like this, not to mention seeing it while submerged.
Eridano2013 13 Sep, 2024 @ 8:50am 
the captain just annoying during time compression, especially in harbor, waiting for loading, holidays, etc.
andargor  [author] 13 Sep, 2024 @ 7:58am 
@Eridano2013 Removing a specific voice line from a character? That's a whole another ball of wax. I have no idea. Are you having the same issue as Ozone, or is the captain just annoying during time compression?
Eridano2013 13 Sep, 2024 @ 2:18am 
@andargor
could you silent the captain's voice: "red light on/ white light on" when time compression is on?
Thanks.
andargor  [author] 12 Sep, 2024 @ 4:20pm 
In Start() you can see that DoUpdate() will be executed every 5 seconds (performance reasons). lightingIterationsRemaining is used to ensure that it is only checked every 6 iterations (30 seconds) once an order has been given. This is to ensure that the captain doesn't ask for the lights again until the sailor finishes toggling the light (I think that the code I added lately to check if it was already in the action queue makes this redundant).

I am not sure about your comment about dark weather, it's etiher/or, red light at night, normal light at day. Note that blue lights will be ignored if you look at the conditions.
Ozone 12 Sep, 2024 @ 2:42pm 
I took a peek at the code. I don't understand lightingIterationsRemaining = 6 ; also are the listeners for darkweather working since you check isNight, but not check for dark weather in TurnOnRedLight?
andargor  [author] 12 Sep, 2024 @ 10:18am 
@Ozone I am not sure what it is then. I haven't seen that issue in several in-game months, but then I only use my mods. Maybe interference by another mod? Someone said Realistic Lights didn`t work well with mine, since I use vanilla lighting states to determine whether lights should be switched or not, and I am thinking it modifies that.

Let's see if other people have the issue. Take a look at the code if you have any ideas, it's linked in the description.
Ozone 11 Sep, 2024 @ 5:13pm 
Nope, it still occurs, especially when time is accelerated.
I also found another minor bug; when you send your crew on vacation, and pass time, the day cycle very quickly, and the voice lines from light changes pile-up. The game plays them continuously for about a whole minute.
andargor  [author] 9 Sep, 2024 @ 7:17am 
@Ozone Hmm, strange. The code already checks for duplicate switch orders, and I haven't had that happen. I've reinforced the conditions, let me know if it seems to resolve the issue.
Ozone 9 Sep, 2024 @ 1:50am 
Very nice mod. There's just a minor bug, it may repeat the order again and again if the sailors are too slow to execute the action. Instead of checking which light is currently active, it should check which light is being requested first. That way, when your script requests a red light, it won't request it again. I've also had that case when I requested blue-light, and your script came right after and overided my order. My suggestion would also fix this edge-case behavior.
(v)1GHTY )v(4V$ 4 Sep, 2024 @ 3:22am 
@andagor it seems since realistic lights removes the blue light and the light switch it has no fallback for SOP and is stuck in a loop to trigger to give the order to hit the switch which is not there anymore. Realistic lights also have red lights (really dimmed white light) fixed to a certain depth or emergency alarm. I thought having both SOP and Realistic Lights would pick both the timing scale and the conditions but I guess it cancels the script somehow.
Eridano2013 3 Sep, 2024 @ 10:10am 
@andargor
may I suggest a SOP to redirect which officers must go to every station during alarm? Now they are sometimes random, and I have to manually give *my* stations.
Example: torpedo man to the radio, Radioman to the Echo, 1st engineer to electric motor, 2nd engineer to planes, XO to watch for discipline, Commander to attack periscope.
Thank you.
andargor  [author] 3 Sep, 2024 @ 10:10am 
@(v)1GHTY )v(4V$ I'm not sure what all that means, since I don't use that mod. I'm using the same method that the vanilla game uses when you click on red lights in the tab menu.
(v)1GHTY )v(4V$ 3 Sep, 2024 @ 7:51am 
It seems to trigger a repeated Order to turn to Red Lights when using Realistic Lights and also messes the surface recognition so it switches to reduced light (which would be red lights and it ticks the box) also when above the threshold of below periscope depth or not beeing in bad weather.
Ivellios 2 Sep, 2024 @ 9:25am 
Thahat 1 Sep, 2024 @ 6:39am 
nice! i was already missing the auto (lights) mods!
andargor  [author] 1 Sep, 2024 @ 6:31am 
Fixed
andargor  [author] 1 Sep, 2024 @ 6:11am 
That is a glaring oversight isn't it? :))) Will fix when I have a bit of time.
Eridano2013 1 Sep, 2024 @ 1:16am 
@andargor
... and turning the light white at daytime? :steamhappy: