Don’t rebuild the actor bindings every query.
This commit is contained in:
@@ -265,7 +265,8 @@ namespace OpenRA
|
||||
Lazy<ScriptActorInterface> luaInterface;
|
||||
public void OnScriptBind(ScriptContext context)
|
||||
{
|
||||
luaInterface = Exts.Lazy(() => new ScriptActorInterface(context, this));
|
||||
if (luaInterface == null)
|
||||
luaInterface = Exts.Lazy(() => new ScriptActorInterface(context, this));
|
||||
}
|
||||
|
||||
public LuaValue this[LuaRuntime runtime, LuaValue keyValue]
|
||||
|
||||
Reference in New Issue
Block a user