couloirs finit
This commit is contained in:
parent
4b77eabeb7
commit
0943ce241e
3 changed files with 15 additions and 3 deletions
BIN
images/noir.png
Normal file
BIN
images/noir.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 2.6 KiB |
BIN
images/textCouloir2.png
Normal file
BIN
images/textCouloir2.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 26 KiB |
|
@ -145,6 +145,11 @@ function createDemoScene(scene) {
|
|||
|
||||
var textCouloir1 = new BABYLON.StandardMaterial("texture3", scene);
|
||||
textCouloir1.diffuseTexture = new BABYLON.Texture("images/textCouloir1.png", scene);
|
||||
textCouloir1.specularColor = new BABYLON.Color3(0, 0, 0);
|
||||
|
||||
var textCouloir11 = new BABYLON.StandardMaterial("texture4", scene);
|
||||
textCouloir11.diffuseTexture = new BABYLON.Texture("images/noir.png", scene);
|
||||
textCouloir11.specularColor = new BABYLON.Color3(0, 0, 0);
|
||||
|
||||
var groundCouloir1 = BABYLON.Mesh.CreateGround("groundCouloir1", 10, 20, 2, scene);
|
||||
groundCouloir1.material = new BABYLON.StandardMaterial("gMaterial", scene);
|
||||
|
@ -161,10 +166,11 @@ function createDemoScene(scene) {
|
|||
mur1Couloir1.checkCollisions = true;
|
||||
|
||||
var mur2Couloir1 = BABYLON.Mesh.CreatePlane("mur2Couloir1", 20, scene);
|
||||
mur2Couloir1.material = textCouloir11;
|
||||
mur2Couloir1.rotation.y = -(Math.PI / 2);
|
||||
mur2Couloir1.position.z = 35;
|
||||
mur2Couloir1.position.x = -5;
|
||||
mur2Couloir1.visibility = 0;
|
||||
mur2Couloir1.visibility = 1;
|
||||
mur2Couloir1.checkCollisions = true;
|
||||
|
||||
/*-----------------SALLE 2----------------------------------*/
|
||||
|
@ -222,6 +228,10 @@ function createDemoScene(scene) {
|
|||
|
||||
/*--------------COULOIR 2--------------------*/
|
||||
|
||||
var textCouloir2 = new BABYLON.StandardMaterial("texture5", scene);
|
||||
textCouloir2.diffuseTexture = new BABYLON.Texture("images/textCouloir2.png", scene);
|
||||
textCouloir2.specularColor = new BABYLON.Color3(0, 0, 0);
|
||||
|
||||
var groundCouloir2 = BABYLON.Mesh.CreateGround("groundCouloir2", 10, 20, 2, scene);
|
||||
groundCouloir2.material = new BABYLON.StandardMaterial("gMaterial", scene);
|
||||
groundCouloir2.material = groundMaterial;
|
||||
|
@ -232,14 +242,16 @@ function createDemoScene(scene) {
|
|||
mur1Couloir2.rotation.y = Math.PI / 2;
|
||||
mur1Couloir2.position.z = 105;
|
||||
mur1Couloir2.position.x = 5;
|
||||
mur1Couloir2.visibility = 0;
|
||||
mur1Couloir2.visibility = 1;
|
||||
mur1Couloir2.material = textCouloir2;
|
||||
mur1Couloir2.checkCollisions = true;
|
||||
|
||||
var mur2Couloir2 = BABYLON.Mesh.CreatePlane("mur2Couloir2", 20, scene);
|
||||
mur2Couloir2.rotation.y = -(Math.PI / 2);
|
||||
mur2Couloir2.position.z = 105;
|
||||
mur2Couloir2.position.x = -5;
|
||||
mur2Couloir2.visibility = 0;
|
||||
mur2Couloir2.visibility = 1;
|
||||
mur2Couloir2.material = textCouloir11;
|
||||
mur2Couloir2.checkCollisions = true;
|
||||
|
||||
/*----------------SALLE 3-------------------------*/
|
||||
|
|
Reference in a new issue