order in pet.js and root.js