Exemplo n.º 1
0
        protected override void OnReading(Newtonsoft.Json.Linq.JObject json)
        {
            cost         = json.GetSafeDoubleValue("cost");
            success      = json.GetSafeDoubleValue("success");
            description2 = json.GetSafeStringValue("description2");
            range        = json.GetSafeStringValue("range");
            forward      = json.GetSafeStringValue("forward");
            if (json.GetValue("trigger") != null)
            {
                trigger = bool.Parse(json.GetValue("trigger").ToString());
            }
            else
            {
                trigger = false;
            }

            animation = json.GetSafeDoubleValue("animation");
            deadable  = json.GetSafeStringValue("deadable");
            base.OnReading(json);
        }
Exemplo n.º 2
0
 protected override void OnReading(Newtonsoft.Json.Linq.JObject json)
 {
     forward = json.GetSafeStringValue("forward");
     range   = json.GetSafeStringValue("range");
     if (json.GetValue("removeable") != null)
     {
         removeable = bool.Parse(json.GetValue("removeable").ToString());
     }
     else
     {
         removeable = false;
     }
     deadable  = json.GetSafeStringValue("deadable");
     animation = json.GetSafeDoubleValue("animation");
     //prop = json.GetSafeStringValue("prop");
     //this.equipProp = new EquipmentProp();
     //this.equipProp.ReadFromJson(prop);
     base.OnReading(json);
 }