spawning marker tips- parenting to markers

This commit is contained in:
ericrius1 2016-02-17 15:08:42 -08:00
parent 073661b78d
commit df84a166e4

View file

@ -51,7 +51,7 @@ var marker = Entities.addEntity({
y: -1,
z: 0
},
rotation: whiteboardRotation,
// rotation: whiteboardRotation,
velocity: {
x: 0,
y: -0.1,
@ -91,10 +91,20 @@ var marker = Entities.addEntity({
})
});
var markerTip = Entities.addEntity({
type: "Box",
dimensions: {x: 0.05, y: 0.05, z: 0.05},
position: Vec3.sum(markerPosition, {x: 0.0, y: 0.001, z: 0.1}),
parentID: marker,
color: {red: 200, green: 10, blue: 200},
collisionless: true
})
function cleanup() {
Entities.deleteEntity(whiteboard);
Entities.deleteEntity(marker);
Entities.deleteEntity(markerTip);
}
Script.scriptEnding.connect(cleanup);