mirror of
https://git.cavemanon.xyz/Cavemanon/SnootGame.git
synced 2025-02-02 06:46:34 +01:00
29 lines
1.1 KiB
Diff
29 lines
1.1 KiB
Diff
233a234
|
|
> import os # @UnresolvedImport
|
|
236a238,263
|
|
>
|
|
> # MODS STUFF
|
|
> APP_ID = 1895350
|
|
>
|
|
> if not renpy.android:
|
|
> try: # Android will try to run this for some reason and fail
|
|
> mod_paths = [
|
|
> f"../../workshop/content/{APP_ID}/",
|
|
> f"/Users/{os.getlogin()}/Library/Application Support/Steam/steamapps/workshop/content/{APP_ID}/",
|
|
> os.path.expanduser(f"~/Library/Application Support/Steam/steamapps/workshop/content/{APP_ID}/")
|
|
> ]
|
|
> except:
|
|
> mod_paths = []
|
|
>
|
|
> new_paths = []
|
|
> for path in mod_paths:
|
|
> try:
|
|
> if os.path.exists(path):
|
|
> for name in os.listdir(path):
|
|
> full_path = os.path.join(path, name)
|
|
> if os.path.isdir(full_path):
|
|
> new_paths.append(full_path)
|
|
> except Exception as e:
|
|
> renpy.display.log.write(f"Error while adding mod search paths: {e}")
|
|
>
|
|
> searchpath += new_paths
|