请问有没有人懂用wirte_file和read_file进行保存?
我暂时只懂write_file但不懂运用read_file
请高手指教
其中的write_file
复制程式
public SaveLocation(id)
{
static Data[64], FilePath[64], iOrigin[3], szMapName[32];
get_mapname(szMapName, charsmax(szMapName));
format(FilePath, charsmax(FilePath), "/maps/%s_location.cfg", szMapName);
get_user_origin(id, iOrigin);
format(Data, charsmax(Data), "{^nOrigin:/%d %d %d^n}", iOrigin[0], iOrigin[1], iOrigin[2]);
write_file(FilePath, Data, -1);
set_hudmessage(75, 200, 200, -1.0, 0.86, 0, 6.0, 2.0, 0.1, 0.5, -1);
show_hudmessage(id,"Data successfully written to %s!", FilePath);
}