Guess it's related with the 0.6T, since it happened after i updated the game... But when the FPS or time are set to be shown on the left, nothing appear, but when it's set on the right, it's working. Any way to fix that?
int copy_file(ccs src, ccs dst)
{
FILE *fin = fopen(src, read_bin);
if (fin==NULL) return 0;
fseek(fin, 0, SEEK_END);
int size = ftell(fin);
if (size==-1)
{
fclose(fin);
return 0;
}
fseek(fin, 0, SEEK_SET);
byte *mem = new byte[size];
fread(mem, 1, size, fin);
fclose(fin);
FILE *fout = fopen(dst, write_bin);
if (fout==NULL)
{
delete [] mem;
return 0;
}
fwrite(mem, 1, size, fout);
fclose(fout);
delete [] mem;
return 1;
}
int copy_file(ccs src, ccs dst)
{
return CopyFile(src, dst, FALSE);
}
DWORD allowedBits = 0x31A7;
LPSTR pszFileName = "copied_file.dat";
DWORD attrs = GetFileAttributes(pszFileName);
if (attrs & FILE_ATTRIBUTE_READONLY) {
attrs &= ~FILE_ATTRIBUTE_READONLY & allowedBits;
SetFileAttributes(pszFileName, attrs);
}