aboutsummaryrefslogtreecommitdiff
path: root/games/devtest/mods/testentities/textures/testentities_cube1.png
diff options
context:
space:
mode:
authorsfan5 <sfan5@live.de>2022-01-24 22:49:36 +0100
committersfan5 <sfan5@live.de>2022-01-28 17:15:10 +0100
commit91c6728eb8cebf060b5a3aaed588a7b6dbf266ad (patch)
treeeaf23233c872495ea7d9451fbe5a93c1088bde87 /games/devtest/mods/testentities/textures/testentities_cube1.png
parent22f0c66abbd02c8d7a66a81cf853f7c7fb84fe17 (diff)
downloadminetest-91c6728eb8cebf060b5a3aaed588a7b6dbf266ad.tar.gz
minetest-91c6728eb8cebf060b5a3aaed588a7b6dbf266ad.tar.bz2
minetest-91c6728eb8cebf060b5a3aaed588a7b6dbf266ad.zip
Add game name to server status string
Diffstat (limited to 'games/devtest/mods/testentities/textures/testentities_cube1.png')
0 files changed, 0 insertions, 0 deletions
tr">'You need to have the Python sqlite3 module.') path = "../world/" paths = [] # sectors2 gets to try first if os.path.isdir(path + 'sectors2/'): paths.append('sectors2') if os.path.isdir(path + 'sectors/'): paths.append('sectors') if not paths: exit('Could not find sectors folder at ' + path + 'sectors2/ or ' + path + 'sectors/') def parseSigned12bit(u): u = int('0x'+u, 16) return (u if u < 2**11 else u - 2**12) def parseSigned16bit(u): u = int('0x'+u, 16) return (u if u < 2**15 else u - 2**16) def int64(u): while u >= 2**63: u -= 2**64 while u <= -2**63: u += 2**64 return u # Convert sector folder(s) to integer def getSectorPos(dirname): if len(dirname) == 8: # Old layout x = parseSigned16bit(dirname[:4]) z = parseSigned16bit(dirname[4:]) elif len(dirname) == 7: # New layout x = parseSigned12bit(dirname[:3]) z = parseSigned12bit(dirname[4:]) else: print('Terrible sector at ' + dirname) return return x, z # Convert block file to integer position def getBlockPos(sectordir, blockfile):