fix not retrieving after first time

This commit is contained in:
Mister_Nebula 2021-07-24 21:29:19 +01:00
parent 1e4c0048c6
commit 8505b3c867

View File

@ -8,7 +8,6 @@ namespace QSB.Tools.ProbeLauncherTool.WorldObjects
{ {
class QSBProbeLauncher : WorldObject<ProbeLauncher> class QSBProbeLauncher : WorldObject<ProbeLauncher>
{ {
private bool _isRetrieving;
private float _probeRetrievalLength; private float _probeRetrievalLength;
private GameObject _preLaunchProbeProxy; private GameObject _preLaunchProbeProxy;
private ProbeLauncherEffects _effects; private ProbeLauncherEffects _effects;
@ -27,10 +26,6 @@ namespace QSB.Tools.ProbeLauncherTool.WorldObjects
public void RetrieveProbe(bool playEffects) public void RetrieveProbe(bool playEffects)
{ {
DebugLog.DebugWrite($"{ObjectId} ({AttachedObject.name}) RETRIEVE"); DebugLog.DebugWrite($"{ObjectId} ({AttachedObject.name}) RETRIEVE");
if (_isRetrieving)
{
return;
}
_preLaunchProbeProxy.SetActive(true); _preLaunchProbeProxy.SetActive(true);
if (playEffects) if (playEffects)
@ -38,7 +33,6 @@ namespace QSB.Tools.ProbeLauncherTool.WorldObjects
_effects.PlayRetrievalClip(); _effects.PlayRetrievalClip();
_probeRetrievalEffect.WarpObjectIn(_probeRetrievalLength); _probeRetrievalEffect.WarpObjectIn(_probeRetrievalLength);
} }
_isRetrieving = true;
} }
} }
} }