Beispiel #1
0
        public static JsonObject serialize(AlphaFeature feature)
        {
            JsonObject obj = new JsonObject(JsonObject.JsonType.OBJECT);

            obj["alphaRate"] = feature.value;
            return(obj);
        }
Beispiel #2
0
        public override ParticleFeature create(JsonObject initData)
        {
            float val = 0f;

            if (initData["alphaRate"] != null)
            {
                val = (float)initData["alphaRate"];
            }
            AlphaFeature lf = new AlphaFeature(val);

            return(lf);
        }