Inspiration: https://github.com/OpenAWE-Project/OpenAWE/commit/68663aaa78b22a7edd7a97f16ede6992353b73ea