Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length

 
Advanced search

1408586 Posts in 68947 Topics- by 62846 Members - Latest Member: AdinaElsa

September 22, 2023, 06:59:30 AM

Need hosting? Check out Digital Ocean
(more details in this thread)
TIGSource ForumsCommunityDevLogsPing (working title)
Pages: [1]
Print
Author Topic: Ping (working title)  (Read 12885 times)
CodeSquares
Level 0
**


View Profile WWW
« on: July 11, 2014, 12:50:13 PM »

    Ping - submarine tactical warfare (working subtitle too!)

    Ping will be a top-down, semi-abstract submarine warfare game with the focus being on locating, intercepting, stalking and sinking ships while avoiding detection and countermeasures, all the while managing on-board resources such as damage, air reserves, fuel supplies and crew morale.

    It is loosely set in the WW2 era simply because it was an era of unreliable equipment, ridiculous odds and very limited resources. No particular country is represented.

    The game will be played from the main screen, which will do triple duty as overhead view (abstracted), sonar and eventually combat map - elements which veterans of the Silent Hunter games will recognize readily. The abstraction is part stylistic and part practical choice, allowing me to focus on development without needing to coordinate with art resources.

    I've been working on this for a while and realized I wouldn't mind putting down some of my dev thoughts. In addition I hope to solicit Unity tips - for example, I recently learned that Unity GUI is intended more for prototyping, but that nGUI is coming soon and may change things. Basically, any noobie Unity developer tips are welcome.

    Resources used:
    • Engine and Language - Unity, C#
    • 3D Assets - SketchUp
    • 2D Assets - currently placeholders from google image search and public domain documents. When a stage is reached that it makes sense to do so, art will be researched and outsourced.
    • Sound FX - SFXR for now

    Images:


    Submersion test.


    Manned/unmanned station test. This is the actual game screen.


    Just scoping out the scene view.

    Links:

    • IndieDB
    • CodeSquares Working blog. Mostly history of my previous game (archived here) but there'll be a few unity/ping posts there too.
    • Dev twitter - not hugely active atm. I tend to tweet from my regular account, here.
    Logged
    CodeSquares
    Level 0
    **


    View Profile WWW
    « Reply #1 on: July 11, 2014, 12:50:28 PM »

    (WIP)

    Past Mini Devlog, first month or so
    - Created basic shapes in Sketchup. Imported them to Unity. Realized that not having them centered in SketchUp means no end of pain in Unity, so redid them all.
    - Created a basic scene in Unity with camera facing the right way. Success!
    - Messed around with lights, gave up. What I have works for now and there's lots of other systems to deal with.
    - Messed around with water, gave up. I have a blue background, that'll do for now.
    - Implemented basic motion using position and rotation and arrow keys.
    - Realized I can leverage Unity physics to make things move more realistically. Rewrote movement using Force and Torque. Results exceeded expectations, will continue tweaking mass and drag numbers.
    - Made boat model rotate to visibly match direction.
    - Changed speed to be incremental, i.e. Full Speed Ahead, Slow Speed Ahead, Emergency Back, Full Stop instead of just pressing arrow down and having it increase forever. Messed with numbers until I got something that made sense for WW2 era subs.
    - Added z-axis movement.
    - Added limits on z-axis movement when I realized my boat could fly.
    - First stab at concept of crew and compartments. This took a lot of revision and isn't done yet.
    - Animations for crew adding/subtracting.
    - Concept of manned compartments. Tied them to movement so that unmanned Command room = no movement possible.
    - Fleshed out the compartments and assigned actual crew to them. Each compartment will now check "readiness level" before complying with orders.
    - Decoupling of speed from keyboard. Lots of work done on dial detection with Unity GUI.
    - Threw out Unity GUI. Completed dial with in-scene assets.
    - Updated camera to move with player and added zoom.

    Future Plans
    Torpedoes. Torpedo limits. Torpedo compartment ready state.
    On-screen sonar, complete with loss of signal behavior and vaguely directional audio.
    Damage, damage control.
    Enemy and self visibility + way to communicate this to player.
    Enemy AI, including different types of ships (currently at least 10 different types planned with varying speeds, inertia, hit likelihood and behaviors).
    Ability to target, shoot at, and destroy ships (this one's huge).
    Depth charges.
    Sound.
    Time of day lighting. Weather condition indicator.
    Attack mapping (another huge one, probably even bigger than the first).

    Wishlist
    Missions.
    Radio messages.
    Factions.
    More realistic crew with individual abilities and names.

    Things I thought about and rejected (for now)
    Manual aiming is probably the biggest thing. The UI requirements for manual aiming are way beyond my scope. You will have to perform a couple of "observations" to get accurate firing solutions, which will then be affected by crew skills and current conditions (boat and environment). This will then determine "aim" which may or may not be correct based on all those factors. Once fired, there will be the usual random dud/premature explosion chance, but the torpedo will run true and physics will determine whether there's a hit or not. Smiley
    « Last Edit: July 11, 2014, 06:55:44 PM by CodeSquares » Logged
    CodeSquares
    Level 0
    **


    View Profile WWW
    « Reply #2 on: July 11, 2014, 07:14:01 PM »

    Update 1

    Current screenshot. Camera zoom, nav dial and depth dial (new and not working yet) in evidence.



    Next task is to refactor the speed dial code. There really shouldn't be a separate script for "set dial to angle X". Right now the script is doing too much work translating set speed (range of -4 to 5) to an angle - that should be done in the nav script, and that way the reusable "set dial to angle X" script is well, reusable.

    On the other hand, I'm doing a maximum of 3 dials here. Tongue Reuse doesn't seem like it should be the highest priority...
    Logged
    CodeSquares
    Level 0
    **


    View Profile WWW
    « Reply #3 on: July 15, 2014, 08:40:05 AM »

    Mostly UI and design thoughts the past few days.

    - Added rotating dial to depth gauge.
    - Completed calculations to map rotation to depth and vice versa.
    - Refactored rotation code for re-use - same script now runs both dials and will most likely run a third with no changes needed (just pass in dial offset - i.e., dial dead space - and desired angle). While I was at it renamed the scripts from vague "navigation" to "speed" and "depth".
    - Realized the depth dial turns where clicked - actually what I want is for the depth gauge to show *real* current depth, and for there to be an extra indicator for "requested" depth. That means ... yay, more UI work. Smiley

    Next up, might take a break from gauges and work on torpedoes. On the other hand since I'm SO close to having all 3 done ... might just forge on through and wrap them up.

    As a complete aside, I thought of a way to add turrets that will track you when ships are alerted. Scope creep! Tongue
    Logged
    Jarkko Vallius
    Level 0
    **



    View Profile WWW
    « Reply #4 on: July 15, 2014, 10:51:24 AM »

    Silent Hunter 3 one of my favorites, watching this. Hand Joystick
    Logged

    CodeSquares
    Level 0
    **


    View Profile WWW
    « Reply #5 on: July 16, 2014, 10:15:20 AM »

    - Split the depth gauge into two behaviors.
    -- 1. Set a marker for desired depth when clicked.
    -- 2. Gauge reflects actual submarine depth.

    Tweaked the dial management code to be able to deal with onClick and arbitrary "set dial to" calls from elsewhere in the code. The directional gauge (compass) will need this too.

    Now I just need a different graphic for the marker and make sure both dial and marker are set to 0 at start of game, as right now (at start before player input) they're acting weirdly.

    I'll get a screenshot of this when I find/make a halfway decent marker graphic. Smiley
    Logged
    CodeSquares
    Level 0
    **


    View Profile WWW
    « Reply #6 on: July 25, 2014, 09:40:01 AM »

    Was on vacation for a bit and then work slammed with some horrible bugs that I'm still fighting with, so not much work done.

    I did however get the dual-dial working and pulled out the Coroutine handling out of Update() and into its own thing. Still getting something out of bounds when the actual depth hits set depth, but at least you can now successfully interrupt a dive or an ascent, so that's good. Smiley

    I will hunt down the out of bounds bug and move on to torps. Getting this one right took way longer than I hoped.
    Logged
    CodeSquares
    Level 0
    **


    View Profile WWW
    « Reply #7 on: July 27, 2014, 10:05:37 AM »

    Torpedoes, pre pre pre alpha state. :D



    Right now there's no timer, limit or collision (torpedo spam!) but I'm pleased I got this working in about an hour this morning. Beer!

    Oh yes, the out of bounds bug has been fixed too.

    Next, all the work needed for this to feel like actual torpedoes are being fired. Smiley
    Logged
    Connor
    Level 8
    ***


    Smooth talker, musician. Loves all things 70s.


    View Profile WWW
    « Reply #8 on: July 27, 2014, 05:58:04 PM »

    that title... i cant help but reply with PONG! Tongue
    sorry.
    i had to.
    lol.
    Logged

    Firearrow games
    www.firearrowgames.net

    blitzkampfer:
    https://forums.tigsource.com/index.php?topic=52009.msg1280646#msg1280646

    too bad eggybooms ents are actually men in paper mache suits and they NEED to be agile
    CodeSquares
    Level 0
    **


    View Profile WWW
    « Reply #9 on: August 20, 2014, 10:31:10 PM »

    Added torpedo compartment. You now need the compartment to be sufficiently manned for firing. In addition, 4 bow tubes and reload times are modeled - you can only fire 4 torpedoes before you're out. Reload time starts immediately right now, as "Silent Running" (when you can't reload due to noise) isn't modeled yet.

    Compartment also communicates current state to the UI. Like almost everything else this is just text now but the hooks are in.



    I need to test this more, add a total torpedo limit and hook up the aft torpedo tube as well (mostly copy paste from this unless I figure out a DRY-er way), then on to the next thing which will possibly be some sort of sonar implementation.
    Logged
    CodeSquares
    Level 0
    **


    View Profile WWW
    « Reply #10 on: September 17, 2014, 09:07:57 PM »

    Implemented a more or less working sonar, currently only auto-scanning around you. It appears only when underwater and reveals ships as long as it's pointed at them. Actual gameplay value - fading out contacts while they're not being followed, ability to "Lock" contacts down, ability to point sonar where you like - of this needs a ton of work, but pretty good start nevertheless.

    I'd love to get better graphics for it too but with my nonexistent skills that'll be last. I think I might devote some time to sound FX after this though, just to liven things up a little bit. Engine noise and sonar ping would be nice, at least.
    Logged
    Pages: [1]
    Print
    Jump to:  

    Theme orange-lt created by panic