Skip to main content

On Sale: GamesAssetsToolsTabletopComics
Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
TagsGame Engines

Gamemaker HTML5 crashes with 403 when trying to load save file (only when on itch.io)

A topic by James created Apr 20, 2024 Views: 87
Viewing posts 1 to 1
(1 edit) (+1)

I've tested my game and it works fine when running in my own web server, but when on itch.io, it leads to a few 403 errors when loading a save file, which leads to a json parse exception. I've searched and I can't figure out what the problem is. The save file name is the same everywhere I use it, there's no casing issues, and I'm being sure to use a unique name. I'm just not sure what the issue is.


function save(_save_data) {

    var _sav = file_text_open_write(working_directory + "cowboy_shapeshiftin_save.json");

    file_text_write_string(_sav, json_stringify(_save_data));

    file_text_close(_sav);

}

function load() {

    if !file_exists(working_directory + "cowboy_shapeshiftin_save.json") {

        return -1;

    }

    var _sav = file_text_open_read(working_directory + "cowboy_shapeshiftin_save.json");

    var _json = file_text_read_string(_sav);

    var _save_data = json_parse(_json);

    file_text_close(_sav);

    return _save_data;

}

This topic has been auto-archived and can no longer be posted in because there haven't been any posts in a while.