Created
September 11, 2026 07:22
-
-
Save nopeless/f26c4c8d340517da8577d3e7961fd12a to your computer and use it in GitHub Desktop.
cuz vault hunters death was too much
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import json | |
| import os | |
| import shutil | |
| if not os.path.exists("spirit_original.json"): | |
| shutil.copy2("spirit.json", "spirit_original.json") | |
| with open("spirit_original.json", "r", encoding="utf-8") as f: | |
| data = json.load(f) | |
| data["__comment"] = "modified with script" | |
| data["rescuedBonusMin"] = 0.5 | |
| GEAR_COST_CAPS = { | |
| "SCRAPPY": 0, | |
| "COMMON": 2, | |
| "RARE": 4, | |
| "EPIC": 6, | |
| "OMEGA": 8, | |
| "UNIQUE": 10 | |
| } | |
| TOOL_COST_CAPS = { | |
| "CHROMATIC_IRON_INGOT": 0, | |
| "CHROMATIC_STEEL_INGOT": 2, | |
| "VAULTERITE_INGOT": 4, | |
| "VAULT_ALLOY": 6, | |
| "BLACK_CHROMATIC_STEEL_INGOT": 8, | |
| "ECHOING_INGOT": 10, | |
| "OMEGA_POG": 12 | |
| } | |
| for levelCost in data["levelCosts"]: | |
| levelCost["itemCost"] = [] | |
| levelCost["gearRarityCost"] = { | |
| tier: min(GEAR_COST_CAPS.get(tier), cost) | |
| for tier, cost in levelCost["gearRarityCost"].items() | |
| } | |
| levelCost["toolMaterialCost"] = { | |
| tier: min(TOOL_COST_CAPS.get(tier), cost) | |
| for tier, cost in levelCost["toolMaterialCost"].items() | |
| } | |
| levelCost["trinketCost"] = min(8, levelCost["trinketCost"]) | |
| levelCost["pendantCost"] = min(8, levelCost["pendantCost"]) | |
| with open("spirit.json", "w", encoding="utf-8") as f: | |
| json.dump(data, f, indent=4) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment