update: fixed a bug in checkIfInAir method