This commit is contained in:
Loup-Garou911XD 2025-07-26 12:41:03 +05:30
parent 237ac157db
commit 8993de53b7
2 changed files with 12 additions and 7 deletions

View file

@ -5,7 +5,15 @@ import bascenev1 as bs
original_getmesh = bs.getmesh original_getmesh = bs.getmesh
plugman = dict(
plugin_name="allow_invisible_models",
description="Shake as many stiies of you as possible",
external_url= "https://www.youtube.com/watch?v=dQw4w9WgXcQ",
author=["Loup", "brostos"],
discord="mydiscord",
email = "dontclickthelink@pleasedont.com",
version="1.0.0"
)
def get_mesh_gracefully(mesh): def get_mesh_gracefully(mesh):
if mesh is not None: if mesh is not None:
return original_getmesh(mesh) return original_getmesh(mesh)

View file

@ -14,6 +14,7 @@ def debug_print(*args, **kwargs):
def update_plugin_json(plugin_info, category): def update_plugin_json(plugin_info, category):
name = plugin_info["plugin_name"] name = plugin_info["plugin_name"]
import os import os
print(os.getcwd()) print(os.getcwd())
with open(f"plugins/{category}/{category}.json", "r+") as file: with open(f"plugins/{category}/{category}.json", "r+") as file:
@ -27,9 +28,7 @@ def update_plugin_json(plugin_info, category):
if current_version > plugman_version or current_version == plugman_version: if current_version > plugman_version or current_version == plugman_version:
plugin["versions"][plugin_info["version"]] = None plugin["versions"][plugin_info["version"]] = None
# Ensure latest version appears first # Ensure latest version appears first
plugin["versions"] = dict( plugin["versions"] = dict(sorted(plugin["versions"].items(), reverse=True))
sorted(plugin["versions"].items(), reverse=True)
)
plugin["description"] = plugin_info["description"] plugin["description"] = plugin_info["description"]
plugin["external_url"] = plugin_info["external_url"] plugin["external_url"] = plugin_info["external_url"]
plugin["authors"] = [ plugin["authors"] = [
@ -89,9 +88,7 @@ def extract_plugman(plugins):
for kw in node.value.keywords: for kw in node.value.keywords:
result[kw.arg] = ast.literal_eval(kw.value) result[kw.arg] = ast.literal_eval(kw.value)
update_plugin_json(result, category=category) update_plugin_json(result, category=category)
raise ValueError( raise ValueError("Variable plugman not found in the file or has unsupported format.")
"Variable plugman not found in the file or has unsupported format."
)
if __name__ == "__main__": if __name__ == "__main__":