Corrected tutorial

This commit is contained in:
Thomas FORGIONE 2015-07-22 17:01:36 +02:00
parent b9ec13bd6d
commit 4e1d86ca8b
3 changed files with 33 additions and 9 deletions

View File

@ -75,7 +75,7 @@ var TutorialSteps = function(tutoCamera, scene, coins, onWindowResize, container
justclick:true justclick:true
}, },
{ {
text: "Here are some more recommendations, try to browse the scene and find the missing red coins (5/8)", text: "Here are some more recommendations, try to browse the scene and find the missing red coins",
justclick:false justclick:false
}, },
{ {
@ -83,7 +83,27 @@ var TutorialSteps = function(tutoCamera, scene, coins, onWindowResize, container
justclick: false justclick: false
}, },
{ {
text: "Tip : if you find that the previews take too much place, you can put them at the bottom of the screen (use the checkbox options below) !", text: "Tip : you can use the arrow buttons in the bar at the bottom of the screen to go to the previous / next position",
justclick: false
},
{
text: "Tip : you can use the arrow buttons in the bar at the bottom of the screen to go to the previous / next position",
justclick: false
},
{
text: "Tip : you can use the arrow buttons in the bar at the bottom of the screen to go to the previous / next position",
justclick: false
},
{
text: "Tip : you can use the arrow buttons in the bar at the bottom of the screen to go to the previous / next position",
justclick: false
},
{
text: "Tip : you can use the arrow buttons in the bar at the bottom of the screen to go to the previous / next position",
justclick: false
},
{
text: "Tip : you can use the arrow buttons in the bar at the bottom of the screen to go to the previous / next position",
justclick:false justclick:false
}, },
{ {
@ -175,11 +195,15 @@ TutorialSteps.prototype.nextStep = function() {
for (var i = 0; i < cams.length; i == 1 ? i+=2 : i++) { for (var i = 0; i < cams.length; i == 1 ? i+=2 : i++) {
this.addRecommendation(cams[i]); this.addRecommendation(cams[i]);
} }
Coin.total = 1;
Coin.max = 8; Coin.max = 8;
Coin.update(); Coin.update();
this.addCoin(new Coin(3.701112872561801,-0.4620393514856378,-3.3373375945128085, callback)); var coins = L3D.generateCoins(L3D.createPeachCoins());
this.addCoin(new Coin(6.694675339780243,-1.2480369397526456,-1.992336719279164, callback)); for (var i = 0; i < coins.length; i++) {
this.addCoin(new Coin(-2.458336118265302,-1.549510268763568,-11.186153614421212, callback)); coins[i].rotating = true;
coins[i].callback = callback;
this.addCoin(coins[i]);
}
break; break;
} }
this.step++; this.step++;

View File

@ -106,7 +106,7 @@ function initCanvases() {
function initModels() { function initModels() {
// Init recommendations // Init recommendations
recommendations = L3D.initPeach(camera1, scene, coins, clickableObjects); recommendations = L3D.initPeach(camera1, scene, coins, clickableObjects, null);
// init clickable objects // init clickable objects
var i; var i;

View File

@ -220,7 +220,9 @@ L3D.generateCoins = function(totalCoins, coin_ids) {
if (coin_ids === undefined) if (coin_ids === undefined)
L3D.shuffle(totalCoins); L3D.shuffle(totalCoins);
else { else if (coin_ids === null) {
return [];
} else {
for (i = 0; i < coin_ids.length; i++) { for (i = 0; i < coin_ids.length; i++) {
@ -250,8 +252,6 @@ L3D.generateCoins = function(totalCoins, coin_ids) {
indices.push(totalCoins[i].id); indices.push(totalCoins[i].id);
} }
console.log(bound);
if (coin_ids === undefined || (coin_ids instanceof Array && coin_ids.length === 0)) if (coin_ids === undefined || (coin_ids instanceof Array && coin_ids.length === 0))
L3D.DB.Private.sendData('/posts/coin-id', {indices : indices}); L3D.DB.Private.sendData('/posts/coin-id', {indices : indices});