Transparent objects working.
This commit is contained in:
+12
-2
@@ -98,7 +98,6 @@ void GameWorld::Initialize()
|
||||
// CommitEntity(ground);
|
||||
//}
|
||||
|
||||
|
||||
{
|
||||
auto ground_middle = CreateEntity();
|
||||
auto transform = AddComponent<Components::Transform>(ground_middle);
|
||||
@@ -109,7 +108,7 @@ void GameWorld::Initialize()
|
||||
auto blendmap = AddComponent<Components::BlendMap>(ground_middle);
|
||||
blendmap->TextureRed = "Textures/Ground/Sand.png";
|
||||
blendmap->TextureGreen = "Textures/Ground/Grass.png";
|
||||
blendmap->TextureBlue = "Textures/Ground/Asphalt.png";
|
||||
blendmap->TextureBlue = "Textures/Ground/Rock.png";
|
||||
blendmap->TextureRepeats = 30.f;
|
||||
|
||||
auto physics = AddComponent<Components::Physics>(ground_middle);
|
||||
@@ -239,6 +238,17 @@ void GameWorld::Initialize()
|
||||
CommitEntity(ground_base_mirrored);
|
||||
}
|
||||
|
||||
{
|
||||
auto tree = CreateEntity();
|
||||
auto transform = AddComponent<Components::Transform>(tree);
|
||||
transform->Position = glm::vec3(0, -15, 0);
|
||||
auto model = AddComponent<Components::Model>(tree);
|
||||
model->ModelFile = "Models/Tree/leafs/Leafs.obj";
|
||||
model->Transparent = true;
|
||||
|
||||
CommitEntity(tree);
|
||||
}
|
||||
|
||||
EntityID tank1 = CreateTank(1);
|
||||
{
|
||||
auto transform = GetComponent<Components::Transform>(tank1);
|
||||
|
||||
Reference in New Issue
Block a user