Refactors, ints->longs, behaviors