find the client country

i want to stop certain country people for my gameplay how can i identify their country and stop them in connection