mirror of
https://github.com/lubosz/overte.git
synced 2025-08-07 16:41:02 +02:00
more atp reworking
This commit is contained in:
parent
556f4b936d
commit
388c562d4d
3 changed files with 8 additions and 7 deletions
|
@ -32,5 +32,5 @@ function createTidyGuy() {
|
||||||
var tidyGuy = createTidyGuy();
|
var tidyGuy = createTidyGuy();
|
||||||
|
|
||||||
Script.scriptEnding.connect(function() {
|
Script.scriptEnding.connect(function() {
|
||||||
// Entities.deleteEntity(tidyGuy);
|
Entities.deleteEntity(tidyGuy);
|
||||||
})
|
})
|
|
@ -34,7 +34,8 @@
|
||||||
max: 1000
|
max: 1000
|
||||||
};
|
};
|
||||||
_this.canCreateFlower = true;
|
_this.canCreateFlower = true;
|
||||||
_this.SHADER_URL = "https://s3-us-west-1.amazonaws.com/hifi-content/eric/shaders/flower.fs";
|
// _this.SHADER_URL = "https://s3-us-west-1.amazonaws.com/hifi-content/eric/shaders/flower.fs";
|
||||||
|
_this.SHADER_URL = "atp:/shaders/flower.fs";
|
||||||
// _this.SHADER_URL = "file:///C:/Users/Eric/hifi/unpublishedScripts/DomainContent/Home/plant/flower.fs";
|
// _this.SHADER_URL = "file:///C:/Users/Eric/hifi/unpublishedScripts/DomainContent/Home/plant/flower.fs";
|
||||||
|
|
||||||
_this.flowerHSLColors = [{
|
_this.flowerHSLColors = [{
|
||||||
|
|
|
@ -9,8 +9,8 @@
|
||||||
// Distributed under the Apache License, Version 2.0.
|
// Distributed under the Apache License, Version 2.0.
|
||||||
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
|
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
|
||||||
//
|
//
|
||||||
var PLANT_SCRIPT_URL = Script.resolvePath("growingPlantEntityScript.js?v1" + Math.random().toFixed(2));
|
var PLANT_SCRIPT_URL = Script.resolvePath("growingPlantEntityScript.js?v1" + Math.random());
|
||||||
var WATER_CAN_SCRIPT_URL = Script.resolvePath("waterCanEntityScript.js?v2" + Math.random().toFixed());
|
var WATER_CAN_SCRIPT_URL = Script.resolvePath("waterCanEntityScript.js?v1" + Math.random());
|
||||||
Plant = function(spawnPosition, spawnRotation) {
|
Plant = function(spawnPosition, spawnRotation) {
|
||||||
var orientation;
|
var orientation;
|
||||||
if (spawnRotation !== undefined) {
|
if (spawnRotation !== undefined) {
|
||||||
|
@ -20,7 +20,7 @@ Plant = function(spawnPosition, spawnRotation) {
|
||||||
}
|
}
|
||||||
print("EBL ORIENTATION " + JSON.stringify(orientation));
|
print("EBL ORIENTATION " + JSON.stringify(orientation));
|
||||||
var bowlPosition = spawnPosition;
|
var bowlPosition = spawnPosition;
|
||||||
var BOWL_MODEL_URL = "http://hifi-content.s3.amazonaws.com/alan/dev/Flowers--Bowl.fbx";
|
var BOWL_MODEL_URL = "atp:/models/Flowers-Bowl.fbx";
|
||||||
var bowlDimensions = {
|
var bowlDimensions = {
|
||||||
x: 0.518,
|
x: 0.518,
|
||||||
y: 0.1938,
|
y: 0.1938,
|
||||||
|
@ -40,7 +40,7 @@ Plant = function(spawnPosition, spawnRotation) {
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
||||||
var PLANT_MODEL_URL = "http://hifi-content.s3.amazonaws.com/alan/dev/Flowers--Moss-Rock.fbx";
|
var PLANT_MODEL_URL = "atp:/models/Flowers-Rock.fbx";
|
||||||
|
|
||||||
var plantDimensions = {
|
var plantDimensions = {
|
||||||
x: 0.52,
|
x: 0.52,
|
||||||
|
@ -68,7 +68,7 @@ Plant = function(spawnPosition, spawnRotation) {
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
||||||
var WATER_CAN_MODEL_URL = "https://s3-us-west-1.amazonaws.com/hifi-content/eric/models/waterCan.fbx";
|
var WATER_CAN_MODEL_URL = "atp:/models/waterCan.fbx";
|
||||||
|
|
||||||
var waterCanPosition = Vec3.sum(plantPosition, Vec3.multiply(0.6, Quat.getRight(orientation)));
|
var waterCanPosition = Vec3.sum(plantPosition, Vec3.multiply(0.6, Quat.getRight(orientation)));
|
||||||
var waterCanRotation = orientation;
|
var waterCanRotation = orientation;
|
||||||
|
|
Loading…
Reference in a new issue