Castles somewhat work now (need to check for some special cases)