-
Notifications
You must be signed in to change notification settings - Fork 31
/
__init__.py
108 lines (92 loc) · 3.36 KB
/
__init__.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
#The init file for the plugin
bl_info = {
"name" : "KKBP (Koikatsu Blender Porter)",
"author" : "a blendlet and some blenderchads",
"location" : "View 3D > Tool Shelf > KKBP and Image Editor > Tool Shelf > KKBP",
"description" : "Scripts to automate cleanup of a Koikatsu export",
"version": (7, 2, 0),
"blender" : (3, 6, 0),
"category" : "3D View",
"tracker_url" : "https://github.com/FlailingFog/KK-Blender-Porter-Pack/",
"doc_url": "https://github.com/FlailingFog/KK-Blender-Porter-Pack/blob/master/wiki/Wiki%20top.md",
}
from bpy.utils import register_class, unregister_class
from bpy.types import Scene
from bpy.props import PointerProperty
def reg_unreg(register_bool):
from .preferences import KKBPPreferences
if register_bool:
register_class(KKBPPreferences)
else:
unregister_class(KKBPPreferences)
from .importing.importbuttons import kkbp_import
from .importing.modifymesh import modify_mesh
from .importing.modifyarmature import modify_armature
from .importing.modifymaterial import modify_material
from .importing.postoperations import post_operations
from .exporting.bakematerials import bake_materials
from .exporting.exportprep import export_prep
from .extras.importstudio import import_studio
from .extras.animationlibrary.createmapassetlibrary import map_asset_lib
from .extras.animationlibrary.createanimationlibrary import anim_asset_lib
from .extras.linkshapekeys import link_shapekeys
from .extras.separatemeshes import separate_meshes
from .extras.separatemeshes import export_separate_meshes
from .extras.toggleik import toggle_ik
from .extras.updatebones import update_bones
from .extras.imageconvert import image_convert
from .extras.imageconvert import image_dark_convert
from .extras.rigifywrapper import rigify_convert
from .extras.rigifyscripts.rigify_before import rigify_before
from .extras.rigifyscripts.rigify_after import rigify_after
from .extras.catsscripts.armature_manual import MergeWeights
from .extras.importanimation import anim_import
from .extras.splitobjects import split_objects
from . KKPanel import PlaceholderProperties
from . KKPanel import (
IMPORTINGHEADER_PT_panel,
IMPORTING_PT_panel,
EXPORTING_PT_panel,
EXTRAS_PT_panel,
)
classes = (
bake_materials,
export_prep,
image_convert,
image_dark_convert,
import_studio,
map_asset_lib,
anim_asset_lib,
link_shapekeys,
separate_meshes,
export_separate_meshes,
toggle_ik,
update_bones,
rigify_convert,
rigify_before,
rigify_after,
MergeWeights,
anim_import,
split_objects,
kkbp_import,
modify_mesh,
modify_armature,
modify_material,
post_operations,
PlaceholderProperties,
IMPORTINGHEADER_PT_panel,
IMPORTING_PT_panel,
EXPORTING_PT_panel,
EXTRAS_PT_panel)
for cls in classes:
register_class(cls) if register_bool else unregister_class(cls)
if register_bool:
Scene.kkbp = PointerProperty(type=PlaceholderProperties)
else:
del Scene.kkbp
def register():
reg_unreg(True)
def unregister():
reg_unreg(False)
if __name__ == "__main__":
register()