Skip to content

Commit e9d6649

Browse files
committed
Fixing bugs + adding 2 new NPC images
1 parent 5e66a50 commit e9d6649

6 files changed

Lines changed: 16 additions & 6 deletions

File tree

README.md

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -125,13 +125,22 @@ For those interested, here is the command I use to generate the folder which I t
125125
(I have this saved as build.bat in the same folder)
126126

127127
```batch
128-
python -m eel main.py "./data/html" -n "Graveyard Keeper Savefile Editor" -i "./data/html/favicon.ico" --exclude PyQt5 --exclude win32com --exclude pydoc --exclude lib2to3 -y
128+
py -3.8 -m eel main.py "./data/html" -n "Graveyard Keeper Savefile Editor" -i "./data/html/favicon.ico" --exclude PyQt5 --exclude win32com --exclude pydoc --exclude lib2to3 -y --additional-hooks-dir=hooks
129129
130130
copy "%cd%\data\hashes" "%cd%\dist\Graveyard Keeper Savefile Editor\data\hashes" /Y
131131
copy "%cd%\data\locals.json" "%cd%\dist\Graveyard Keeper Savefile Editor\data\locals.json" /Y
132132
copy "%cd%\data\data.json" "%cd%\dist\Graveyard Keeper Savefile Editor\data\data.json" /Y
133133
copy "%cd%\data\version" "%cd%\dist\Graveyard Keeper Savefile Editor\data\version" /Y
134134
copy "%cd%\data\itemversion" "%cd%\dist\Graveyard Keeper Savefile Editor\data\itemversion" /Y
135+
copy "%cd%\data\new_item_data.json" "%cd%\dist\Graveyard Keeper Savefile Editor\data\new_item_data.json" /Y
135136
136137
pause
137138
```
139+
140+
In the hooks directory there is a file called `hook-eel.py` with the content:
141+
142+
```py
143+
from PyInstaller.utils.hooks import collect_all
144+
145+
datas, binaries, hiddenimports = collect_all('eel')
146+
```

data/html/index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1264,7 +1264,7 @@
12641264
$(this.el).parents(".item").find(".item_icon").attr("class", "item_icon " + sanitzize_item_id(id));;
12651265

12661266
if ( !settings["expert"]){
1267-
if(!gamedata.items.includes(newid)){
1267+
if(!gamedata.items.includes(id)){
12681268
$(this.el).parents(".item").addClass("unknown_item");
12691269
} else {
12701270
$(this.el).parents(".item").removeClass("unknown_item");
1.75 KB
Loading
1.81 KB
Loading

data/locals.json

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2338,5 +2338,7 @@
23382338
"recipe_bag_universal": "Recipe: Universal bag",
23392339
"recipe_bag_universal_big": "Recipe: Big universal bag",
23402340
"npc_marquis_teodoro_jr": "Marquis Teodoro Jr.",
2341-
"npc_refugee_cook": "Cook"
2341+
"npc_refugee_cook": "Cook",
2342+
"npc_refugee_tanner": "Tanner",
2343+
"npc_refugee_coffin_maker": "Undertaker"
23422344
}

main.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -414,7 +414,7 @@ def modify_save(data, shash):
414414
savefiles[shash]["savedata"]["_inventory"]["v"]["_params"]["v"]["_res_v"]["v"][rel["s"]],
415415
rel["cur"])
416416

417-
edit_inventory(savefiles[shash]["savedata"]["_inventory"]["v"]["inventory"]["v"], data["subinventory"], shash)
417+
edit_inventory(savefiles[shash]["savedata"]["_inventory"]["v"]["inventory"]["v"], data["inventory"], shash)
418418

419419
# Here we check if the save is from an older version which doesn't have this variable yet
420420
# If there is a second inventory (for tools) we update it
@@ -469,8 +469,7 @@ def modify_save(data, shash):
469469

470470
# Check if the object id is the id of a storage unit, if so modify the values
471471
if it["obj_id"]["v"] in gamedata["storage"]:
472-
edit_inventory(it["-1126421579"]["v"]["inventory"]["v"], data["subinventory"],
473-
data["additionalstorage"][i2]["items"])
472+
edit_inventory(it["-1126421579"]["v"]["inventory"]["v"], data["additionalstorage"][i2]["items"], shash)
474473

475474
# Set the inventory size to the new value - the modification of this was removed in the ui because it seems
476475
# that most if not all storage units have a fixed size which can not be changed in the save file

0 commit comments

Comments
 (0)