Pin logic was added(not yet finished)