@@ -36,7 +36,10 @@ internal void Execute()
3636
3737 if ( null == msg )
3838 {
39- msg = this . CheckModuleManagerConflict112 ( ) ;
39+ int version = Versioning . version_major * 100 + Versioning . version_minor ; ;
40+ msg = version >= 108 ? this . CheckModuleManagerConflict108 ( )
41+ : this . CheckModuleManagerConflict ( )
42+ ;
4043 if ( null != msg && ! Globals . Instance . IsValid )
4144 {
4245 KSPe . UI . OptionDialogBox . Option [ ] options = new KSPe . UI . OptionDialogBox . Option [ ]
@@ -164,11 +167,26 @@ private string CheckModuleManagerDoppelganger18()
164167 private static readonly string GAMEDATAMMDLL = SIO . Path . Combine ( "GameData" , MYFORK_FILENAME ) ;
165168 static readonly string DASHMMDLL = GAMEDATAMMDLL . Replace ( "GameData" , "" ) ;
166169 static readonly string FULLMMPATH = SIO . Path . Combine ( GAMEDATA , MYFORK_FILENAME ) ;
167- private string CheckModuleManagerConflict112 ( )
170+ 171+ private string CheckModuleManagerConflict ( )
172+ {
173+ IEnumerable < System . Reflection . Assembly > loaded = SanityLib . FetchAssembliesByName ( ASSEMBLY_NAME ) ;
174+ #if DEBUG
175+ Log . dbg ( "CheckModuleManagerConflict" ) ;
176+ foreach ( System . Reflection . Assembly a in loaded )
177+ Log . dbg ( "{0} :: {1}" , a . FullName , a . Location ) ;
178+ #endif
179+ if ( loaded . Count ( ) > 1 )
180+ foreach ( System . Reflection . Assembly asm in loaded ) if ( this . IsMyFork ( new SIO . FileInfo ( asm . Location ) ) )
181+ return ErrorMessage . Conflict . ERR_MSG ;
182+ return null ;
183+ }
184+ 185+ private string CheckModuleManagerConflict108 ( )
168186 {
169187 IEnumerable < System . Reflection . Assembly > loaded = SanityLib . FetchAssembliesByName ( ASSEMBLY_NAME ) ;
170188#if DEBUG
171- Log . dbg ( "CheckModuleManager112 " ) ;
189+ Log . dbg ( "CheckModuleManagerConflict108 " ) ;
172190 foreach ( System . Reflection . Assembly a in loaded )
173191 Log . dbg ( "{0} :: {1}" , a . FullName , a . Location ) ;
174192#endif
0 commit comments