Fixed bugs with overlapping