mirror of
https://github.com/overte-org/overte.git
synced 2025-08-04 01:43:27 +02:00
passing marker color accross
This commit is contained in:
parent
40176b0424
commit
9ae1ccee50
2 changed files with 10 additions and 4 deletions
|
@ -72,7 +72,7 @@
|
|||
},
|
||||
position: position,
|
||||
textures: _this.MARKER_TEXTURE_URL,
|
||||
color: {red: 0, green: 10, blue: 200}
|
||||
color: _this.markerColor
|
||||
});
|
||||
|
||||
_this.linePoints = [];
|
||||
|
@ -127,10 +127,12 @@
|
|||
print("EBL PRELOAD");
|
||||
},
|
||||
|
||||
setWhiteboard: function(myId, data) {
|
||||
_this.whiteboard = JSON.parse(data[0]);
|
||||
setProperties: function(myId, data) {
|
||||
var data = JSON.parse(data);
|
||||
_this.whiteboard = data.whiteboard;
|
||||
var whiteboardProps = Entities.getEntityProperties(_this.whiteboard, ["rotation"]);
|
||||
_this.whiteboardNormal = Quat.getRight(whiteboardProps.rotation);
|
||||
_this.markerColor = data.markerColor;
|
||||
}
|
||||
};
|
||||
|
||||
|
|
|
@ -95,7 +95,11 @@ var marker = Entities.addEntity({
|
|||
});
|
||||
|
||||
Script.setTimeout(function() {
|
||||
Entities.callEntityMethod(marker, "setWhiteboard", [JSON.stringify(whiteboard)]);
|
||||
var data = {
|
||||
whiteboard: whiteboard,
|
||||
markerColor: {red: 10, green: 10, blue: 200}
|
||||
}
|
||||
Entities.callEntityMethod(marker, "setProperties", [JSON.stringify(data)]);
|
||||
}, 1000)
|
||||
|
||||
|
||||
|
|
Loading…
Reference in a new issue