Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

Space Game Starter Kit [Released]

Discussion in 'Assets and Asset Store' started by ArenMook, Oct 11, 2011.

  1. ArenMook

    ArenMook

    Joined:
    Oct 20, 2010
    Posts:
    1,902


    Play it here.

    Have you ever wanted to create a 3D space game, but weren't sure where to start?
    Well, here's how the Space Game Starter Kit can help your ideas come to life tonight:

    - NEW: NGUI+TNet-based version is available upon request.
    - NGUI-based version available upon request.
    - Multiplayer support out of the box
    - Controllable with keyboard/mouse as well as the XBox 360 controller
    - Very flexible and tweakable damage, power generation, and shielding systems
    - Plasma beams and heat-seeking missiles as weapon examples
    - Simple yet powerful UI system (no need for any additional UI package; optimized for Android/iOS)
    - Planet shader lets you create your own unique looking planets with a few clicks of a mouse
    - Fully tweakable ship parameters -- create anything from a slow, unwieldy cargo ship to a fast highly manuverable assault fighter
    - Asteroid shader automatically seamlessly textures rocks of all shapes and sizes (no UVs required!)
    - Real-time dynamic reflections on anything you like via a simple attachable script (Pro only)
    - Localized gravity example (space station)
    - Distortion shield effect
    - Control impairment on collision
    - Near miss detection
    - 3D HUD (no OnGUI used!)
    - Simple targeting indicators
    - Even runs on Android and iOS (with appropriately limited functionality)

    All of that in clean, easy to understand and well-optimized code.

    All feedback welcome :)
     
    Last edited: Dec 29, 2012
  2. Rajmahal

    Rajmahal

    Joined:
    Apr 20, 2011
    Posts:
    2,101
    This looks great ... on my to buy list!
     
  3. orrtcloud

    orrtcloud

    Joined:
    Aug 3, 2011
    Posts:
    45
    Looks great! What about skyboxes/domes? Does it support those? Is your webplayer version's skybox a normal texture or generated?
     
  4. ArenMook

    ArenMook

    Joined:
    Oct 20, 2010
    Posts:
    1,902
    It currently uses Unity's built-in skybox for simplicity's sake (which is far from ideal, I know). It uses a set of 6 regular textures. I actually have a procedurally generated star map using LibNoise, but it's not finished so I have chosen to exclude it until a future update.

    I would really appreciate some feedback in regards to the XBox 360 controls if anyone has a controller around. What feels natural to me may not feel the same to others... :-|

    Also, in case anyone is interested in taking a quick glance at how the UI is set up and configured:

     
  5. Rajmahal

    Rajmahal

    Joined:
    Apr 20, 2011
    Posts:
    2,101
    I tried the web player demo but for some reason the camera begins to shake after a few seconds. I'm using IE 8.0 and have the latest version of the web player installed.
     
  6. ArenMook

    ArenMook

    Joined:
    Oct 20, 2010
    Posts:
    1,902
    I'm guessing it's that odd issue I see with Unity sometimes. Shutting down Unity usually helps (is it running in the background?). If not, try this link: http://www.tasharen.com/sg/index2.html -- the only difference between this and the original is the smooth camera follow script is partially disabled.
     
  7. Rajmahal

    Rajmahal

    Joined:
    Apr 20, 2011
    Posts:
    2,101
    Strange ... for some reason it's still happening with the new link and with Unity switched off. As soon as I press a key to move the ship or use the right mouse button, the whole screen begins to shake and the ship barely responds to input. It may be this computer that I'm using ... I'll try again on my home laptop when I'm home from work.

    What type of documentation do you provide with it? Is there a walkthrough document or is it all in code comments?
     
  8. ArenMook

    ArenMook

    Joined:
    Oct 20, 2010
    Posts:
    1,902
    That's odd, can't say I've seen that happening and I've tested it on several PCs, macs, and even an android phone. It almost sounds like the rumble effect gets turned on, but that should only happen if you collide with something. Are you trying multiplayer? Currently all players spawn in the same location, which can cause issues if they don't move (note to self: randomize that). What are the specs of your machine? As for documentation, I've commented the code where I believed it was necessary, but most of it is pretty clean and straightforward. If anyone has any questions, I'm able to answer them pretty much any time, unless I'm asleep. :)
     
  9. Rajmahal

    Rajmahal

    Joined:
    Apr 20, 2011
    Posts:
    2,101
    Sounds good. It does seem like the rumble effect since the screen seems to rotate a few few degrees and then rotates back in the opposite direction a few degrees and so on. I am trying multiplayer so perhaps that's the issue.

    The machine I'm using is my work laptop ... a dual core Intel CPU running Win XP and with 2 gigs of ram. I'm pretty sure my next game will be a space shooter so will pick this up as my starting point as it has multiplayer worked, which is still a big mystery area for me at the moment.
     
  10. ArenMook

    ArenMook

    Joined:
    Oct 20, 2010
    Posts:
    1,902
  11. g00niebird

    g00niebird

    Joined:
    Jul 24, 2010
    Posts:
    281
    I'm getting the rumble thing on both links. No Unity on this machine (crappy Dell at work), so that's not the reason.

    Also, if I may suggest enabling going fullscreen. Otherwise, your webplayer barely fits on my screen.
     
  12. ArenMook

    ArenMook

    Joined:
    Oct 20, 2010
    Posts:
    1,902
    Odd. I'll see if I can get a hold of an XP machine and try it there.
     
  13. Rajmahal

    Rajmahal

    Joined:
    Apr 20, 2011
    Posts:
    2,101
    Tried the new link but I get the same result.
     
  14. ArenMook

    ArenMook

    Joined:
    Oct 20, 2010
    Posts:
    1,902
    I think I managed to reproduce the problem on my end. The physics updates currently happen 100 times per second. If I change that back to 50 times per second (Unity's default), I get jitterness. I'll try to figure out why this happens and fix it.
     
  15. RandAlThor

    RandAlThor

    Joined:
    Dec 2, 2007
    Posts:
    1,293
    Is there something to shoot at and with?
    Are there an ios control (joystick or buttons) inside?
     
  16. ArenMook

    ArenMook

    Joined:
    Oct 20, 2010
    Posts:
    1,902
    Not yet. I'll most likely add some rockets this weekend just for the fun of it though. Each game has their own approach to how they want to handle combat, so I've chosen to omit the damage and combat mechanics from the toolkit... but if there is enough interest, I can certainly add it.

    The control on iOS/Android is touch-based in this version, and there are no visible widgets. With the next update there will be, but it's a bit limited compared to its PC and 360 counterparts (no maneuvering thrusters).
     
  17. Rajmahal

    Rajmahal

    Joined:
    Apr 20, 2011
    Posts:
    2,101
    I tried it last night at hom one my windows 7 computer and it worked fine. I wonder if it's either an XP thing or perhaps because I was connecting via a VPN on my work laptop?
     
  18. ArenMook

    ArenMook

    Joined:
    Oct 20, 2010
    Posts:
    1,902
    I updated the build last night with a fix. :) The update has also been submitted to the asset store, so should be fixed in version 1.4.
     
  19. ArenMook

    ArenMook

    Joined:
    Oct 20, 2010
    Posts:
    1,902
    Oh yeah, forgot to mention... I've added proper iOS and Android controls as well:

    - Hold the top left corner to accelerate, bottom left corner to slow down.
    - Drag from the center of the screen to steer.
    - Left side of the screen to roll left, right side of the screen to roll right.

    It still feels a bit awkward to me and I'm open to suggestions on how to make it better (accelerometer perhaps?).
     
  20. Rajmahal

    Rajmahal

    Joined:
    Apr 20, 2011
    Posts:
    2,101
    Sounds great ... missiles or lasers would be a great addition as well.

    I tried the latest link and now only the ship shakes while the rest of the screen is fine. That's on my XP computer with 2 gigs ram while on my home computer (Win 7 with 8 gigs Ram) worked fine.

    I just switched off my VPN and connected directly on the work computer but that still gives the same shakiness to the ship.
     
  21. ArenMook

    ArenMook

    Joined:
    Oct 20, 2010
    Posts:
    1,902
    Does the shakiness begin when you try to roll the ship?
     
  22. Rajmahal

    Rajmahal

    Joined:
    Apr 20, 2011
    Posts:
    2,101
    Any kind of movement kicks it off ... that includes:

    - change of direction with Righ mouse button
    - rolls
    - acceleration
    - pitching left, right, up, down

    The ship shaking only stops when the I decelerate the ship and bring its movement to zero.
     
  23. ArenMook

    ArenMook

    Joined:
    Oct 20, 2010
    Posts:
    1,902
    Ok, thank you, I will try to figure out what may be causing this.
     
  24. ArenMook

    ArenMook

    Joined:
    Oct 20, 2010
    Posts:
    1,902
  25. Rajmahal

    Rajmahal

    Joined:
    Apr 20, 2011
    Posts:
    2,101
    Version 3 works quite well with only a little shake here or there ... looks like it was a performance issue with my work laptop.
     
  26. ArenMook

    ArenMook

    Joined:
    Oct 20, 2010
    Posts:
    1,902
    :) Thanks!
     
  27. junkyardog

    junkyardog

    Joined:
    Feb 20, 2009
    Posts:
    92
    OK OK you twisted my arm. I'll get it.

    Wasn't looking for this type of kit yet but looks interesting enough I'll check it out.
     
  28. ArenMook

    ArenMook

    Joined:
    Oct 20, 2010
    Posts:
    1,902
    If you need any assistance, explanation, or examples of how to use something, just post here or send me a PM. :)
     
  29. ArenMook

    ArenMook

    Joined:
    Oct 20, 2010
    Posts:
    1,902
    The update is now on the asset store:
    - Changed the way camera was following the ship, eliminating jitter.
    - Proper touch-based controls on iOS (ReadMe has the instructions).
    - Some other tweaks and fixes.

    The web player links have also been updated.
     
  30. Rajmahal

    Rajmahal

    Joined:
    Apr 20, 2011
    Posts:
    2,101
    Fantastic ... the jitter and shaking is completely gone in the latest link even on my work laptop. Great stuff.

    Will you be making an update on this for basic weapons?
     
  31. ArenMook

    ArenMook

    Joined:
    Oct 20, 2010
    Posts:
    1,902
    In a way, yes -- heat-seeking missiles that will create an explosion force when they hit the ship just for the fun of it. Next update should have them.
     
  32. Rajmahal

    Rajmahal

    Joined:
    Apr 20, 2011
    Posts:
    2,101
    Excellent ... will pick this up either later today or tomorrow when I'm home from work. Can't wait to start playing around with this.
     
  33. reissgrant

    reissgrant

    Joined:
    Aug 20, 2009
    Posts:
    726
    Looks very cool!
     
  34. psyclone

    psyclone

    Joined:
    Nov 17, 2009
    Posts:
    245
    Not bad... Work quite well... Just missing some documentation :) But that docent seem that unusual (even for my own stuff)..

    Cheers
     
  35. RandAlThor

    RandAlThor

    Joined:
    Dec 2, 2007
    Posts:
    1,293
    Is this in c#?
     
  36. ArenMook

    ArenMook

    Joined:
    Oct 20, 2010
    Posts:
    1,902
    Yup it's all in C#. I documented all the potentially confusing parts of the code and used proper function headers for intellisense, and some things (network manager for example) are commented extensively -- but if there is something else you'd like me to document better, just let me know. :)
     
  37. psyclone

    psyclone

    Joined:
    Nov 17, 2009
    Posts:
    245
    Ill let you know once I had a chance to dig into the code... was more thinking about the more code/scripting limited peeps.

    Some documentation around why certain cameras setup, and your intentions around there use.
     
  38. ArenMook

    ArenMook

    Joined:
    Oct 20, 2010
    Posts:
    1,902
    The rendering process is split up into 3 cameras.
    - Distant camera renders objects that are massive -- skybox and the planet.
    - Main camera follows the distant camera (clears the depth), and renders all regular objects (ships, asteroids, space station). This is also the camera with post-processing effects.
    - Last comes the 3D UI camera. It happens after the post-processing effects, so UI doesn't get affected.
     
  39. moctezumagames

    moctezumagames

    Joined:
    Jun 9, 2009
    Posts:
    395
    really nice ArenMook. I wonder how this runs in iOS devices, with the obvious things unable to run disabled.
     
  40. ArenMook

    ArenMook

    Joined:
    Oct 20, 2010
    Posts:
    1,902
    It runs fairly well on iOS and Android. I was getting 45+ FPS on an Android phone (with shadows and post-processing effects disabled), and there are some things that can be easily optimized -- both the ship and the space station are made out of several pieces (boxes), which will go down to 1 draw call each when replaced with a proper model. There was one remaining issue on the mobile devices that I haven't yet addressed -- the forcefield effect doesn't work so it needs to be replaced with a simplied shader.
     
  41. ArenMook

    ArenMook

    Joined:
    Oct 20, 2010
    Posts:
    1,902
    Update 1.7 has been submitted to the Asset Store:
    - Added heat-seeking missiles with all the relevant logic.
    - Added explosions for heat-seeking missiles.
    - Target reticles now actually do something, showing you what the heat-seeking missiles will lock on to when fired.
    - Added the ability to shoot missiles (Left mouse button, E, or 360 controller's 'A' button).
    - Some tweaks to the UI fixing some issues with input in complex multi-UI-viewport scenes.

    The web player link has been updated. Try it with a friend and see which one of you can dodge the missiles. :)

     
    Last edited: Oct 17, 2011
  42. ArenMook

    ArenMook

    Joined:
    Oct 20, 2010
    Posts:
    1,902
    The update has been approved and is now live.
     
  43. Maurice-Hoffman

    Maurice-Hoffman

    Joined:
    Jan 22, 2009
    Posts:
    182
    Hello I have bought the starter kit not yet because i like to see besides the missiles with i think are very cool , i need some laser guns.

    It now is a network version, will you make a version where i have a mission to destroy a certain amount of ships en static guns at space stations, before the next level starts.

    I like your support for the xbox 360 joypad
     
  44. ArenMook

    ArenMook

    Joined:
    Oct 20, 2010
    Posts:
    1,902
    I believe adding missions and goals is something those who purchase the kits should add themselves, as each one of us has different ideas as to what the game should be like in the end. :) If the game is already there, then it would be a game, not a starter kit -- and it would impose a certain way of thinking upon those that try it.

    As an example, in its current state, the kit can be used to create a space combat game where you fight other ships; or a racing game where you fly through checkpoints at high speed; or an exploration / resource gathering game... all very distinct games. The best thing I can do for those that use the kit is to make it generic enough to not be restricting, and let other people's imagination do the rest.

    That said, I might add an objective / mission system if I can make it generic enough, but in the near future I will be focusing on adding extensive documentation on how to make the most of the systems already in place.
     
  45. ArenMook

    ArenMook

    Joined:
    Oct 20, 2010
    Posts:
    1,902
    Update 1.8 has been submitted to the Asset Store. The web player link has been updated for your viewing pleasure. ;)

    Changes:
    - UIInput now brings up the keyboard on Android/iOS.
    - New ship model.
    - Lighting tweaks.
    - A few other tweaks.

     
  46. Deleted User

    Deleted User

    Guest

    Game is flickering when i shot missile or when i change direction of ship. I think i know the problem.
    Definitely something happens when your ( shader / particular ) starts to show vena from speed.
    ( but its weird cause in last update everything was okkei but at least its a head start for you )
     
  47. ArenMook

    ArenMook

    Joined:
    Oct 20, 2010
    Posts:
    1,902
    Hmm, thanks for the heads up. What do you mean "vena from speed" though?
     
  48. Rajmahal

    Rajmahal

    Joined:
    Apr 20, 2011
    Posts:
    2,101
    Looks much better with the new ship.
     
  49. MarkcusD

    MarkcusD

    Joined:
    Jul 12, 2011
    Posts:
    40
    Looks good for the next game I'm planning. I'll try the demo with the 360 controller.
     
  50. Deleted User

    Deleted User

    Guest

    Vena from speed its ummm the orange line that comes from engine and from rockets.
    That line is call Vena.
    Sorry for not re posting faster, i had to do a lot of work.