I want a respawn script where when a player collide a object it will respawn its current position but i faced some problem here is my script
using UnityEngine;
using System.Collections;
public class Testrun : MonoBehaviour {
void OnTriggerEnter(Collider other)
{
transform.position = Vector3(1019.62f, 80.53411f, -801.2841f);
}
}
and the problem is
error CS0119: Expression denotes a type', where a
variable’, value' or
method group’ was expected
i am new in scripting pls help me what i will do