Fix opening the scriptwrapper.lua file as read-write
This commit is contained in:
@@ -160,7 +160,7 @@ namespace OpenRA.Scripting
|
||||
.ToArray();
|
||||
|
||||
runtime.Globals["GameDir"] = Platform.GameDir;
|
||||
runtime.DoBuffer(File.Open(Platform.ResolvePath(".", "lua", "scriptwrapper.lua"), FileMode.Open).ReadAllText(), "scriptwrapper.lua").Dispose();
|
||||
runtime.DoBuffer(File.Open(Platform.ResolvePath(".", "lua", "scriptwrapper.lua"), FileMode.Open, FileAccess.Read).ReadAllText(), "scriptwrapper.lua").Dispose();
|
||||
tick = (LuaFunction)runtime.Globals["Tick"];
|
||||
|
||||
// Register globals
|
||||
|
||||
Reference in New Issue
Block a user