Skip to content

Commit 2e171a3

Browse files
authored
Update to 0.18.0
Update to 0.18.0
2 parents 89702cd + 01986c0 commit 2e171a3

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

84 files changed

+7201
-2049
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ resources/downloads
1212
resources/settings.json
1313
resources/dictionary_google.json
1414
resources/google-response.txt
15+
resources/google-response-readable.txt
1516
resources/ignore_version.txt
1617
resources/no_auto_ver_check.txt
1718
.coverage

README.md

Lines changed: 47 additions & 43 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Cats Blender Plugin (0.17.0)
1+
# Cats Blender Plugin (0.18.0)
22

33
A tool designed to shorten steps needed to import and optimize models into VRChat.
44
Compatible models are: MMD, XNALara, Mixamo, Source Engine, Unreal Engine, DAZ/Poser, Blender Rigify, Sims 2, Motion Builder, 3DS Max and potentially more
@@ -17,14 +17,13 @@ There are a lot of perks like having your name inside the plugin!
1717
- Optimizing model with one click!
1818
- Creating lip syncing
1919
- Creating eye tracking
20-
- Automatic decimation
20+
- Automatic decimation (while keeping shapekeys)
2121
- Creating custom models easily
2222
- Creating texture atlas
2323
- Creating root bones for Dynamic Bones
2424
- Optimizing materials
2525
- Translating shape keys, bones, materials and meshes
2626
- Merging bone groups to reduce overall bone count
27-
- Protecting your avatars from game cache ripping
2827
- Auto updater
2928

3029
*More to come!*
@@ -52,11 +51,11 @@ Join our Discord to report errors, suggestions and make comments!
5251

5352
![](https://i.imgur.com/pJfVsho.png)
5453

55-
- If you need help figuring out how to use the tool:
54+
- If you need help figuring out how to use the tool (very outdated):
5655

5756
[![VRChat - Cat's Blender Plugin Overview](https://img.youtube.com/vi/0gu0kEj2xwA/0.jpg)](https://www.youtube.com/watch?v=0gu0kEj2xwA)
5857

59-
Skip the step where he installs "mmd_tools" in the video below, it's not needed anymore!
58+
Skip the step where he installs "mmd_tools" in the video below, it's not needed anymore! (also very outdated)
6059

6160
[![VRChat - Importing an MMD to VRChat Megatutorial!](https://img.youtube.com/vi/7P0ljQ6hU0A/0.jpg)](https://www.youtube.com/watch?v=7P0ljQ6hU0A)
6261

@@ -65,6 +64,9 @@ Skip the step where he installs "mmd_tools" in the video below, it's not needed
6564
- Shotariya
6665
- Neitri
6766
- Kiraver
67+
- Jordo
68+
- Ruubick
69+
- feilen
6870

6971

7072
## Model
@@ -190,10 +192,13 @@ This uses an internal dictionary and Google Translate.
190192

191193
## Decimation
192194

193-
![](https://i.imgur.com/vozxKy9.png)
195+
![](https://i.imgur.com/5u3teLp.png)
194196

195197
**Decimate your model automatically.**
196198

199+
##### Smart Decimation
200+
- This will decimate all meshes while keeping every shapekey.
201+
197202
##### Save Decimation
198203
- This will only decimate meshes with no shape keys.
199204

@@ -204,7 +209,7 @@ This uses an internal dictionary and Google Translate.
204209
- This will decimate your whole model deleting all shape keys in the process.
205210

206211
##### Custom Decimation
207-
- This will let you choose which meshes and shape keys should not be decimated.
212+
- This lets you choose the meshes and shape keys that should not be decimated.
208213

209214

210215
## Eye Tracking
@@ -282,6 +287,15 @@ This works by checking all bones and trying to figure out if they can be grouped
282287
- Starts the merge process
283288

284289

290+
## Bake
291+
292+
![](https://user-images.githubusercontent.com/1109288/97830517-147d1500-1c82-11eb-8b20-feba732ad672.png)
293+
294+
**This is a non-destructive way to produce an optimized variant of (almost) any avatar!**
295+
296+
For more information please visit the **[Bake Panel Wiki Page](https://github.com/GiveMeAllYourCats/cats-blender-plugin/wiki/Bake)**.
297+
298+
285299
## Shape Key
286300

287301
![](https://i.imgur.com/LgFK4KO.png)
@@ -297,9 +311,35 @@ This works by checking all bones and trying to figure out if they can be grouped
297311
**This plugin has an auto updater.**
298312
It checks for a new version automatically once every day.
299313

314+
---
300315

301316
## Changelog
302317

318+
#### 0.18.0
319+
- **Added Bake Panel!**
320+
- This is a non-destructive way to produce an optimized variant of (almost) any avatar!
321+
- Full credit goes to **feilen**! Thanks so much for this awesome feature <3
322+
- Check out the wiki for more information: https://github.com/GiveMeAllYourCats/cats-blender-plugin/wiki/Bake
323+
- **Added Smart Decimation!**
324+
- This lets you decimate without loosing any shapekeys!
325+
- Full credit goes to **feilen**! Tons of thanks for this awesome feature as well <3
326+
- **Added Japanese translation!**
327+
- Cats is now almost fully translated into Japanese
328+
- To use it simply change your Blender language to Japanese and then restart Blender
329+
- Full credit goes to **Jordo** and **Ruuubick**! Thank you so much <3
330+
- If you want to help translating Cats into any language, please us know!
331+
- **General:**
332+
- Cats is now fully compatible with Blender 2.90 and 2.91
333+
- Added "Show mmd_tools tabs" option to Settings
334+
- This allows you show and hide the "MMD" and "Misc" tabs added by the mmd_tools plugin
335+
- Added button to "Start/Stop Pose Mode" which starts/stops pose mode without resetting the current pose
336+
- Changed link to a new vrm importer since the old one dropped support
337+
- Fixed Google Translations no longer working
338+
- Fixed bug in "Apply as Rest Pose" and "Pose to Shape Key" in Blender 2.90
339+
- More fixes for Blender 2.90
340+
- NOTE: Using Cats in Blender 2.90+ on Ubuntu might cause Blender to crash on load (caused by mmd_tools)
341+
- To fix this use a Blender version prior to 2.90 or try updating your drivers
342+
303343
#### 0.17.0
304344
- **Cats is now fully compatible with Blender 2.83!**
305345
- *It was compatible with 2.82 all long*
@@ -329,42 +369,6 @@ It checks for a new version automatically once every day.
329369
- Fixed objects getting unhidden when doing any cats operation in 2.80+
330370
- Updated mmd_tools
331371

332-
#### 0.16.1
333-
- Fixed export warning bug
334-
335-
#### 0.16.0
336-
- **Cats is now fully compatible with Blender 2.81!**
337-
- **Importer**:
338-
- Added support for ZIP files
339-
- It will only extract the zip if importable models are found
340-
- If multiple models are found in the zip, you can select the one you want in a popup window
341-
- Japanese zip files will be extracted with the correct encoding
342-
- Models can now be imported with Cats via the Windows command shell
343-
- **Fix Model**:
344-
- Hips bone will now be larger than before, to comply with the VRChat recommendations
345-
- Read through them here: https://docs.vrchat.com/docs/full-body-tracking
346-
- FFXIV models are now compatible
347-
- Added "Fix Materials" option in Blender 2.80 and higher
348-
- This will apply some VRChat related fixes to materials
349-
- This has always been done in Fix Model but now you can turn it off
350-
- **Model Options**:
351-
- Remove Doubles no longer effects meshes with no shapekeys
352-
- **Custom Model Creation**:
353-
- Added "Join Meshes" option
354-
- Merge Armatures and Attach Mesh no longer require a mesh on the armature
355-
- Fixed bones from the merge armature sometimes getting unintentionally deleted
356-
- **Optimization**:
357-
- Added manual download button if Material Combiner is outdated
358-
- **Copy Protection**:
359-
- Removed Copy Protection panel
360-
- It is no longer a good method for protecting against cache ripping
361-
and it can cause performance and lighting issues
362-
- **General**:
363-
- Armatures will no longer be forced into rest position after any action
364-
- Fixed armatures sometimes not getting detected
365-
- Small bug fixes
366-
- Updated mmd_tools
367-
368372
Read the full changelog [here](https://github.com/michaeldegroot/cats-blender-plugin/releases).
369373

370374

__init__.py

Lines changed: 35 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@
3030
'author': 'GiveMeAllYourCats & Hotox',
3131
'location': 'View 3D > Tool Shelf > CATS',
3232
'description': 'A tool designed to shorten steps needed to import and optimize models into VRChat',
33-
'version': (0, 17, 0), # Has to be (x, x, x) not [x, x, x]!! # Only change this version and the dev branch var right before publishing the new update!
33+
'version': (0, 18, 0), # Has to be (x, x, x) not [x, x, x]!! Only change this version and the dev branch var right before publishing the new update!
3434
'blender': (2, 80, 0),
3535
'wiki_url': 'https://github.com/michaeldegroot/cats-blender-plugin',
3636
'tracker_url': 'https://github.com/michaeldegroot/cats-blender-plugin/issues',
@@ -49,6 +49,7 @@
4949
import shutil
5050
import pathlib
5151
import requests
52+
import platform
5253

5354
from . import globs
5455

@@ -59,22 +60,28 @@
5960
else:
6061
is_reloading = True
6162

63+
import mmd_tools_local
64+
6265
# Load or reload all cats modules
6366
if not is_reloading:
6467
# This order is important
65-
import mmd_tools_local
68+
# import mmd_tools_local
6669
from . import updater
70+
from . import translations
6771
from . import tools
6872
from . import ui
6973
from . import extentions
7074
else:
7175
import importlib
7276
importlib.reload(updater)
7377
importlib.reload(mmd_tools_local)
78+
importlib.reload(translations)
7479
importlib.reload(tools)
7580
importlib.reload(ui)
7681
importlib.reload(extentions)
7782

83+
from .translations import t
84+
7885

7986
# How to update mmd_tools: (outdated, no longer used)
8087
# Delete mmd_tools_local folder
@@ -84,7 +91,13 @@
8491
# Search for "show_backface_culling" and set it to False in view.py
8592
# Done
8693

87-
# How to update googletrans:
94+
# How to update google_trans_new:
95+
# In google_trans.py comment out everything that has to do with urllib3
96+
# This is done because 3.5 doesn't have urllib3 by default and it is only used
97+
# to suppress debug logs in the console
98+
# Done
99+
100+
# How to update googletrans: (outdated since a new googletrans is used Todo remove this)
88101
# in the gtoken.py on line 57 update this line to include "verify=False":
89102
# r = self.session.get(self.host, verify=False)
90103
# In client.py on line 42 remove the Hyper part, it's not faster at all!
@@ -167,18 +180,12 @@ def remove_corrupted_files():
167180
if no_perm:
168181
unregister()
169182
sys.tracebacklimit = 0
170-
raise ImportError('\n\nFaulty CATS installation found!'
171-
'\nTo fix this restart Blender as admin! '
172-
'\n')
183+
raise ImportError(t('Main.error.restartAdmin'))
173184

174185
if os_error:
175186
unregister()
176187
sys.tracebacklimit = 0
177-
message = ' ' \
178-
' '\
179-
'\n\nFaulty CATS installation found!' \
180-
'\nTo fix this delete the following files and folders inside your addons folder:' \
181-
'\n'
188+
message = t('Main.error.deleteFollowing')
182189

183190
for folder in folders:
184191
if folder in to_remove:
@@ -193,34 +200,26 @@ def remove_corrupted_files():
193200
if wrong_path:
194201
unregister()
195202
sys.tracebacklimit = 0
196-
raise ImportError('\n\nFaulty CATS installation found!'
197-
'\nPlease install CATS via User Preferences and restart Blender!'
198-
'\n')
203+
raise ImportError(t('Main.error.installViaPreferences'))
199204

200205
if faulty_installation:
201206
unregister()
202207
sys.tracebacklimit = 0
203-
raise ImportError('\n\nFaulty CATS installation was found and fixed!'
204-
'\nPlease restart Blender and enable CATS again!'
205-
'\n')
208+
raise ImportError(t('Main.error.restartAndEnable'))
206209

207210

208211
def check_unsupported_blender_versions():
209212
# Don't allow Blender versions older than 2.79
210213
if bpy.app.version < (2, 79):
211214
unregister()
212215
sys.tracebacklimit = 0
213-
raise ImportError('\n\nBlender versions older than 2.79 are not supported by Cats. '
214-
'\nPlease use Blender 2.79 or later.'
215-
'\n')
216+
raise ImportError(t('Main.error.unsupportedVersion'))
216217

217218
# Versions 2.80.0 to 2.80.74 are beta versions, stable is 2.80.75
218219
if (2, 80, 0) <= bpy.app.version < (2, 80, 75):
219220
unregister()
220221
sys.tracebacklimit = 0
221-
raise ImportError('\n\nYou are still on the beta version of Blender 2.80!'
222-
'\nPlease update to the release version of Blender 2.80.'
223-
'\n')
222+
raise ImportError(t('Main.error.beta2.80'))
224223

225224

226225
def set_cats_version_string():
@@ -265,6 +264,9 @@ def register():
265264
# Register Updater and check for CATS update
266265
updater.register(bl_info, dev_branch, version_str)
267266

267+
# Load translations and check for missing translations
268+
translations.check_missing_translations()
269+
268270
# Set some global settings, first allowed use of globs
269271
globs.dev_branch = dev_branch
270272
globs.version_str = version_str
@@ -277,15 +279,16 @@ def register():
277279
show_error = True
278280
if show_error:
279281
sys.tracebacklimit = 0
280-
raise ImportError('\n\nPlease restart Blender and enable CATS again!'
281-
'\n')
282+
raise ImportError(t('Main.error.restartAndEnable_alt'))
282283

283284
# if not tools.settings.use_custom_mmd_tools():
284285
# bpy.utils.unregister_module("mmd_tools")
285286

286287
# Load mmd_tools
287288
try:
288289
mmd_tools_local.register()
290+
except NameError:
291+
print('Could not register local mmd_tools')
289292
except AttributeError:
290293
print('Could not register local mmd_tools')
291294
except ValueError:
@@ -349,9 +352,16 @@ def unregister():
349352
# Unregister updater
350353
updater.unregister()
351354

355+
# Register unloaded mmd_tools tabs if they are hidden to avoid issues when unloading mmd_tools
356+
if not bpy.context.scene.show_mmd_tabs:
357+
tools.common.toggle_mmd_tabs(shutdown_plugin=True)
358+
352359
# Unload mmd_tools
353360
try:
354361
mmd_tools_local.unregister()
362+
except NameError:
363+
print('mmd_tools was not registered')
364+
pass
355365
except AttributeError:
356366
print('Could not unregister local mmd_tools')
357367
pass

0 commit comments

Comments
 (0)