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

Editor: Preview pure skeleton. #22858

Merged
merged 3 commits into from
Dec 23, 2021
Merged

Conversation

gonnavis
Copy link
Contributor

Let editor can preview pure skeleton file, which has not SkinnedMesh.
Such as some animation pack files downloaded from https://www.mixamo.com/ :
Sword and Shield Pack.zip

@gonnavis gonnavis changed the title Editor: Can preview pure skeleton. Editor: Preview pure skeleton. Nov 18, 2021
@@ -424,6 +424,10 @@ Editor.prototype = {

helper = new THREE.SkeletonHelper( object.skeleton.bones[ 0 ] );

} else if ( object.isBone && ( !object.parent || !object.parent.isBone ) ) {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this can be simplified like so:

} else if ( object.isBone && ( object.parent?.isBone !== true ) ) {

Copy link
Collaborator

@Mugen87 Mugen87 Nov 19, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

BTW: The policy for testing is* flags looks like so:

object.isBone === true // detecting all bones
object.isBone !== true // detecting all 3D objects except for bones

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks! Updated.

@Mugen87 Mugen87 added this to the r135 milestone Nov 19, 2021
@mrdoob mrdoob modified the milestones: r135, r136 Nov 26, 2021
@mrdoob mrdoob merged commit 095233f into mrdoob:dev Dec 23, 2021
@mrdoob
Copy link
Owner

mrdoob commented Dec 23, 2021

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants