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
| # python ubiart (?) crc32 implementation by github.com/InvoxiPlayGames | |
| # function usage - crc(bytearray), if using a string, crc(bytearray(uppercasestring, "utf8")) | |
| # code licensing: don't be a dick with it, credit for general usage would be nice but not required | |
| # if you use parts of this python script in your own project, credit is required | |
| import math | |
| def shifter(a, b, c): | |
| # the masks are because python likes to get excited with bit shifting | |
| d = 0 | |
| a = (a - b - c) ^ (c >> 0xd) |
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
| #Http downloader class for Godot | |
| #This is a simple http downloader class which can be used to download anything from an http url | |
| #USAGE | |
| #Create a new scene "http.xml", with a root Node and attach this script | |
| #Then in other scripts where you want to download something | |
| #var http = preload("res://http.xml").instance() | |
| #http.connect("loading",self,"_ondownloading") | |
| #http.connect("loaded",self,"_ondownloaded") | |
| #http.get(domain,url,port,useSSL) |
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
| version: '3' | |
| services: | |
| web: | |
| build: . | |
| image: server | |
| container_name: server_web | |
| command: flask run --host=0.0.0.0 | |
| ports: | |
| - "5000:5000" | |
| depends_on: |
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
| from io import BytesIO | |
| import struct | |
| toc = [] | |
| filename_directory = [] | |
| with open(input("Input file: "), "rb") as f: | |
| assert f.read(4) == b"AFS\x00" | |
| files_nb = range(struct.unpack("I", f.read(4))[0]) | |