Question - General How to use "Fast Crypt & Compress" with ini files

Discussion in 'Marketplace' started by OblivionSkull21, Aug 23, 2019.

  1. OblivionSkull21

    OblivionSkull21 Member

    Joined:
    Sep 26, 2017
    Posts:
    299
    Hello, I just recently downloaded Existical Games' asset to encode/decode data so that the normal player can't read/alter it.
    https://marketplace.yoyogames.com/assets/6057/fast-crypt-compress
    Original posting: https://forum.yoyogames.com/index.php?threads/fast-secure-file-encryption-scripts.37005/#post-362695

    I've been reading through the different scripts provided and looked at the example code in each of the scripts, but I'm not completely understanding how to use it, and it doesn't help that there's no actual video footage explaining how to use it.

    My game uses ini files for saving and loading various data, so I would want to encode/decode the data in those ini files.

    I'm mostly interested in using the fast_file_key_crypt_compress() script as it offers the most security, but I can't for the life of me understand what the last argument "enc_key" is supposed to be. Is that the data I'm wanting to encode/decode or something else??

    Here's an example of how my game saves/loads data.

    I have a scr_save() for saving, which opens and writes the data to the file:
    Code:
    if file_exists("SaveInfo.ini"){
    file_delete("SaveInfo.ini")
    }
    ini_open("SaveInfo.ini")  //open save file, or creates an .ini file if one doesn't exist.
    
    date_set_timezone(timezone_local)
    
    ini_write_real("Time of Save", "Hour", current_hour);
    ini_write_real("Time of Save", "Minute", current_minute);
    
    ini_close();
    Then, when I need to load that data I have a separate scr_load:

    Code:
    ini_open("SaveInfo.ini")  //open save file.
    
    hour = ini_read_real("Time of Save", "Hour", current_hour);
    minute = ini_read_real("Time of Save", "Minute", current_minute);
    
    ini_close();
    
    Could someone who has/is familiar with this asset help explain how to use the script fast_file_key_crypt_compress with ini files? Do I need to represent each ini_write_real line as a variable and use that variable as the fourth argument???
     
    Last edited: Aug 23, 2019

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice