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

Author Topic: Space Colony - multiplayer strategy project  (Read 3241 times)

0 Members and 1 Guest are viewing this topic.

MrOnlineCoder

  • Jr. Member
  • **
  • Posts: 87
    • View Profile
Space Colony - multiplayer strategy project
« on: February 11, 2018, 01:56:42 pm »
Hello. Me and my friend were developing one project - Space Colony, a multiplayer space turn-based strategy game. But, unfortunately, we do not have time to continue working on it. So, I decided to publish it's source code and assets.

Gameplay

Turn based strategy, up to 4-6 multiplayer players.
Each player owns a colony and can own some planets.

Planets contain useful resources - metal, oil and crystals, used to build different structures and objects. Each player has different ships, used to capture other planets.

Colony/player loses the game, if all their planets are captured by other colonies.

One gameplay aspect which we wanted to implement is motherships - special big ships, which are required to control other ships - so you, for e.g, make 10 small attacking ships and 1 mothership. Then you attach theese ships to the mothership, and by moving mothership you move your space fleet.

What we wanted to add:

  • Tech tree
  • Terra incognita (you only see a part of the map, which increases when you explore new areas)
  • Buildings on the planet
  • And, surely, epic space fights ! :)

Code structure

SFML is used for network, graphics, window, audio. Also I use PhysFS for loading resources from 1 zip file Resources.dat.

Game entry point is in Main.cpp, which just creates instance of Engine and then, it loads all resources, game states and starts the game by switching to IntroState.

GUIManager is responsible for GUI.

Game is the main game class, which just implements game logic. It is shared between client and server (I mean, like it is synced over network).

Initially, it was hardly inspired by Heroes of Might and Magic 3 and Starcraft


Code is avaliable at https://github.com/MrOnlineCoder/SpaceColony.

Working win32 release build is avaliable here (which also contains all assets, they are not included in the git repo): https://github.com/MrOnlineCoder/SpaceColony/releases/tag/v1.0

You can fork it, add pull requests, develop your own game based on it, shortly speaking, anything you want, but I'll be very happy if you include my name in credits :)

Third-party:

  • SFML by Laurent Gomila and contributors
  • PhysFS by Ryan C. Gordon
  • Some assets are downloaded from opengameart.org and belong to their respective owners

All music by Kevin MacLeod (incompetech.com), published under Creative Commons: By Attribution 3.0 License


« Last Edit: February 11, 2018, 02:03:26 pm by MrOnlineCoder »

FRex

  • Hero Member
  • *****
  • Posts: 1845
  • Back to C++ gamedev with SFML in May 2023
    • View Profile
    • Email
Re: Space Colony - multiplayer strategy project
« Reply #1 on: February 11, 2018, 02:19:00 pm »
If you're interested I've updated https://github.com/SFML/SFML/wiki/Source:-PhysicsFS-Input-Stream a few days ago to make it two files, non copyable and not include so much stuff.
Back to C++ gamedev with SFML in May 2023

MrOnlineCoder

  • Jr. Member
  • **
  • Posts: 87
    • View Profile
Re: Space Colony - multiplayer strategy project
« Reply #2 on: February 11, 2018, 02:31:44 pm »
Thanks for information, I'll take it into account.

Ah, also I forgot to credit you for useful PhysFSStream class.  ;)
« Last Edit: February 11, 2018, 02:44:37 pm by MrOnlineCoder »

FRex

  • Hero Member
  • *****
  • Posts: 1845
  • Back to C++ gamedev with SFML in May 2023
    • View Profile
    • Email
Re: Space Colony - multiplayer strategy project
« Reply #3 on: February 11, 2018, 02:53:28 pm »
It's simple, you don't need to.
Back to C++ gamedev with SFML in May 2023