@@ -26,19 +26,18 @@ protected override void Load()
2626
2727 #region Functions
2828 public static int GetWorkshopCount ( ) =>
29- ( String . Join ( "," , Provider . serverWorkshopFileIDs . Select ( x => x . ToString ( ) ) . ToArray ( ) ) . Length - 1 ) / 120 + 1 ;
29+ ( String . Join ( "," , Provider . getServerWorkshopFileIDs ( ) . Select ( x => x . ToString ( ) ) . ToArray ( ) ) . Length - 1 ) / 120 + 1 ;
3030
3131 public static int GetConfigurationCount ( ) =>
3232 ( String . Join ( "," , typeof ( ModeConfigData ) . GetFields ( )
33- . SelectMany ( x => x . GetValue ( Provider . modeConfigData ) . GetType ( ) . GetFields ( ) . Select ( y => y . GetValue ( x . GetValue ( Provider . modeConfigData ) ) ) )
33+ . SelectMany ( x => x . FieldType . GetFields ( ) . Select ( y => y . GetValue ( x . GetValue ( Provider . modeConfigData ) ) ) )
3434 . Select ( x => x is bool v ? v ? "T" : "F" : ( String . Empty + x ) ) . ToArray ( ) ) . Length - 1 ) / 120 + 1 ;
3535
36-
3736 public void OnPostLevelLoaded ( int xd ) => ModifyLobbyInfo ( ) ;
3837
3938 private void ModifyLobbyInfo ( )
4039 {
41- bool workshop = Provider . serverWorkshopFileIDs . Count > 0 ;
40+ bool workshop = Provider . getServerWorkshopFileIDs ( ) . Count > 0 ;
4241
4342 #region Workshop
4443 if ( Configuration . Instance . HideWorkshop )
@@ -140,7 +139,7 @@ private void ModifyLobbyInfo()
140139 SteamGameServer . SetBotPlayerCount ( 1 ) ;
141140 if ( ! Configuration . Instance . HidePlugins && ! Configuration . Instance . MessPlugins )
142141 SteamGameServer . SetKeyValue ( "rocketplugins" , string . Join ( "," , R . Plugins . GetPlugins ( ) . Select ( p => p . Name ) . ToArray ( ) ) ) ;
143- string version = ModuleHook . modules . FirstOrDefault ( a => a . config . Name == "Rocket.Unturned" ) ? . config . Version ?? "0.0.0.69" ;
142+ string version = ModuleHook . modules . Find ( a => a . config . Name == "Rocket.Unturned" ) ? . config . Version ?? "0.0.0.69" ;
144143 SteamGameServer . SetKeyValue ( "rocket" , version ) ;
145144 }
146145 #endregion
0 commit comments