Merge remote-tracking branch 'james/homereset' into atpHomeReset

This commit is contained in:
ericrius1 2016-04-01 15:06:17 -07:00
commit 56ab1e86ba
13 changed files with 268 additions and 18 deletions

View file

@ -188,7 +188,7 @@
// delete littleVersionProps.script;
littleVersionProps.gravity = {
x: 0,
y: -5,
y: -10,
z: 0
};
var userData = JSON.parse(littleVersionProps.userData);

View file

@ -15,7 +15,7 @@
dynamic: true,
gravity: {
x: 0,
y: -5,
y: -10,
z: 0
},
visible: true,

View file

@ -98,7 +98,7 @@ Plant = function(spawnPosition, spawnRotation) {
dynamic: true,
gravity: {
x: 0.0,
y: -2.0,
y: -10.0,
z: 0
},
velocity: {

View file

@ -32,7 +32,7 @@
},
"shapeType": "compound",
"type": "Model",
"userData": "{\"hifiHomeKey\":{\"reset\":true}}",
"userData": "{\"hifiHomeKey\":{\"reset\":true}}"
}
],
"Version": 57

View file

@ -2,7 +2,7 @@
"Entities": [{
"gravity": {
"x": 0,
"y": -7,
"y": -10,
"z": 0
},
"userData": "{\"hifiHomeKey\":{\"reset\":true}}",

View file

@ -0,0 +1,186 @@
{
"Entities": [{
"collisionsWillMove": 1,
"created": "2016-04-01T18:13:50Z",
"dimensions": {
"x": 0.31800505518913269,
"y": 0.31800499558448792,
"z": 0.0033226886298507452
},
"dynamic": 1,
"gravity": {
"x": 0,
"y": -10,
"z": 0
},
"userData": "{\"hifiHomeKey\":{\"reset\":true}}",
"id": "{e9edc4d0-ecef-42de-88de-a652087f8a18}",
"modelURL": "atp:/tutorialContent/Junk-Album-3.fbx",
"name": "Junk-Album-3.fbx",
"queryAACube": {
"scale": 0.44973927736282349,
"x": -0.22486963868141174,
"y": -0.22486963868141174,
"z": -0.22486963868141174
},
"restitution": 0.10000000149011612,
"rotation": {
"w": 0.66469824314117432,
"x": -0.66491186618804932,
"y": 0.24086368083953857,
"z": 0.24098575115203857
},
"shapeType": "box",
"type": "Model"
}, {
"collisionsWillMove": 1,
"created": "2016-04-01T18:13:50Z",
"dimensions": {
"x": 0.2365347146987915,
"y": 0.32964301109313965,
"z": 0.34057953953742981
},
"dynamic": 1,
"gravity": {
"x": 0,
"y": -10,
"z": 0
},
"userData": "{\"hifiHomeKey\":{\"reset\":true}}",
"id": "{cc75df45-0caf-41ff-8c05-29c771cc63d9}",
"modelURL": "atp:/tutorialContent/Hideous-Knick-Knack1.fbx",
"name": "Junk-Doll",
"position": {
"x": 0.3363037109375,
"y": 0.1844482421875,
"z": 0.3884124755859375
},
"queryAACube": {
"scale": 0.52972406148910522,
"x": 0.071441680192947388,
"y": -0.080413788557052612,
"z": 0.12355044484138489
},
"rotation": {
"w": 0.24678421020507812,
"x": -7.62939453125e-05,
"y": 0.9690546989440918,
"z": -7.62939453125e-05
},
"shapeType": "box",
"type": "Model"
}, {
"collisionsWillMove": 1,
"created": "2016-04-01T18:11:39Z",
"dimensions": {
"x": 0.31800505518913269,
"y": 0.31800499558448792,
"z": 0.0033226886298507452
},
"dynamic": 1,
"friction": 0.75,
"gravity": {
"x": 0,
"y": -10,
"z": 0
},
"userData": "{\"hifiHomeKey\":{\"reset\":true}}",
"id": "{903543d7-4531-4532-997a-8176be9fc660}",
"modelURL": "atp:/tutorialContent/Junk-Album-1.fbx",
"name": "Junk-Album-1.fbx",
"position": {
"x": 0.10009765625,
"y": 0.087310791015625,
"z": 0.27129364013671875
},
"queryAACube": {
"scale": 0.44973927736282349,
"x": -0.12477198243141174,
"y": -0.13755884766578674,
"z": 0.046424001455307007
},
"rotation": {
"w": 0.31657898426055908,
"x": -0.024460196495056152,
"y": 0.63219654560089111,
"z": 0.70672154426574707
},
"shapeType": "box",
"type": "Model"
}, {
"collisionsWillMove": 1,
"created": "2016-04-01T18:13:50Z",
"dimensions": {
"x": 0.29665771126747131,
"y": 0.50835514068603516,
"z": 0.26848328113555908
},
"dynamic": 1,
"gravity": {
"x": 0,
"y": -10,
"z": 0
},
"userData": "{\"hifiHomeKey\":{\"reset\":true}}",
"id": "{d99aeed0-9d38-4b82-8ae0-630cdfcd32cb}",
"marketplaceID": "268b7d13-d3f6-4e03-a252-3e5bde1d145e",
"modelURL": "https://s3.amazonaws.com/hifi-public/marketplace/hificontent/ozan/Lamp.fbx",
"name": "Junk - lamp",
"position": {
"x": 0.61279296875,
"y": 0.2528076171875,
"z": 0.91259002685546875
},
"queryAACube": {
"scale": 0.64692658185958862,
"x": 0.28932967782020569,
"y": -0.070655673742294312,
"z": 0.58912670612335205
},
"rotation": {
"w": 0.999969482421875,
"x": -7.62939453125e-05,
"y": -0.0066376924514770508,
"z": 4.57763671875e-05
},
"shapeType": "box",
"type": "Model"
}, {
"compoundShapeURL": "atp:/static_objects/Junk-Crate.obj",
"created": "2016-04-01T18:13:50Z",
"dimensions": {
"x": 0.39995807409286499,
"y": 0.11108967661857605,
"z": 0.71549224853515625
},
"gravity": {
"x": 0,
"y": -10,
"z": 0
},
"userData": "{\"hifiHomeKey\":{\"reset\":true}}",
"id": "{51a01cc1-15cf-4265-9d33-261c96e0e1ed}",
"modelURL": "atp:/models/Junk-Crate.fbx",
"name": "home_model_junk_holder",
"position": {
"x": 0.369384765625,
"y": 0.0540771484375,
"z": 0.39377593994140625
},
"queryAACube": {
"scale": 0.82718592882156372,
"x": -0.04420819878578186,
"y": -0.35951581597328186,
"z": -0.01981702446937561
},
"rotation": {
"w": 0.85989165306091309,
"x": -0.0001373291015625,
"y": 0.5104600191116333,
"z": 4.57763671875e-05
},
"shapeType": "compound",
"type": "Model"
}],
"Version": 57
}

View file

@ -14,7 +14,8 @@ var TRASHCAN_URL = "atp:/kineticObjects/trashcan.json"
var BLOCKS_URL = "atp:/kineticObjects/blocks.json";
var PLAYA_POSTER_URL = "atp:/kineticObjects/postersPlaya.json"
var CELL_POSTER_URL = "atp:/kineticObjects/postersCell.json"
var STUFF_ON_SHELVES_URL ="atp:/kineticObjects/stuff_on_shelves.json"
var STUFF_ON_SHELVES_URL = "atp:/kineticObjects/stuff_on_shelves.json"
var JUNK_URL = "atp:/kineticObjects/junk.json"
FruitBowl = function(spawnLocation, spawnRotation) {
print('CREATE FRUIT BOWL')
@ -139,6 +140,7 @@ BlueChair = function(spawnLocation, spawnRotation) {
function create() {
var success = Clipboard.importEntities(BLUE_CHAIR_URL);
if (success === true) {
created = Clipboard.pasteEntities(spawnLocation)
print('created ' + created);
@ -293,5 +295,28 @@ StuffOnShelves = function(spawnLocation, spawnRotation) {
create();
this.cleanup = cleanup;
}
HomeJunk = function(spawnLocation, spawnRotation) {
print('HOME CREATE JUNK')
var created = [];
function create() {
var success = Clipboard.importEntities(JUNK_URL);
if (success === true) {
created = Clipboard.pasteEntities(spawnLocation)
print('created ' + created);
}
};
function cleanup() {
created.forEach(function(obj) {
Entities.deleteEntity(obj);
})
};
create();
this.cleanup = cleanup;
}

View file

@ -0,0 +1,30 @@
(function() {
var _this;
var LIVING_ROOM_POSITION = {
"x": 1102.35,
"y": 460.122,
"z": -78.924
}
var ROTATION = {
"x": 0,
"y": -0.447182,
"z": 0,
"w": 0.894443
}
var AvatarCatcher = function() {
_this = this;
}
AvatarCatcher.prototype = {
enterEntity: function() {
this.teleportToLivingRoom();
},
teleportToLivingRoom: function() {
MyAvatar.goToLocation(LIVING_ROOM_POSITION, true, ROTATION);
}
}
return new AvatarCatcher();
});

View file

@ -35,7 +35,7 @@
var PING_PONG_GUN_GRAVITY = {
x: 0,
y: -5,
y: -10,
z: 0
};

View file

@ -29,7 +29,7 @@ HomePingPongGun = function(spawnPosition, spawnRotation) {
},
gravity: {
x: 0,
y: -3,
y: -10,
z: 0
},
rotation: Quat.fromPitchYawRollDegrees(spawnRotation.x, spawnRotation.y, spawnRotation.z),

View file

@ -241,15 +241,24 @@
z: -79.8097
});
print('HOME CREATE BLUE CHAIR')
var blueChair = new BlueChair({
var blueChair = new BlueChair({
x: 1100.4821,
y: 459.8161,
z:-75.9071
z: -75.9071
});
// var stuffOnShelf = new stuffOnShelf({});
var stuffOnShelves = new StuffOnShelves({
x: 1105.9432,
y: 461.095,
z: -80.7894
});
var junk = new HomeJunk({
x: 1102.5861,
y: 460.1812,
z: -69.5005
});
var trashcan = new Trashcan({
x: 1103.9034,
@ -314,7 +323,7 @@
}),
position: {
x: 1106.9778,
y: 460.6075,
y: 460.3075,
z: -74.5842
},
userData: JSON.stringify({
@ -334,7 +343,7 @@
var DAIS_DIMENSIONS = {
x: 1.0654,
y: 0.4679,
y: 0.1695,
z: 1.0654
};

View file

@ -83,7 +83,7 @@ TiltMaze = function(spawnPosition, spawnRotation) {
var MAZE_ANGULAR_DAMPING = 0.6;
var MAZE_GRAVITY = {
x: 0,
y: -3,
y: -10,
z: 0
};

View file

@ -112,7 +112,7 @@ Whiteboard = function(spawnPosition, spawnRotation) {
dynamic: true,
gravity: {
x: 0,
y: -1,
y: -10,
z: 0
},
velocity: {
@ -195,7 +195,7 @@ Whiteboard = function(spawnPosition, spawnRotation) {
dynamic: true,
gravity: {
x: 0,
y: -1,
y: -10,
z: 0
},
velocity: {