Edit 2: It has been confirmed that this also works for getting 9999 villagers, check the bottom of this post for the values.
Edit 3: Sky3DS+ users, DO NOT edit the save on the Sky's microSD, this is not the correct save, load the game and use a save dumper to get BD2colony0.sav to do this edit...