is there a Frikfile tutorial somewhere?
I want to use it to store and reload my current weapons, ammo, clips and health between the levels.
Im using a scratch qc so i dont use any of the old quakestuff..
FrikFile tutorial??
Re: FrikFile tutorial??
hello mrwayne, using frik file stuff is very easy, you can see a clear example of this use here
http://www.mediafire.com/download/szo8y ... Ceriux.rar
In this example, i am using frik file instead some stats
http://www.mediafire.com/download/szo8y ... Ceriux.rar
In this example, i am using frik file instead some stats
hi, I am nahuel, I love quake and qc.
Re: FrikFile tutorial??
thx im going too look into that
So i can basicially save anything with frikfile?
What about custom ammo, stats and weapons?
I dont use parm1, parm2 etc for giving the player items.
So i can basicially save anything with frikfile?
What about custom ammo, stats and weapons?
I dont use parm1, parm2 etc for giving the player items.
Re: FrikFile tutorial??
frik_file supports only strings. note that you can read/write floats/vectors via using stof/ftos / stov/vtos.
fopen returns -1 on failure, not 0.
empty lines return "" while EOF returns string_null. if (strvalue) will evaluate to true for "" and false for the null string.
don't forget to close your file. just because its good to clean up after yourself.
there's no seek support or binary files, so generally you'll want to read everything in and work in memory instead of constantly refering to the file.
\n denotes the end of a line. strings that contain that character (like centerprint messages) can thus be awkward to save.
you can use frik_file for inventory systems between maps, but you'll have to be sure to avoid issues with saved games etc. players joining midgame will require extra care.
in a deathmatch game on a public server, you probably don't want to create a new file for every player, or someone will waste all your diskspace citing 'for the luls'. there's no real way to delete files again.
fopen returns -1 on failure, not 0.
empty lines return "" while EOF returns string_null. if (strvalue) will evaluate to true for "" and false for the null string.
don't forget to close your file. just because its good to clean up after yourself.
there's no seek support or binary files, so generally you'll want to read everything in and work in memory instead of constantly refering to the file.
\n denotes the end of a line. strings that contain that character (like centerprint messages) can thus be awkward to save.
you can use frik_file for inventory systems between maps, but you'll have to be sure to avoid issues with saved games etc. players joining midgame will require extra care.
in a deathmatch game on a public server, you probably don't want to create a new file for every player, or someone will waste all your diskspace citing 'for the luls'. there's no real way to delete files again.
Re: FrikFile tutorial??
thanks for the infos
I just going to use it in SP, for MP i will use a different way to give the players their weapons and stuff
I just going to use it in SP, for MP i will use a different way to give the players their weapons and stuff