Fixed Sosa stacking bug and mage bug