Take the cast vector from the raycast and instantiate your test prefab at that point.
Try something like this:
public GameObject cubeClone;
void SomeFunction(){
Instantiate(cubeClone, cast, transform.rotation);
}
↧