Is there a way to make the external files such as images write proof? Once the game is ready to be published, I don't want people to change textures and images.
Thanks!
Thanks!
Type names Field path$ ;The path to the file used End Type Local destfile = WriteFile(destfilepath$ + ".lok") ;This line uses destfilepath, the file path the user entered earlier where the compacted file will be ;destfile is the handle for the destination file WriteInt(destfile,10506) ;This just writes a random number to the beginning of the file as a 'watermark' Local count = 0 ;This variable will be used to count the number of files being compressed For n.names = Each names ;Cycles through each name to count the number of files stored count = count + 1 Next WriteInt(destfile,count) ;This puts how many files are being compressed in the file For n.names = Each names tempfile = ReadFile(n\path$) ;This reads the files as they come through WriteString(destfile,n\path$) ;This writes the name of each file at the beginning of each file While Not Eof(tempfile) ;This transfers the data from the file selected to the compressed file WriteInt(destfile,ReadInt(tempfile)) Wend WriteInt(destfile,1234) ;This is the sequence that will serve as the markers between files WriteInt(destfile,9876) ;The probability that a file will contain these numbers in this order is extrememly low... if a file you are using does then WriteInt(destfile,101) ;Just change them :) WriteInt(destfile,10) WriteInt(destfile,55608) CloseFile(tempfile) Next CloseFile destfile