d07RiV / diabloweb

Diablo 1 for web browsers
2.71k stars 220 forks source link

The game crashes (with the error: "index out of bounds") when I try to save it. #586

Open ColourGrey opened 3 weeks ago

ColourGrey commented 3 weeks ago

Description: I tried to save the game, and this produced the error.

App version: DiabloWeb 1.0.39 (Retail)

Error message:

RuntimeError: index out of bounds
_malloc@https://d07riv.github.io/diabloweb/d2271be9a67638d3642f.worker.js?__WB_REVISION__=4115803155f6ffac29dc0498aae8c82f line 1 > WebAssembly.instantiate:wasm-function[1784]:0x10b66b
__Z9SMemAllocjPKcii@https://d07riv.github.io/diabloweb/d2271be9a67638d3642f.worker.js?__WB_REVISION__=4115803155f6ffac29dc0498aae8c82f line 1 > WebAssembly.instantiate:wasm-function[1100]:0xbc1c6
__Z7OpenMPQPKcim@https://d07riv.github.io/diabloweb/d2271be9a67638d3642f.worker.js?__WB_REVISION__=4115803155f6ffac29dc0498aae8c82f line 1 > WebAssembly.instantiate:wasm-function[975]:0xae510
__Z21pfile_write_save_filePKcPhmm@https://d07riv.github.io/diabloweb/d2271be9a67638d3642f.worker.js?__WB_REVISION__=4115803155f6ffac29dc0498aae8c82f line 1 > WebAssembly.instantiate:wasm-function[1022]:0xb37ed
__Z8SaveGamev@https://d07riv.github.io/diabloweb/d2271be9a67638d3642f.worker.js?__WB_REVISION__=4115803155f6ffac29dc0498aae8c82f line 1 > WebAssembly.instantiate:wasm-function[239]:0x17900
__Z18gamemenu_save_gamei@https://d07riv.github.io/diabloweb/d2271be9a67638d3642f.worker.js?__WB_REVISION__=4115803155f6ffac29dc0498aae8c82f line 1 > WebAssembly.instantiate:wasm-function[206]:0x117cb
__Z16gmenu_left_mousei@https://d07riv.github.io/diabloweb/d2271be9a67638d3642f.worker.js?__WB_REVISION__=4115803155f6ffac29dc0498aae8c82f line 1 > WebAssembly.instantiate:wasm-function[230]:0x12b3f
__Z13LeftMouseDowni@https://d07riv.github.io/diabloweb/d2271be9a67638d3642f.worker.js?__WB_REVISION__=4115803155f6ffac29dc0498aae8c82f line 1 > WebAssembly.instantiate:wasm-function[1054]:0xb4f0e
__ZN9MainState7onMouseERK10MouseEvent@https://d07riv.github.io/diabloweb/d2271be9a67638d3642f.worker.js?__WB_REVISION__=4115803155f6ffac29dc0498aae8c82f line 1 > WebAssembly.instantiate:wasm-function[1317]:0xd66c4
dynCall_vii@https://d07riv.github.io/diabloweb/d2271be9a67638d3642f.worker.js?__WB_REVISION__=4115803155f6ffac29dc0498aae8c82f line 1 > WebAssembly.instantiate:wasm-function[2190]:0x11ddac
    at apply (api/Diablo.jscc:2698:0)
    at index (api/Diablo.jscc:2265:0)
__ZN9GameState12processMouseERK10MouseEvent@https://d07riv.github.io/diabloweb/d2271be9a67638d3642f.worker.js?__WB_REVISION__=4115803155f6ffac29dc0498aae8c82f line 1 > WebAssembly.instantiate:wasm-function[1297]:0xd5a23
_DApi_Mouse@https://d07riv.github.io/diabloweb/d2271be9a67638d3642f.worker.js?__WB_REVISION__=4115803155f6ffac29dc0498aae8c82f line 1 > WebAssembly.instantiate:wasm-function[1279]:0xd509a
    at apply (api/Diablo.jscc:2450:0)
    at apply (api/game.worker.js:305:6)
    at func (api/game.worker.js:290:4)
    at X (api/game.worker.js:297:10)
    at apply (api/game.worker.js:423:12)

User agent:

Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:129.0) Gecko/20100101 Firefox/129.0

Save file: single_0.sv.txt (Remove the ".txt" extension, added to keep Github from complaining.)

AJenbo commented 3 weeks ago

Works fine in DevilutionX, DiabloWeb is no longer maintained so you might want to use it instead.

single_0.zip

ColourGrey commented 3 weeks ago

DiabloWeb is no longer maintained

Aha! Well, this is disappointing, given that it has just received coverage from no other than Ars Technica itself.

AJenbo commented 3 weeks ago

Pretty sure that's not the first time, and belive me I'm already well aware that it has made another round in the media. The article is also wrong, Diabloweb doesn't support hellfire, I'm guessing they got it somewhat confused with DevilutionX.

The developer that made the port chose to do so outside of the community maintained DevilutionX and didn't want to maintain it much past getting it working. I'm just giving it a bit of life support until DevilutionX has the bits in place to run in the browser as well (pretty close at this point but no one is actively working on that part).