implemented paging, kinda slow (mb thread it...?)