Topic: How do I disable default camera and use custom camera?
I have a custom camera I am trying to use. I have written this code but throws errors. I just need to disable the default camera for UFE 2 so that I can use my own. Here is the code I currently have:
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using FPLibrary;
using UFE3D;
public class CameraOverride : MonoBehaviour
{
public Camera splitScreenCam;
public Camera ufeCamera;
void Start()
{
UFE.OnGameBegin += OnGameBegin;
}
void OnGameBegin(CharacterInfo player1, CharacterInfo player2, StageOptions stage)
{
if (player1 != null && player2 != null)
ufeCamera.SetActive(false);
splitScreenCam.SetActive(true);
}
}