differentiate new/old Lua APIs

This commit is contained in:
Matthias Mailänder
2014-07-20 13:53:12 +02:00
parent ef5178407c
commit 7901c06e4c
4 changed files with 5 additions and 1 deletions

View File

@@ -15,6 +15,7 @@ using OpenRA.Traits;
namespace OpenRA.Mods.RA.Scripting
{
[Desc("Part of the new Lua API.")]
public class LuaScriptInfo : ITraitInfo, Requires<SpawnMapActorsInfo>
{
public readonly string[] Scripts = { };

View File

@@ -18,6 +18,7 @@ using OpenRA.Primitives;
namespace OpenRA.Mods.RA.Scripting
{
[Desc("Part of the legacy Lua API.")]
public sealed class LuaScriptContext : IDisposable
{
public Lua Lua { get; private set; }

View File

@@ -1,6 +1,6 @@
#region Copyright & License Information
/*
* Copyright 2007-2013 The OpenRA Developers (see AUTHORS)
* Copyright 2007-2014 The OpenRA Developers (see AUTHORS)
* This file is part of OpenRA, which is free software. It is made
* available to you under the terms of the GNU General Public License
* as published by the Free Software Foundation. For more information,
@@ -13,6 +13,7 @@ using OpenRA.Traits;
namespace OpenRA.Mods.RA.Scripting
{
[Desc("Part of the legacy Lua API.")]
public class LuaScriptEventsInfo : TraitInfo<LuaScriptEvents> { }
public class LuaScriptEvents : INotifyKilled, INotifyAddedToWorld, INotifyRemovedFromWorld,

View File

@@ -25,6 +25,7 @@ using WorldRenderer = OpenRA.Graphics.WorldRenderer;
namespace OpenRA.Mods.RA.Scripting
{
[Desc("Part of the legacy Lua API.")]
public class LuaScriptInterfaceInfo : ITraitInfo, Requires<SpawnMapActorsInfo>
{
public readonly string[] LuaScripts = { };