updated onGround global variables