Closed legacy5813 closed 1 year ago
You are totally right! whereas in js it will work without a problem, typescript will complain here. I have updated the code and the playgrounds.
You are totally right! whereas in js it will work without a problem, typescript will complain here. I have updated the code and the playgrounds.
thank you!
in the stage "Find the line of code that creates the ground plane and add these new lines underneath it"
the code example in line 4 states "ground.material.diffuseColor = BABYLON.Color3.Red();" but diffuseColor is not a property of ground.material.
The correct code is accessing the ground material through a new babylon standard material class i.e. [ let groundMaterial = new BABYLON.StandardMaterial("Ground Material", scene); groundMaterial.diffuseColor = BABYLON.Color3.Red(); ]
Tutorial link: https://doc.babylonjs.com/journey/theFirstStep -Go to playground 2 step