public void OnLoad() { // Pick the Mesh from the first entity that has one. // (This will be either a heart or sword.) // TODO: Right now MeshManager.Load will always load in a new Mesh. // var (_, mesh) = Game.GetAll<Mesh>().First(); // Game.Set(Game.MainCamera, mesh); PipCamera = Game.Entities.New() .Set(Camera.Create3d( fieldOfView: 90.0F, clearColor: Color.Black, viewport: new(8, 8, 320, 180) )); }
public void OnUnload() { PipCamera.Delete(); PipCamera = default; }