Baike.dev
All toolsOnline toolsAI codingTrendingOpen sourceNewsSubmit
Log in
< Back to tools
U

UnityTutorials-RTS

> 编程语言
Open source

The code for my series of tutorials on how to make a real-time stategy (RTS) game in the well-know Unity game engine (with C# scripting)!

725 stars0 likes0 views
WebsiteGitHub

About

The code for my series of tutorials on how to make a real-time stategy (RTS) game in the well-know Unity game engine (with C# scripting)!

[Unity/C#] Making a RTS game

Mina Pêcheux • March 2021 - March 2022

This project is now UNMAINTAINED . But feel free to use it as a reference archive :)

⚠️⚠️ In particular, this series and the repo was made using Unity 2020+ and 2021+ - it is not (and probably won't ever be) compatible with the new Unity 6 core system, or the more recent rendering pipelines, sorry! ⚠️⚠️

Discover the series as an ebook and get bonus material on Gumroad!

This repository contains the code for my on-going series of tutorials on how to make a real-time strategy (RTS) game in the well-known game engine Unity! Throughout this series of tutorials, I explore C# scripting for games, GUI building, event systems, behavior trees, sound optimization...


To run this project, make sure you play it from the "Core" scene! ;)

→ For more info, see Tutorial #41

You can find the list of all tutorials on Medium, or right below:

Tutorial #1: Placing buildings

Tutorial #2: Adding a very basic UI

Tutorial #3: Setting up in-game resources

Interlude #1: Introducing an event system

Tutorial #4: Selecting units

Tutorial #5: Transforming our data into Scriptable Objects

Tutorial #6: Improving the UI

Tutorial #7: Polymorphism, take 2!

Tutorial #8: Boosting our selection feature

Tutorial #9: Implementing character units and skills

Tutorial #10: Moving the camera

Interlude #2: Refactoring the event system

Tutorial #11: Adding a day-and-night cycle

Tutorial #12: Moving Character Units

Tutorial #13: Adding a minimap and fog of war 1/3

Tutorial #14: Adding a minimap and fog of war 2/3

Tutorial #15: Adding a minimap and fog of war 3/3

Tutorial #16: Introducing a sound system 1/2

Tutorial #17: Introducing a sound system 2/2

Tutorial #18: Preparing our game parameters

Tutorial #19: Displaying our in-game settings!

Tutorial #20: Saving the player’s data properly

Tutorial #21: Adding players and unit ownership

Tutorial #22: Producing some resources with our buildings

Tutorial #23: Implementing behaviour trees for our units 1/3

Tutorial #24: Implementing behaviour trees for our units 2/3

Tutorial #25: Implementing behaviour trees for our units 3/3

Tutorial #26: Levelling up our units! 1/2

Tutorial #27: Levelling up our units! 2/2

Tutorial #28: Adding some shortcuts

Tutorial #29: Improving our players system

Tutorial #30: Refactoring our save/load system with binary serialisation 1/2

Tutorial #31: Refactoring our save/load system with binary serialisation 2/2

Tutorial #32: Creating a debug console

Tutorial #33: Using Unity’s terrain tools

Tutorial #34: Improving unit navigation & adding unit formations 1/2

Tutorial #35: Improving unit navigation & adding unit formations 2/2

Tutorial #36: Using workers to construct buildings 1/3

Tutorial #37: Using workers to construct buildings 2/3

Tutorial #38: Using workers to construct buildings 3/3

Tutorial #39: Boosting our game scene

Tutorial #40: Fixing our minimap

Tutorial #41: Preparing for a main menu...

Tutorial #42: Designing our main menu 1/2

Tutorial #43: Designing our main menu 2/2

Tutorial #44: Importing models & animating our characters 1/2

Tutorial #45: Importing models & animating our characters 2/2

Tutorial #46: Saving our game scene data...

Tutorial #47: ... and loading back our game scene data!

Interlude #3: Showing our updated minimaps in the menu

Tutorial #48: Various fixes, improvements and clean-ups

Tutorial #49: Optimisation tips & tricks

Interlude #4: Improving the healthbars

Tutorial #50: Implementing a technology tree 1/3

Tutorial #51: Implementing a technology tree 2/3

Tutorial #52: Implementing a technology tree 3/3

Article #53: Final words, thanks… and an ebook!

Known issues

About installing / upgrading

The project was written in Unity 2020.3. This implies that, when loading it up with different recent versions of Unity, you'll need to "upgrade" the project. This usually goes without a hitch, but there is for now 2 bugs that have been spotted by the followers and I:

  • incorrect lighting: upgrading to some Unity 2020+ might lead to some strange lighting of the scene (because of pipeline render defaults and lighting settings changes). To get a similar lighting to the original project, make sure that you remove all baked lighting data, that all your (directional) lights are set to "Realtime" and that you ignore the environment lighting.

    To do so, open the Window > Rendering > Lighting panel, go to the "Environment" tab, and set the "Intensity Multiplier" variable to 0 both in the Environment Lighting and Environment Reflections sections.

  • FOV shader bug (thanks to @Oarcinae): upgrading to Unity 2019.4 might lead to unexpected behaviour for the FOV shader (because of pipeline render defaults changes); to fix the issue, you can try modifying the AlphaProjection.shader and comment out the line: #pragma exclude_renderers d3d11 gles (still an open issue #2, any help is welcome )

Issues· 0 open

View all issuesOpen on GitHub

No open issues yet, or sync has not completed.

> Tags

C#gamegame-developmentgamesrts

No comments yet. Be the first to share.

> Details

PublishedAug 1, 2026
UpdatedSep 17, 2026
Category编程语言
PricingOpen source

> Related tools

T
TypeScript
JavaScript 的超集,为前端与全栈提供静态类型
P
Python
通用编程语言,广泛用于 Web、数据与 AI
G
Go
Google 推出的简洁高效系统语言