hello i need help, i created a touch screen for the mobile phone in unity 3d. Now I've encountered the problem that I keep getting this error message: "Assets\Scripts\TouchPlayer.cs(7,12): error CS0246: The type or namespace name 'InputRing' could not be found (are you missing a using directive or an assembly reference?)"
I don't know what to do or how to get rid of it
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class TouchPlayer : MonoBehaviour
{
public InputRing input;
public InputLook look;
public float moveSpeed = 5, rotSpeed = 4;
Rigidbody ri;
private void Start()
{
ri = GetComponent();
void Update()
{
transform.Rotate(new Vector3(0, look.dir.x * rotSpeed, 0));
ri.velocity = Vector3.zero;
Vector2 dir = input.dir;
if (dir.x != 0 || dir.y != 0) ri.AddRelativeForce(new Vector3(dir.x, 0, dir.y) * moveSpeed, ForceMode.Impulse);
else ri.velocity = Vector3.zero;
}
}
}
----------
----------
↧