Hfile skip a line?
#1

When using hFile, like this:
pawn Код:
format(var, 32, "PayDayHad=%d\n",PlayerInfo[playerid][pPayDayHad]);fwrite(hFile, var);
format(var, 32, "PayDayHad=%d\n",PlayerInfo[playerid][pPayDayHad]);fwrite(hFile, var);
format(var, 32, "PayDayHad=%d\n",PlayerInfo[playerid][pPayDayHad]);fwrite(hFile, var);
lets say I wouldnt want to update something on accounts update, how could I skip without writting?

something like this?:
pawn Код:
format(var, 32, "PayDayHad=\n");fwrite(hFile, var);
or what?
Reply
#2

Any ideas?
Reply
#3

and how will know what to write?
Код:
format(var, 32, "PayDayHad=\n");fwrite(hFile, var);
He will write this..
PlayerInfo[playerid][pPayDayHad]
Код:
format(var, 32, "PayDayHad=%d\n",PlayerInfo[playerid][pPayDayHad]);fwrite(hFile, var);
Reply
#4

I know it did write this, I tested it, so how can I skip through leaving whatever valu is there, because that value gets updated at different point, not every time accounts update.

Any ideas?
Reply
#5

You can do it with a timer,write files on
Код:
OnPlayerUpdate
And you can put a timer there and is updating on X Minutes.
But is better to write that on OnPlayerUpdate and put it to
OnPlayerDisconnect, an it save it.
Reply
#6

no need no timer, I just want everything to save as it is, but dont update on the pPayDayHad, if that was =20, I want it to stay like that without updating
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)