File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -105,7 +105,7 @@ public static void OnPluginTick()
105105 continue ;
106106 }
107107 }
108-
108+
109109 menu . GetPlayer ( ) . PrintToCenterHtml ( menu . GetText ( ) , 1 ) ;
110110 }
111111 }
Original file line number Diff line number Diff line change @@ -31,7 +31,7 @@ public class PluginConfig : BasePluginConfig
3131public class MenuManagerCore : BasePlugin , IPluginConfig < PluginConfig >
3232{
3333 public override string ModuleName => "MenuManager [Core]" ;
34- public override string ModuleVersion => "1.4" ;
34+ public override string ModuleVersion => "1.4.1 " ;
3535 public override string ModuleAuthor => "Nick Fox" ;
3636 public override string ModuleDescription => "All menus interacts in one core" ;
3737 public PluginConfig Config { get ; set ; }
Original file line number Diff line number Diff line change @@ -345,6 +345,8 @@ internal static void NotHooked(int i)
345345 {
346346 hooked = false ;
347347 Control . GetPlugin ( ) . Logger . LogInformation ( $ "Metamod MenusApi found but couldnt hook it! [Code: { i } ]") ;
348+ Control . GetPlugin ( ) . Config . UseMetamodMenu = false ;
349+ Control . GetPlugin ( ) . Config . UseMetamodMenuReplace = false ;
348350 }
349351
350352 private static void AddCallbackInfo ( int slot , MM_MenuCallbackFunc func )
@@ -390,13 +392,15 @@ internal static void PassMenuToMM(CCSPlayerController player, MenuInstance menu)
390392 if ( iItem < 7 )
391393 {
392394 var index = int . Parse ( szBack ) ;
395+ if ( menu . PostSelectAction != PostSelectAction . Nothing )
396+ ClosePlayerMenu ( iSlot ) ;
393397 menu . MenuOptions [ index ] . OnSelect ( player , menu . MenuOptions [ index ] ) ;
394398
395399
396400 switch ( menu . PostSelectAction )
397401 {
398402 case PostSelectAction . Close : ClosePlayerMenu ( iSlot ) ; Control . CloseMenu ( Utilities . GetPlayerFromSlot ( iSlot ) ) ; break ;
399- case PostSelectAction . Reset : ClosePlayerMenu ( iSlot ) ; if ( menu . ResetAction != null ) Server . NextFrameAsync ( ( ) => menu . ResetAction ( player ) ) ; break ;
403+ case PostSelectAction . Reset : if ( menu . ResetAction != null && ! Control . HasOpenedMenu ( player ) ) Server . NextFrameAsync ( ( ) => menu . ResetAction ( player ) ) ; break ;
400404 }
401405
402406 }
You can’t perform that action at this time.
0 commit comments