4X Space Game

The aim of this project is to produce a working basic 4X space game. Features will include:

  • Randomly generated galaxies with unique solar systems.
  • A basic UI and user controls.
  • Some predifined races with unique traits and play styles.
  • A customisation system for the races.
  • Random events.
  • A basic AI

More features could be added later depending on demand.

All Code for Each part can be found here (Paste Bin)

Or Downloaded at the bottom of each tutorial.

All the Project files can be found on GitHub

Galaxy and Solar System Creation

Part 1 Creating the Galaxy!

Part 2 Making the Stars Unique

Part 3 Setting Up Solar Systems

Part 4 Seeding the Galaxy

Part 5 Viewing Solar Systems

Tidy Up – Between Part 5 and 6

Part 6 Resetting the Galaxy

Camera Control

Part 7 Camera Control

Part 8 Camera Control 2

Part 9 Camera Control 3

Making Things Look Better

Part 10 Orbits 

Part 11 Star Selection Icon

Adding Spiral Galaxies

Part 12 Spiral Galaxies

Part 13 Spiral Galaxies 2

Part 14 Spiral Galaxies 3

Naming Stuff

Part 15 Naming the Stars

Part 16 Naming the Stars 2

Ships

Part 17 Building Ships

Part 18 Building Ships 2

Part 19 Building Ships 3

Bug Fix and Efficiency Saving

Part 20 Improving Efficiency

Resources

Part 21 Resources

Star Bases

Part 22 Star Bases 1

Part 23 Star Bases 2

Part 24 Star Bases 3

Part 25 Star Bases 4

Turn System

Part 26 Turn System

Part 27 Ship Production using Turns

Part 28 Ship Production using Turns 2

Part 29 Ship Production using Turns 3

Improving Resources

Part 30 Getting Resources from Planets

Part 31 Resource UI

Part 32 Resource Refunds – Coming Soon

Advertisements

5 Comments »

    • Hi vstdgmr, I would really like to do both turn based and real time but I do not have time to do both. The only real difference between real time and turn based is the code executes when a button is pressed in turn based and in real time code will be executed in update methods and trigger events. Hope this helps

      Tom

  1. Great tutorial series! Been using a lot of this info in my own project to build a galaxy map. Are you still continuing with these tutorials? I am curious to how you will handle path finding in order to move ships to a destination.

    Here is my current map built from using your methods and expanding it into my own project https://www.youtube.com/watch?v=jVVsnbtUGKA

    • I am continuing them :). Currently Releasing one per month, wish I could do more but struggle to find the time.

      That map looks amazing! I’m glad my tutorials helped. Are your stars using a shader or are they modeled like that?

  2. With a full time job, family, and house I fully understand the struggle for time. Great to hear the tutorial is still going, though, this will be a big help for tons of people!

    My stars are Particle Systems from the Space for Unity asset pack I picked up when the store was having a sale. They were meant for background stars but with a little modification they worked wonders on a small scale such as the map

    https://assetstore.unity.com/packages/tools/level-design/space-for-unity-space-scene-construction-kit-7095

    Looking forward to your new tutorial posts

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.