Sonar2D is a 2D sonar detection and minimap system for
Unity. Emit expanding sonar waves that detect targets and
display them on a radar-style minimap.Sonar2D is a 2D sonar detection and minimap system for Unity. Emit expanding sonar waves that detect targets and display them on a radar-style minimap. Features: Expanding sonar wave with visual ring effect WiFi-style pulse feedback at detected targets Automatic minimap with fading icons Per-target customization (color, size, signal strength) Cooldown and audio support Upgrade methods for power-ups (range, speed, cooldown) Optional filtering callbacks for custom detection logic Works with both Legacy and New Input System No prefabs required - fully automatic icon creation Lightweight (~40KB), no dependencies Includes: 6 core scripts 2 example scripts Demo scene Full documentationExpanding Sonar Wave - Visual ring that expands outward from emitter, detecting targets as it passes through themWiFi-Style Pulse Effects - Animated arc effects appear at detected targets, pointing back toward the emitter with configurable color, size, and brightnessAutomatic Minimap System - Radar-style UI display that shows detected targets with fade-in/fade-out animations. Icons created automatically at runtime - no prefabs neededPer-Target Customization - Each SonarTarget has independent settings for pulse color, pulse size, duration, signal strength, minimap color, and minimap icon sizeCooldown System - Built-in cooldown timer prevents wave spam, with public methods to modify at runtimeAudio Integration - Optional AudioClip field for wave emission sound effectsUpgrade Methods - IncreaseRange(), IncreaseSpeed(), and ReduceCooldown() methods for power-up and progression systemsCustom Filtering - Callback delegates on SonarWave andMinimapController allow filtering which targets can be detected or displayedInput System Agnostic - Automatic detection and support for both Legacy Input Manager and New Input SystemEvent System - UnityEvent fired on wave emission for UI feedback, animations, or game logic hooksDebug Options - Toggle debug logging on WaveEmitter, SonarTarget, and MinimapController for troubleshootingZero Dependencies - Pure C# scripts using only built-in Unity APIs. No external packages requiredLightweight - ~40KB total package size with 8 scripts and full documentation




