Two small bugfixes (#3534)

This commit is contained in:
Leon Friedrich
2022-11-26 18:03:38 +13:00
committed by GitHub
parent e418ab96b9
commit c5ebe2c252
2 changed files with 2 additions and 5 deletions

View File

@@ -91,10 +91,7 @@ namespace Robust.Client.GameObjects
var sequence = _stateMan.SystemMessageDispatched(msg);
EntityNetManager?.SendSystemNetworkMessage(msg, sequence);
if (!_stateMan.IsPredictionEnabled)
return;
DebugTools.Assert(_gameTiming.InPrediction && _gameTiming.IsFirstTimePredicted || _client.RunLevel != ClientRunLevel.Connected);
DebugTools.Assert(!_stateMan.IsPredictionEnabled || _gameTiming.InPrediction && _gameTiming.IsFirstTimePredicted || _client.RunLevel != ClientRunLevel.Connected);
var eventArgs = new EntitySessionEventArgs(localPlayer!.Session);
EventBus.RaiseEvent(EventSource.Local, msg);

View File

@@ -177,7 +177,7 @@ public abstract class SharedAudioSystem : EntitySystem
/// <param name="audioParams">Audio parameters to apply when playing the sound. Defaults to using the sound specifier's parameters</param>
public IPlayingAudioStream? PlayPvs(SoundSpecifier? sound, EntityUid uid, AudioParams? audioParams = null)
{
return sound == null ? null : PlayPvs(GetSound(sound), uid, audioParams);
return sound == null ? null : PlayPvs(GetSound(sound), uid, audioParams ?? sound.Params);
}
/// <summary>