mirror of
https://github.com/bdunderscore/modular-avatar.git
synced 2024-12-29 02:35:06 +08:00
fix: NRE when AnimatorControllerLayer.stateMachine
is null (#1283)
Closes: #1056
This commit is contained in:
parent
7ae98d63b0
commit
f40d02ceb9
@ -573,6 +573,8 @@ namespace nadena.dev.modular_avatar.animation
|
||||
|
||||
private AnimatorStateMachine mapStateMachine(string basePath, AnimatorStateMachine layerStateMachine)
|
||||
{
|
||||
if (layerStateMachine == null) return null;
|
||||
|
||||
var cacheKey = new KeyValuePair<string, AnimatorStateMachine>(basePath, layerStateMachine);
|
||||
|
||||
if (_stateMachines.TryGetValue(cacheKey, out var asm))
|
||||
|
Loading…
Reference in New Issue
Block a user