add generic pagination from warsow.net forums