mirror of
https://github.com/The-Powder-Toy/The-Powder-Toy.git
synced 2025-08-26 09:24:28 +02:00
Allow setting of application data path \(For config, save and script data\)
This commit is contained in:
14
src/main.c
14
src/main.c
@@ -1716,6 +1716,20 @@ int main(int argc, char *argv[])
|
|||||||
}
|
}
|
||||||
i++;
|
i++;
|
||||||
}
|
}
|
||||||
|
else if (!strncmp(argv[i], "ddir", 4) && i+1<argc)
|
||||||
|
{
|
||||||
|
/*char * temppath;
|
||||||
|
FILE *f;
|
||||||
|
temppath = malloc(strlen(argv[i+1])+19);
|
||||||
|
sprintf(temppath, "%s%s%s", argv[i+1], PATH_SEP, "powdertoydir.test")
|
||||||
|
f = fopen(temppath, "wb");
|
||||||
|
if(f){*/
|
||||||
|
chdir(argv[i+1]);
|
||||||
|
/* fclose(f);
|
||||||
|
remove(temppath);
|
||||||
|
}
|
||||||
|
free(temppath);*/
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user