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: Change textures on MultiMaterial #12023

Merged
merged 1 commit into from
Aug 24, 2017

Conversation

TyLindberg
Copy link
Contributor

Fix for #12022


Command.call( this );
this.type = 'SetMaterialMapCommand';
this.name = 'Set Material.' + mapName;

this.object = object;
this.mapName = mapName;
this.oldMap = ( object !== undefined ) ? object.material[ mapName ] : undefined;
this.material = ( Array.isArray( object.material ) ) ? object.material[ materialSlot ] : object.material;
Copy link
Owner

Choose a reason for hiding this comment

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

Is this.material accessed from outside?

Maybe it would be better to follow the other command classes?
https://github.com/mrdoob/three.js/blob/dev/editor/js/commands/SetMaterialColorCommand.js

Copy link
Owner

Choose a reason for hiding this comment

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

Never mind 😇

@mrdoob mrdoob merged commit 01d996f into mrdoob:dev Aug 24, 2017
@mrdoob
Copy link
Owner

mrdoob commented Aug 24, 2017

Thanks!

@TyLindberg
Copy link
Contributor Author

Sorry about the delay on my response, I didn't have time to fix it up yesterday.
Thanks for merging it in!

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.

2 participants