Created
July 13, 2017 10:52
-
-
Save drcmda/1c027cedf1abb1022db16e39fdd8a92d to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
globals.color { | |
objectHoverColor: ... | |
materialHoverColor: ... | |
} | |
Mesh.material = [{ ... }, {}, {}] || { ... } | |
const array = [...Mesh.material] | |
array.forEach( ... ) | |
Scene | |
Group.Connection.Pool | |
Group.Assembly | |
Group.Part | |
Group.Part | |
Group.Assembly | |
[Group.Part] - Hellrot | |
Mesh | |
Mesh | |
[LineSegments] - Dunkelrot | |
pierce = [''] | |
types = ['LineSegments'] | |
objectMode = types.filter(i => i !== 'Mesh' && i !== 'LineSegments' && i !== 'Point').length > 0 | |
constr() { | |
opbserev.state.globals,activeSelection => this.active = active | |
} | |
const = hover({ object, material }) => { | |
if (objectMode) { | |
obj.traverse(child => | |
child && child.material && child.animate(child.mapMaterial(childMaterial => | |
child.type === 'Mesh' | |
|| childMaterial === material | |
&& ({ color: new THREE.Color(globals.color + (childMaterial === material ? 0x101010 : 0)) }) | |
).start(1000)) | |
} | |
} else material.animate({ color, opacity, ... }) | |
if (active) -> active.items = [ids...] | |
} | |
//Obj.delete("16516,1761761,1871,-19898") | |
//selector.getSelected(...) | |
obj[.material].animate(...) | |
obj[.material] | |
obj[.material] | |
obj[.material] | |
obj.traverse(c => c && c.material && c.animte(c.mapMaterials({ opacity: 0 }).start(1000)) | |
child.traverse(c => c && c.material && c.animte(c.mapMaterials({ opacity: 1 }).start(1000)) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment