Skip to content

Commit

Permalink
Merge pull request #632 from misternebula/dev
Browse files Browse the repository at this point in the history
0.28.3
  • Loading branch information
misternebula authored Jun 25, 2023
2 parents 4bd6524 + ed2b3e4 commit a1fcbd3
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 4 deletions.
2 changes: 1 addition & 1 deletion QSB/PoolSync/CustomNomaiRemoteCamera.cs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ namespace QSB.PoolSync;

internal class CustomNomaiRemoteCamera : MonoBehaviour
{
private OWCamera _camera;
public OWCamera _camera;
private AudioListener _audioListener;
private NomaiViewerImageEffect _viewerImageEffect;
private CustomNomaiRemoteCameraPlatform _owningPlatform;
Expand Down
13 changes: 11 additions & 2 deletions QSB/PoolSync/CustomNomaiRemoteCameraPlatform.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
using QSB.Utility;
using System.Collections.Generic;
using System.Linq;
using System.Reflection;
using UnityEngine;

namespace QSB.PoolSync;
Expand Down Expand Up @@ -516,8 +517,16 @@ private void SwitchToRemoteCamera()

private void SwitchToPlayerCamera()
{
// does nothing except run CCU's prefix
_oldPlatform.SwitchToPlayerCamera();
if (QSBCore.Helper.Interaction.ModExists("xen.CommonCameraUtility"))
{
// this is a really fucking dumb fix, but i cannot be
// bothered to rewrite this class to make this work better
var ccuAssembly = QSBCore.Helper.Interaction.TryGetMod("xen.CommonCameraUtility").GetType().Assembly;
var utilClass = ccuAssembly.GetType("CommonCameraUtil.CommonCameraUtil");
var instance = utilClass.GetField("Instance", BindingFlags.Public | BindingFlags.Static).GetValue(null);
var removeCameraMethod = utilClass.GetMethod("RemoveCamera", BindingFlags.Public | BindingFlags.Instance);
removeCameraMethod.Invoke(instance, new object[] { _slavePlatform._ownedCamera._camera });
}

if (_slavePlatform._visualSector != null)
{
Expand Down
2 changes: 1 addition & 1 deletion QSB/manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
"body": "- Disable *all* other mods. (Can heavily affect performance)\n- Make sure you are not running any other network-intensive applications."
},
"uniqueName": "Raicuparta.QuantumSpaceBuddies",
"version": "0.28.2",
"version": "0.28.3",
"owmlVersion": "2.9.0",
"dependencies": [ "_nebula.MenuFramework", "JohnCorby.VanillaFix" ],
"pathsToPreserve": [ "debugsettings.json" ],
Expand Down

0 comments on commit a1fcbd3

Please sign in to comment.