1
0
Fork 0
mirror of https://github.com/zeldaret/oot.git synced 2025-07-04 06:54:33 +00:00

Fix colliderinit.py to run from project root (#531)

* Now works from root but not from overlayhelpers

* Fix to run from anywhere
This commit is contained in:
Tharo 2020-12-15 23:27:35 +00:00 committed by GitHub
parent 92e9f2d370
commit 5632df406b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 7 additions and 4 deletions

View file

@ -1,5 +1,6 @@
#!/usr/bin/env python3
import os
import struct
import argparse
from filemap import FileResult, GetFromVRam, GetFromRom
@ -223,7 +224,9 @@ else:
print("ItemInit type must specify number of elements")
exit()
ovlFile = open("../../baserom/" + fileResult.name, "rb")
script_dir = os.path.dirname(os.path.realpath(__file__))
ovlFile = open(script_dir + "/../../baserom/" + fileResult.name, "rb")
ovlData = bytearray(ovlFile.read())
ovlFile.close()