29 lines
620 B
C#
29 lines
620 B
C#
using System;
|
|
using UnityEngine;
|
|
|
|
public interface ILockOnTarget {
|
|
public float lockonTargetRadius { set; }
|
|
|
|
Transform transform {get;}
|
|
GameObject gameObject{ get; }
|
|
|
|
public Vector3 GetReticlePosition(){
|
|
Bounds objectBounds = gameObject.GetComponent<Renderer>().bounds;
|
|
|
|
Vector3 reticlePosition = new Vector3(transform.position.x, transform.position.y + objectBounds.size.y, transform.position.z);
|
|
|
|
return reticlePosition;
|
|
}
|
|
}
|
|
|
|
public class PlayerCamera : MonoBehaviour{
|
|
void Start(){
|
|
|
|
}
|
|
|
|
// Update is called once per frame
|
|
void LateUpdate(){
|
|
|
|
}
|
|
}
|