- Fixed network synchro of vars, needs synctype testing.
This commit is contained in:
@@ -0,0 +1,22 @@
|
||||
using System;
|
||||
using System.Collections.Immutable;
|
||||
using System.Linq;
|
||||
using Barotrauma.LuaCs.Data;
|
||||
|
||||
namespace Barotrauma.LuaCs;
|
||||
|
||||
public sealed partial class ConfigService
|
||||
{
|
||||
public ImmutableArray<ISettingBase> GetDisplayableConfigs()
|
||||
{
|
||||
using var _ = _operationLock.AcquireReaderLock().ConfigureAwait(false).GetAwaiter().GetResult();
|
||||
IService.CheckDisposed(this);
|
||||
|
||||
return _settingsInstances.Values
|
||||
.Where(s => !s.IsDisposed)
|
||||
.Where(s => s.GetDisplayInfo().ShowInMenus)
|
||||
.Where(s => !GameMain.IsMultiplayer || s.GetConfigInfo().NetSync != NetSync.ServerAuthority)
|
||||
.Where(s => s.GetConfigInfo().EditableStates >= _infoProvider.CurrentRunState)
|
||||
.ToImmutableArray();
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user