Save data

hi, how can i save data from the game(like variables) to a file that is in my folder and read the variables from it when i open the game it will read the data from the file(save/load data to a helper file in the game’s folder)
is there a way to do it?
(even with shared objects,as long as it use a file that is in the game’s folder)
thanks in advance :smiley: