public LuaTable GetLuaMap(Mission mission)
        {
            var args = LuaTable.CreateArray(new [] { mission.ToIngameX(X), 0, mission.ToIngameY(Y) });
            var map  = new Dictionary <object, object>
            {
                { "orderType", OrderType },
                { "args", args },
            };

            return(new LuaTable(map));
        }
		public override LuaTable GetLuaMap(Mission mission)
		{
			var map = new Dictionary<object, object>
				{
					{"category", "cylinder"},
					{"x", mission.ToIngameX(X)},
					{"y", mission.ToIngameY(Y)},
					{"r", mission.ToIngameX(R)},
				};
			return new LuaTable(map);
		}
		public override LuaTable GetLuaMap(Mission mission)
		{
			var map = new Dictionary<object, object>
				{
					{"category", "rectangle"},
					{"x", mission.ToIngameX(X)},
					{"y", mission.ToIngameY(Y)},
					{"width", mission.ToIngameX(width)},
					{"height", mission.ToIngameX(height)},
				};
			return new LuaTable(map);
		}
Exemple #4
0
        public override LuaTable GetLuaMap(Mission mission)
        {
            var map = new Dictionary <object, object>
            {
                { "category", "cylinder" },
                { "x", mission.ToIngameX(X) },
                { "y", mission.ToIngameY(Y) },
                { "r", mission.ToIngameX(R) },
            };

            return(new LuaTable(map));
        }
        public override LuaTable GetLuaMap(Mission mission)
        {
            var map = new Dictionary <object, object>
            {
                { "category", "rectangle" },
                { "x", mission.ToIngameX(X) },
                { "y", mission.ToIngameY(Y) },
                { "width", mission.ToIngameX(width) },
                { "height", mission.ToIngameX(height) },
            };

            return(new LuaTable(map));
        }
		public LuaTable GetLuaMap(Mission mission)
		{
			var map = new Dictionary<object, object>
				{
					{"orderType", OrderType},
				};
            if (!String.IsNullOrEmpty(Group)) map.Add("target", Group);
            else
            {
                var args = LuaTable.CreateArray(new[] { mission.ToIngameX(X), 0, mission.ToIngameY(Y) });
                map.Add("args", args);
            }
			return new LuaTable(map);
		}
        public LuaTable GetLuaMap(Mission mission)
        {
            var map = new Dictionary <object, object>
            {
                { "unitDefName", UnitDef.Name },
                { "x", Math.Floor(mission.ToIngameX(X)) },
                { "y", Math.Floor(mission.ToIngameY(Y)) },
                { "player", mission.Players.IndexOf(Player) },
                { "groups", LuaTable.CreateSet(Groups) },
                { "heading", Heading },
                { "isGhost", isGhost },
            };

            return(new LuaTable(map));
        }
        public LuaTable GetLuaMap(Mission mission)
        {
            var map = new Dictionary <object, object>
            {
                { "orderType", OrderType },
            };

            if (!String.IsNullOrEmpty(Group))
            {
                map.Add("target", Group);
            }
            else
            {
                var args = LuaTable.CreateArray(new[] { mission.ToIngameX(X), 0, mission.ToIngameY(Y) });
                map.Add("args", args);
            }
            return(new LuaTable(map));
        }
		public LuaTable GetLuaMap(Mission mission)
		{
			var map = new Dictionary<object, object>
			          {
			          	{ "unitDefName", UnitDef.Name },
			          	{ "x", Math.Floor(mission.ToIngameX(X)) },
			          	{ "y", Math.Floor(mission.ToIngameY(Y)) },
			          	{ "player", mission.Players.IndexOf(Player) },
			          	{ "groups", LuaTable.CreateSet(Groups) },
			          	{ "heading", Heading },
						{ "isGhost", isGhost},
			          };
			return new LuaTable(map);
		}