mirror of
https://github.com/HifiExperiments/overte.git
synced 2025-08-09 22:28:48 +02:00
Change equip-hotspot to a green sphere.
This commit is contained in:
parent
c9f440a49d
commit
6d462a477d
1 changed files with 8 additions and 10 deletions
|
@ -897,28 +897,26 @@ function MyController(hand) {
|
||||||
|
|
||||||
var hotspotPos = grabProps.position;
|
var hotspotPos = grabProps.position;
|
||||||
|
|
||||||
// does this entity have an equip point?
|
// does this entity have an attach point?
|
||||||
var wearableData = getEntityCustomData("wearable", entities[i], undefined);
|
var wearableData = getEntityCustomData("wearable", entities[i], undefined);
|
||||||
if (wearableData) {
|
if (wearableData) {
|
||||||
var handJointName = this.hand === RIGHT_HAND ? "RightHand" : "LeftHand";
|
var handJointName = this.hand === RIGHT_HAND ? "RightHand" : "LeftHand";
|
||||||
if (wearableData[handJointName]) {
|
if (wearableData[handJointName]) {
|
||||||
// draw the hotspot around the equip point.
|
// draw the hotspot around the attach point.
|
||||||
hotspotPos = wearableData[handJointName][0];
|
hotspotPos = wearableData[handJointName][0];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// draw a hotspot!
|
// draw a hotspot!
|
||||||
this.equipHotspotOverlays.push(Overlays.addOverlay("cube", {
|
this.equipHotspotOverlays.push(Overlays.addOverlay("sphere", {
|
||||||
position: hotspotPos,
|
position: hotspotPos,
|
||||||
size: 0.1,
|
size: 0.2,
|
||||||
color: { red: 90, green: 255, blue: 90 },
|
color: { red: 90, green: 255, blue: 90 },
|
||||||
alpha: 1,
|
alpha: 0.7,
|
||||||
solid: false,
|
solid: true,
|
||||||
visible: true,
|
visible: true,
|
||||||
dashed: false,
|
ignoreRayIntersection: false,
|
||||||
lineWidth: 2.0,
|
drawInFront: false
|
||||||
ignoreRayIntersection: true, // this never ray intersects
|
|
||||||
drawInFront: true
|
|
||||||
}));
|
}));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue