SUBSIM Radio Room Forums



SUBSIM: The Web's #1 resource for all submarine & naval simulations since 1997

Go Back   SUBSIM Radio Room Forums > Sub/Naval + Other Games > Sub/Naval & General Games Discussion
Forget password? Reset here

Reply
 
Thread Tools Display Modes
Old 04-17-25, 02:25 PM   #1
blackcan
Gunner
 
Join Date: Oct 2012
Location: Germany
Posts: 100
Downloads: 97
Uploads: 0
bullhorn Sonar Pixelart Subsim

Hey Everyone!


I’m excited to share my current project: Sonar, a pixel‑art submarine simulator set in the Cold War. While the visuals embrace a stylized, old‑school aesthetic, I’m striving for authentic, realistic mechanics under the hood.

Although there’s not much to show yet, I’d love your feedback. If you have programming experience, feel free to dive into the code, suggest improvements, or request new features:

Sonar on Github

Planned Features
Short‑Term Goals
  • Skirmish missions & full campaign
  • Playable NATO and Soviet submarines
  • Distinct UIs for each faction

Long‑Term Roadmap
  • Mission editor for custom scenarios
  • Full modding support

Because I’m not only designing the game but also building the underlying engine from scratch, development may take longer than a typical game‑only project. Crafting a robust, flexible engine alongside all the game systems means extra architecture, testing, and iteration—but it’ll pay dividends when adding new features or mods down the road.

I intend to post weekly updates here with progress, insights, and demos. Thanks for reading and stay tuned!
__________________
blackcan is offline   Reply With Quote
Old 04-17-25, 03:17 PM   #2
Skybird
Soaring
 
Skybird's Avatar
 
Join Date: Sep 2001
Location: the mental asylum named Germany
Posts: 32,194
Downloads: 10
Uploads: 0


Default

Sounds ambitious. Hope you find some developement mates while journeying on. I'm sure our eyes will watch you with interest. Good luck!
__________________
If you feel nuts, consult an expert.
Skybird is offline   Reply With Quote
Old 04-17-25, 05:33 PM   #3
Platapus
Rear Admiral
 
Join Date: Oct 2006
Posts: 14,771
Downloads: 63
Uploads: 0


Default

Good luck with it.
__________________
abusus non tollit usum - A right should NOT be withheld from people on the basis that some tend to abuse that right.
Platapus is offline   Reply With Quote
Old 04-17-25, 07:47 PM   #4
Aktungbby
Gefallen Engel U-666
 
Aktungbby's Avatar
 
Join Date: Jul 2013
Location: On a tilted, overheated, overpopulated spinning mudball on Collision course with Andromeda Galaxy
Posts: 17,658
Downloads: 24
Uploads: 0


Default welcome back!

blackcan!
__________________

"The world is too rediculous to even live in!"- Little Big Man
Aktungbby is offline   Reply With Quote
Old 04-22-25, 04:02 AM   #5
blackcan
Gunner
 
Join Date: Oct 2012
Location: Germany
Posts: 100
Downloads: 97
Uploads: 0
Default

Development Update – 2025 - 04 - 22

Overview:
  • Refactored the Asset Registry to be seperated from the GameInstance
  • Added a PlayerUI Class, which displays, Course, Speed, Depth of the Players Submarine
  • Added correct Display for Units on the Map with some Data
  • Mostly Engine Stuff, not much Game Related

New Features:
  • Focoused Unit on Map Display Key Information all the Time

Bug Fixes:
  • Deleting of Entitity, caused a crash

Known Issues:
  • Linux Build at this point not Compatible

Next Steps & Roadmap:
  • Integrating a custom Thorp Model Variant, to realisticly calculate sound travel, without layers yet
  • PopWindows
  • Mission Details
  • TMA
  • Many Backend stuff

Also i got 2 more People on the Team, one will be responsible for some of the Art and the Other for the Music

__________________
blackcan is offline   Reply With Quote
Old 04-24-25, 06:58 AM   #6
blackcan
Gunner
 
Join Date: Oct 2012
Location: Germany
Posts: 100
Downloads: 97
Uploads: 0
Default

Screenshot Update – 2025 - 04 - 24

Main Menu:


Waterfall Sonar in two Different TimeFrames:


Map with two Submarines:
Cyan is Player, Red Enemy
__________________
blackcan is offline   Reply With Quote
Old 04-29-25, 04:57 PM   #7
Platapus
Rear Admiral
 
Join Date: Oct 2006
Posts: 14,771
Downloads: 63
Uploads: 0


Default

Do you think it is necessary to have decimals out to the millionth place?


Does the game need that precision?
__________________
abusus non tollit usum - A right should NOT be withheld from people on the basis that some tend to abuse that right.
Platapus is offline   Reply With Quote
Old 04-29-25, 06:41 PM   #8
blackcan
Gunner
 
Join Date: Oct 2012
Location: Germany
Posts: 100
Downloads: 97
Uploads: 0
Default

Development Update – 2025 - 04 - 30

Overview:
  • Implemented custom Reflection Type Class for Classes
  • Implemented a specific PlayerUI Class
  • Waterfall Sonar Display, now correctly accumulates Data between ticks, so no info is lost
  • Implemented new Map Logic, including a custom Shader to draw the world in 1:1 scale

New Features:
  • World Map
  • Improved Waterfall Display
  • World System

Known Issues:
  • Linux Build at this point not Compatible

Next Steps & Roadmap:
  • Integrating a custom Thorp Model Variant, to realisticly calculate sound travel, without layers yet
  • PopWindows
  • Mission Details
  • TMA
  • Many Backend stuff

@Platapus:
Thank you for your input! This is definitley, not necessary, under the Hood its floating point numbers, but for all readings later on, will be casted to integers

Screenshots




__________________

Last edited by blackcan; 04-30-25 at 07:29 AM.
blackcan is offline   Reply With Quote
Old 04-30-25, 06:05 PM   #9
Platapus
Rear Admiral
 
Join Date: Oct 2006
Posts: 14,771
Downloads: 63
Uploads: 0


Default

Arrrg, you worthless deck swab


I ordered steer course 43.582386


Not course 43.582385


You are relieved! Report for Captain's mast tomorrow!!!
__________________
abusus non tollit usum - A right should NOT be withheld from people on the basis that some tend to abuse that right.
Platapus is offline   Reply With Quote
Old 12-24-25, 03:48 AM   #10
blackcan
Gunner
 
Join Date: Oct 2012
Location: Germany
Posts: 100
Downloads: 97
Uploads: 0
bullhorn

First off im sorry for the long pause but had a lot of things to sort out this year.
But i continued development around a few Months Ago.

But before i retell what i worked on the last few Months here is a little Goodie for Christmas as a video



Development Update – 2025-12-24

Overview:
  • Major refactoring initiative started in temp/torefactor branch focusing on Display class and GridLayoutManager coupling
  • Integrated Sound Event system with acoustic signal processing for submarines
  • Implemented interactive UI window resizing and repositioning with handle-based controls
  • Added AABB (Axis-Aligned Bounding Box) support for map continents with horizontal wrapping
  • Refactored World rendering system, separating it from Map class for better architecture
  • Enhanced resource management with improved cleanup and shutdown procedures
  • Fixed circular dependency issues with custom deleters in event dispatcher system
New Features:
  • Sound Event Integration: Submarines now emit acoustic signals while moving; waterfall display computes bearings per signal with multi-sample rendering
  • Interactive Window Management: UI displays support dynamic resize and move operations with visual handles
  • Map Enhancements:
  • Horizontal wrap-around for seamless world navigation
  • Continent bounding boxes for faster region lookups
  • Waterfall Display Improvements: Time-scale overlay, resizable with preserved/scaled image data
  • Context Menu System: Right-click functionality on map with player centering, course setting, and speed adjustment options
  • Global Key Events: Keyboard shortcuts now context-aware based on mouse position over UI components

Backend Improvements:
  • Refactored RenderBuffer system with RAII principles for automatic GL resource cleanup
  • Consolidated continent rendering to centralized render-buffer system
  • Resource manager cleanup methods refactored with OpenMP support for Linux
  • Added Shutdown game mode for controlled application termination
  • Improved asset registry with better lifecycle management
  • Enhanced thread-safe task management

Bug Fixes:
  • Fixed custom deleter circular dependency with event dispatcher
  • Resolved memory leak in map file handling
  • Fixed array bounds checking in WaterfallDisplay to prevent segfaults
  • Corrected Linux build compatibility issues
  • Improved cross-platform path separator handling

Next Steps & Roadmap:
  • Complete Display/GridLayoutManager refactoring from temp/torefactor branch
  • Merge refactoring work back to main branch
  • Continue Thorp Model integration for realistic sound propagation
  • Implement layered sound travel calculations
  • PopWindows refinement
  • Mission Details system
  • TMA (Target Motion Analysis)
  • Further backend architecture improvements

I wish everyone a happy christmas and a happy new year
__________________
blackcan is offline   Reply With Quote
Old 12-24-25, 02:12 PM   #11
magicstix
Commander
 
Join Date: Aug 2011
Location: Nuclear submarine under the North Pole
Posts: 469
Downloads: 1
Uploads: 0
Default

Just FYI, you can get a decent propagation model off github with USML (UnderSea Modeling Library).

It's a 3d acoustic raytracer.

Add in some historic sound speed profiles from NOAA's World Ocean Atlas and gebco bathymetry and you can get a very accurate sound propagation model for your SONAR.
magicstix is offline   Reply With Quote
Old 12-25-25, 04:30 AM   #12
blackcan
Gunner
 
Join Date: Oct 2012
Location: Germany
Posts: 100
Downloads: 97
Uploads: 0
Default

Quote:
Originally Posted by magicstix View Post
Just FYI, you can get a decent propagation model off github with USML (UnderSea Modeling Library).

It's a 3d acoustic raytracer.

Add in some historic sound speed profiles from NOAA's World Ocean Atlas and gebco bathymetry and you can get a very accurate sound propagation model for your SONAR.
Oh Awesome! Thank you i didn't knew that existed open source!
I will probably implement this and also the "simplified" Thorp Model to better support low end and old Hardware and either have this as a Fallback depending on Distance (I am not 100% sure but i assume, the closer the Target the is the less relevant is the useage of the USM Raytracer or thorp modell) or have it toggle able in the Options

Thank you a lot!
__________________
blackcan is offline   Reply With Quote
Old 12-29-25, 04:43 PM   #13
magicstix
Commander
 
Join Date: Aug 2011
Location: Nuclear submarine under the North Pole
Posts: 469
Downloads: 1
Uploads: 0
Default

Quote:
Originally Posted by blackcan View Post
Oh Awesome! Thank you i didn't knew that existed open source!
I will probably implement this and also the "simplified" Thorp Model to better support low end and old Hardware and either have this as a Fallback depending on Distance (I am not 100% sure but i assume, the closer the Target the is the less relevant is the useage of the USM Raytracer or thorp modell) or have it toggle able in the Options

Thank you a lot!
Thorp is just an absorption coefficient model. It doesn't really add a whole lot above simple geometric spreading.

Whether or not you need an actual raytracer depends entirely on the sound speed profile gradient. You'd generally only see "straight line" (called isovelocity or sometimes incorrectly referred to as direct path) propagation at very short ranges (< 2 km), but even then it's not guaranteed. If the profile gradients are steep the ray paths can start bending immediately.
magicstix is offline   Reply With Quote
Old 01-02-26, 07:58 PM   #14
blackcan
Gunner
 
Join Date: Oct 2012
Location: Germany
Posts: 100
Downloads: 97
Uploads: 0
Default

Quote:
Originally Posted by magicstix View Post
Thorp is just an absorption coefficient model. It doesn't really add a whole lot above simple geometric spreading.

Whether or not you need an actual raytracer depends entirely on the sound speed profile gradient. You'd generally only see "straight line" (called isovelocity or sometimes incorrectly referred to as direct path) propagation at very short ranges (< 2 km), but even then it's not guaranteed. If the profile gradients are steep the ray paths can start bending immediately.
Yes i know but what thorp enables me from open world aspect is to precaculate each cell of my spatial quad tree with their attenuations in respect to speed, so i can skip any calculations when the ambient / distance / sound strength etc. would be too big anyways

for the USML Raytracer i will need to check on performance and thread safety for several emitter + several receiver.
__________________
blackcan is offline   Reply With Quote
Old 01-02-26, 08:45 PM   #15
magicstix
Commander
 
Join Date: Aug 2011
Location: Nuclear submarine under the North Pole
Posts: 469
Downloads: 1
Uploads: 0
Default

Quote:
Originally Posted by blackcan View Post
Yes i know but what thorp enables me from open world aspect is to precaculate each cell of my spatial quad tree with their attenuations in respect to speed, so i can skip any calculations when the ambient / distance / sound strength etc. would be too big anyways

for the USML Raytracer i will need to check on performance and thread safety for several emitter + several receiver.
"...attenuations in respect to speed..."

Not quite sure I follow. Attenuation isn't speed related; it's entirely based on distance and reflection losses.

Is your plan somehow to use the quad tree to add up all cells between source and receiver and calculate the attenuation from that? That would be less accurate than just doing simple geometric spreading.

The sonar equation is very simple:

RL = SL - TL;

PD = (RL - LE + DI) * RD;

Where:

RL = receive level
SL = source level
TL = transmission loss

PD = probability of detect
LE = noise level (Ambient + self)
DI = directivity index (Ability of beamformer and processing to increase gain)
RD = recognition differential (50% chance of a SONAR operator "seeing" a trace bright enough to call contact. Personally I wouldn't use this metric as it's very arbitrary)

LE = Ns + Nw + Self
Ns = shipping noise
Nw = wind noise
Self = Self noise

For a simulation you'd want to cast it in terms of SNR, which is just
SNR = (SL - TL + DI) - LE, but you can simply say "if RL > LE we have a chance at contact" or, more accurately, if RL > some threshold above LE we hold contact.

LE would be the average brightness of your background "salt and pepper" on the waterfall, and RL is the individual contact trace. If a trace is bright enough to exceed that LE, then a player can see it, otherwise it's lost in the background noise.

USML is how you calculate the TL term, but it also gives you other useful information like the ray arrival angles and will create real effects like CZs and shadow zones.
magicstix is offline   Reply With Quote
Reply

Tags
cold, pixelart, subsim, war


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 05:28 PM.


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.