ADDED update function to tiles