Added a callback update for inputs and animation handling.