mirror of
http://47.107.252.169:3000/Roguelite-Game-Developing-Team/Gen_Hack-and-Slash-Roguelite.git
synced 2025-11-20 06:47:14 +08:00
Co-authored-by: m0_75251201 <m0_75251201@noreply.gitcode.com> Reviewed-on: http://47.107.252.169:3000/Roguelite-Game-Developing-Team/Gen_Hack-and-Slash-Roguelite/pulls/60
25 lines
523 B
C#
25 lines
523 B
C#
using System;
|
|
using Base;
|
|
using UnityEngine;
|
|
|
|
namespace CameraControl
|
|
{
|
|
public class MiniMapCamera : MonoBehaviour, ITick
|
|
{
|
|
private void OnEnable()
|
|
{
|
|
Clock.AddTick(this);
|
|
}
|
|
|
|
private void OnDisable()
|
|
{
|
|
Clock.RemoveTick(this);
|
|
}
|
|
|
|
public void Tick()
|
|
{
|
|
if (Program.Instance.FocusedEntity)
|
|
transform.position = Program.Instance.FocusedEntity.transform.position + new Vector3(0, 0, -10);
|
|
}
|
|
}
|
|
} |