BuildableInfo GetBuildableInfo(string actorType)
{
if (!Player.World.Map.Rules.Actors.ContainsKey(actorType))
throw new LuaException("Actor of type {0} is invalid".F(actorType));
var ri = Player.World.Map.Rules.Actors[actorType];
var bi = ri.TraitInfoOrDefault<BuildableInfo>();
if (bi == null)
throw new LuaException("Actor of type {0} cannot be produced".F(actorType));
else
return bi;
}
}
}
}