This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System.Collections.Generic; | |
using System.Linq; | |
using UnityEngine; | |
using Random = System.Random; | |
// This source code is used for the video. It obviously requires heavy alterations to be used in a real project. | |
public class ExampleGrid : MonoBehaviour | |
{ | |
[SerializeField] private Vector2Int _size; | |
[SerializeField] private Vector2 _gap; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using UnityEngine; | |
using TMPro; | |
public class BuildDisplayer : MonoBehaviour | |
{ | |
[SerializeField] private TMP_Text _textBuildNumber; | |
private void Awake() | |
{ | |
if (_textBuildNumber.TryGetComponent(out TMP_Text textBuildLabel)) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using UnityEngine; | |
public class FlyCamera : MonoBehaviour | |
{ | |
private float _mainSpeed = 100.0f; | |
private float _shiftAdd = 250.0f; | |
private float _maxShift = 1000.0f; | |
private float _camSens = 0.25f; | |
private float _totalRun = 1.0f; | |
private Vector3 _lastMouse = new (255, 255, 255); |