Created
June 27, 2019 09:52
-
-
Save IshidaGames/4ecc5154e0c1ae6df6a8143aa065b51a to your computer and use it in GitHub Desktop.
This file contains 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; | |
using System.Collections.Generic; | |
using UnityEngine; | |
//UI使うときは忘れずに。 | |
using UnityEngine.UI; | |
public class HPBarDirection : MonoBehaviour | |
{ | |
public Canvas canvas; | |
void Update() | |
{ | |
//EnemyCanvasをMain Cameraに向かせる | |
canvas.transform.rotation = | |
Camera.main.transform.rotation; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment