public static GetProperties_properties AllFields()
        {
            var items = Enum.GetValues(typeof(Property.Name));
            var list  = new GetProperties_properties();

            list.AddRange(items.Cast <Property.Name>());
            return(list);
        }
Beispiel #2
0
        /// <summary>
        /// Retrieves the values of the given properties
        /// </summary>
        public async Task <Value> GetProperties(int playerid = 0, GetProperties_properties properties = null)
        {
            var jArgs = new JObject();

            if (playerid != null)
            {
                var jpropplayerid = JToken.FromObject(playerid, _client.Serializer);
                jArgs.Add(new JProperty("playerid", jpropplayerid));
            }
            if (properties != null)
            {
                var jpropproperties = JToken.FromObject(properties, _client.Serializer);
                jArgs.Add(new JProperty("properties", jpropproperties));
            }
            return(await _client.GetData <Value>("Player.GetProperties", jArgs));
        }