FlailingFog / KK-Blender-Porter-Pack

Plugin pack for exporting Koikatsu characters to Blender.
310 stars 29 forks source link

Outfit is not defined and Object has not Attribute , RuntimeError: Error: Nothing selected #236

Closed LegionInstaller closed 1 year ago

LegionInstaller commented 1 year ago

Error: Unknown python error occurred Traceback (most recent call last): File "C:\Users\AppData\Roaming\Blender Foundation\Blender\3.2\scripts\addons\KK-Blender-Shader-Pack-pluginupdate\importing\importeverything.py", line 1171, in execute texture_error = get_and_load_textures(directory) File "C:\Users\AppData\Roaming\Blender Foundation\Blender\3.2\scripts\addons\KK-Blender-Shader-Pack-pluginupdate\importing\importeverything.py", line 524, in get_and_load_textures if '_m_bodyAM' in image.name and outfit.name[-1:].isnumeric(): NameError: name 'outfit' is not defined

Only some cards give this error

Can be fixed my Copying the AM_some number and changing it to 00

LegionInstaller commented 1 year ago

Update: Happens with every card now

LegionInstaller commented 1 year ago

Error: Unknown python error occurred Traceback (most recent call last): File "C:\Users\AppData\Roaming\Blender Foundation\Blender\3.1\scripts\addons\KK-Blender-Shader-Pack-pluginupdate\importing\importeverything.py", line 1177, in execute add_outlines(single_outline_mode) File "C:\Users\AppData\Roaming\Blender Foundation\Blender\3.1\scripts\addons\KK-Blender-Shader-Pack-pluginupdate\importing\importeverything.py", line 941, in add_outlines mod.thickness = 0.0005 AttributeError: 'UVWarpModifier' object has no attribute 'thickness'

LegionInstaller commented 1 year ago

Another one

Error: Unknown python error occurred Traceback (most recent call last): File "C:\Users\AppData\Roaming\Blender Foundation\Blender\3.2\scripts\addons\KK-Blender-Shader-Pack-pluginupdate\importing\separatebody.py", line 697, in execute separate_everything(context) File "C:\Users\AppData\Roaming\Blender Foundation\Blender\3.2\scripts\addons\KK-Blender-Shader-Pack-pluginupdate\importing\separatebody.py", line 174, in separate_everything separate_material(outfit, hair_mat_list) File "C:\Users\AppData\Roaming\Blender Foundation\Blender\3.2\scripts\addons\KK-Blender-Shader-Pack-pluginupdate\importing\separatebody.py", line 126, in separate_material bpy.ops.mesh.separate(type='SELECTED') File "D:\blender-3.2.2-stable+v32.bcfdb14560e7-windows.amd64-release\3.2\scripts\modules\bpy\ops.py", line 115, in call ret = _op_call(self.idname_py(), None, kw) RuntimeError: Error: Nothing selected

poisenbery commented 1 year ago

I've been getting this issue on some cards as well.

KK_110730

Sample card that produces import errors.

LegionInstaller commented 1 year ago

I've been getting this issue on some cards as well.

KK_110730

Sample card that produces import errors.

What kind of Error are you getting ?

poisenbery commented 1 year ago

What kind of Error are you getting ?

"Nothing Selected" on blender import

poisenbery commented 1 year ago

@LegionInstaller It has something to do with the clothing textures.

I believe that they have a different naming convention from other textures, specifically with clothing.

I was able to get the model to successfully import into blender by selecting "Naked" in KK so they export with empty outfits.

Still trying to isolate exactly what is causing this bug.

MediaMoots commented 1 year ago

@FlailingFog

image The issue is most likely caused by this variable not being defined. Maybe the code broke when the new outfit numbering system was added?

LegionInstaller commented 1 year ago

@FlailingFog

image The issue is most likely caused by this variable not being defined. Maybe the code broke when the new outfit numbering system was added?

The AM Issue can be fixed by changing it to AM_00 if Single Outfit and the Modifier by choosing the option in the KKBP Import Panel

FlailingFog commented 1 year ago

outfit.name was supposed to be image.name. I changed that part to something else in https://github.com/FlailingFog/KK-Blender-Porter-Pack/pull/138/commits/a5ca4938eac7702a4c2d80222f87236742f31844