Fix custom radius option

This commit is contained in:
AngelJumbo 2022-10-20 16:39:09 -05:00
parent a69ce502d7
commit 3b2dd40b5a

View File

@ -189,7 +189,7 @@ int parse_options(int argc, char *argv[]) {
} }
break; break;
case 'r': case 'r':
radius = 50 + (11 - atoi(optarg)) * 10; radius = 50 + atoi(optarg) * 10;
if (radius > 150 || radius < 50) { if (radius > 150 || radius < 50) {
printf("Invalid radius, only values between 1 and 10 are allowed\n"); printf("Invalid radius, only values between 1 and 10 are allowed\n");
return 0; return 0;