How to get a variable from another script in Unity (the right way)

▸ Learn how to CODE in Unity: https://gamedevbeginner.com/how-to-co... Learn how to get a variable from another script in Unity, without making a mess of your project. 00:00 Intro 00:37 Creating a connection in the Inspector 02:06 Get Component 06:32 Connecting to different objects 09:09 Global variables 10:36 Global variables (using Singletons) 12:24 Global Variables (using Scriptable Object) 15:10 Outro You'll learn how to connect objects and scripts together using the Inspector, Get Component, static variables and Singletons and by using scriptable objects. Read my full article here: https://gamedevbeginner.com/how-to-ge... Ryan Hipple's Unite Austin talk:    • Unite Austin 2017 - Game Architecture with...   Outro music: New Year by Bad Snacks Image Attribution 3d cube icons created by Freepik - https://www.flaticon.com/free-icons/3... Page icons created by Icongeek26 - https://www.flaticon.com/free-icons/page sword icons"Sword icons created by Darius Dan - https://www.flaticon.com/free-icons/s... Unity icons created by Freepik - https://www.flaticon.com/free-icons/u...