Fixed bug in tryMoveTo
Fixed bug in tryMoveTo