@@ -33,25 +33,23 @@ namespace Orts.Common.Scripting
3333 [ CallOnThread ( "Loader" ) ]
3434 public class ScriptManager
3535 {
36- readonly Simulator Simulator ;
3736 readonly IDictionary < string , Assembly > Scripts = new Dictionary < string , Assembly > ( ) ;
3837 static readonly string [ ] ReferenceAssemblies = new [ ]
3938 {
40- typeof ( System . Object ) . GetTypeInfo ( ) . Assembly . Location ,
41- typeof ( System . Diagnostics . Debug ) . GetTypeInfo ( ) . Assembly . Location ,
42- typeof ( ORTS . Common . ElapsedTime ) . GetTypeInfo ( ) . Assembly . Location ,
43- typeof ( ORTS . Scripting . Api . Timer ) . GetTypeInfo ( ) . Assembly . Location ,
44- typeof ( System . Linq . Enumerable ) . GetTypeInfo ( ) . Assembly . Location ,
39+ typeof ( System . Object ) . Assembly . Location ,
40+ typeof ( System . Diagnostics . Debug ) . Assembly . Location ,
41+ typeof ( ORTS . Common . ElapsedTime ) . Assembly . Location ,
42+ typeof ( ORTS . Scripting . Api . Timer ) . Assembly . Location ,
43+ typeof ( System . Linq . Enumerable ) . Assembly . Location ,
4544 } ;
4645 static MetadataReference [ ] References = ReferenceAssemblies . Select ( r => MetadataReference . CreateFromFile ( r ) ) . ToArray ( ) ;
4746 static CSharpCompilationOptions CompilationOptions = new CSharpCompilationOptions (
4847 OutputKind . DynamicallyLinkedLibrary ,
4948 optimizationLevel : Debugger . IsAttached ? OptimizationLevel . Debug : OptimizationLevel . Release ) ;
5049
5150 [ CallOnThread ( "Loader" ) ]
52- internal ScriptManager ( Simulator simulator )
51+ internal ScriptManager ( )
5352 {
54- Simulator = simulator ;
5553 }
5654
5755 public object Load ( string [ ] pathArray , string name , string nameSpace = "ORTS.Scripting.Script" )
0 commit comments