Set new rotation
Source
@override
void set rotation(Vector2 rotation)
{
super.rotation = rotation;
// Different chair rotations -> different collision extents
if(rotation.y.abs() > 0.5)
{
if(rotation.y < 0.0)
this.scale = new Vector2(78.0, 96.0);
else
this.scale = new Vector2(66.0, 72.0);
}
else
{
this.scale = new Vector2(66.0, 96.0);
}
}