public override void WriteProperties(JsonObjectContract contract, JsonWriter writer, object value, Type objectType, JsonSerializerWriter internalWriter)
        {
            var instance = (UnityEngine.Collider)value;

            writer.WriteProperty("isTrigger", instance.isTrigger);
            writer.WriteProperty("contactOffset", instance.contactOffset);
            internalWriter.SerializeProperty(writer, "sharedMaterial", instance.sharedMaterial);
            internalWriter.SerializeObjectProperties(writer, value, contract, null, null, null, this.propertiesToIgnore.ToArray());
        }
 public override void WriteProperties(JsonObjectContract contract, JsonWriter writer, object value, Type objectType, JsonSerializerWriter internalWriter)
 {
     //var instance = (UnityEngine.Renderer)value;
     //WriteObjectProperties(writer, instance, internalWriter);
     internalWriter.SerializeObjectProperties(writer, value, contract, null, null, null, this.propertiesToIgnore.ToArray());
 }
Пример #3
0
 public override void WriteProperties(JsonObjectContract contract, JsonWriter writer, object value, Type objectType, JsonSerializerWriter internalWriter)
 {
     base.WriteProperties(contract, writer, value, objectType, internalWriter);
     internalWriter.SerializeObjectProperties(writer, value, contract, null, null, null, this.baseProperties.ToArray());
 }