You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
23 lines
501 B
C#
23 lines
501 B
C#
1 year ago
|
using System.Collections;
|
||
|
using System.Collections.Generic;
|
||
|
using UnityEngine;
|
||
|
using TMPro;
|
||
|
|
||
|
public class LookAtCamera : MonoBehaviour
|
||
|
{
|
||
|
// Start is called before the first frame update
|
||
|
public GameObject Ok;
|
||
|
void Start()
|
||
|
{
|
||
|
Ok.transform.LookAt(Camera.main.transform);
|
||
|
Ok.transform.Rotate(0, 180, 0);
|
||
|
}
|
||
|
|
||
|
// Update is called once per frame
|
||
|
void Update()
|
||
|
{
|
||
|
Ok.transform.LookAt(Camera.main.transform);
|
||
|
Ok.transform.Rotate(0, 180, 0);
|
||
|
}
|
||
|
}
|