Keep only position as bud.parentPos instead of whole object. That then simplifies JSON serialization as you can save the objects as they are