Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

T&Oが親によってinactive/disableをあんま想定してない #434

Closed
anatawa12 opened this issue Sep 7, 2023 · 0 comments · Fixed by #441
Closed

T&Oが親によってinactive/disableをあんま想定してない #434

anatawa12 opened this issue Sep 7, 2023 · 0 comments · Fixed by #441
Labels
a:TraceAndOptimize issues about TraceAndOptimize features bug Something isn't working
Milestone

Comments

@anatawa12
Copy link
Owner

bool? activeNess;
switch (component)
{
case Transform transform:
var gameObject = transform.gameObject;
activeNess = _modifications.GetConstantValue(gameObject, "m_IsActive", gameObject.activeSelf);
break;
case Cloth cloth:
activeNess = _modifications.GetConstantValue(cloth, "m_IsEnable", cloth.enabled);
break;
case Renderer cloth:
activeNess = _modifications.GetConstantValue(cloth, "m_IsEnable", cloth.enabled);
break;
case Behaviour behaviour:
activeNess = _modifications.GetConstantValue(behaviour, "m_IsEnable", behaviour.enabled);
break;
case Component _:
activeNess = null;
break;
default:
throw new Exception($"Unexpected type: {component.GetType().Name}");
}

@anatawa12 anatawa12 added bug Something isn't working a:TraceAndOptimize issues about TraceAndOptimize features labels Sep 7, 2023
@anatawa12 anatawa12 added this to the v1.5 milestone Sep 7, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
a:TraceAndOptimize issues about TraceAndOptimize features bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant