In this Unity tutorial we're going to look at how to allow the Player to gain points by killing enemies, and how to display the score on screen.
We'll cover the creation of scripts to keep track of the score and increase it when enemies are killed. Then we'll display the score using Text Mesh Pro and use Unity events to update the UI whenever the score is changed.
This is the fifteenth video in our series showing how to make a full top down 2D shooter game in Unity.
The playlist for this series can be found here
► • Unity 2D Top Down Shooter for Beginners
The project files are available to our patrons here:
► / 89775350
Want to follow along? This project is a good starting point
► / 88654003
The full Top Down Shooter Project is available to our patrons here
► / 75231350
The final script can be found here
► https://dotnetfiddle.net/CCn3IZ
Help support our work:
► Patreon: / ketragames
Follow us:
► Ketra Games: http://www.ketra-games.com
► Patreon: / ketragames
► Twitter: / ketragames
► Facebook: / ketragames
Introduction - 0:00
Creating a Script to Keep Track of the Score - 0:35
Creating a Script to Increase the Score When the Enemy Dies - 2:30
Displaying the Score in the UI Using Text Mesh Pro - 5:24
Summary - 8:44:38
Thumbnail Image by FreePik - https://www.freepik.com/free-vector/f...
#KetraGames #LearnUnity #UnityTutorials #UnityTips
Watch video How to Keep Score in Unity Using Unity Events and Text Mesh Pro online, duration hours minute second in high quality that is uploaded to the channel Ketra Games 25 September 2023. Share the link to the video on social media so that your subscribers and friends will also watch this video. This video clip has been viewed 5,791 times and liked it 128 visitors.