From 7160ad922c3d8a1bf668bfd962e8880a9ed8275a Mon Sep 17 00:00:00 2001
From: GolfOcean334 <130740013+GolfOcean334@users.noreply.github.com>
Date: Mon, 22 Apr 2024 17:56:45 +0200
Subject: [PATCH] Fix: Water Shader
---
enginecustom/applicationclass.cpp | 4 ++--
enginecustom/enginecustom.vcxproj | 1 +
enginecustom/enginecustom.vcxproj.filters | 3 +++
3 files changed, 6 insertions(+), 2 deletions(-)
diff --git a/enginecustom/applicationclass.cpp b/enginecustom/applicationclass.cpp
index 17adf6f..7b5305d 100644
--- a/enginecustom/applicationclass.cpp
+++ b/enginecustom/applicationclass.cpp
@@ -727,8 +727,8 @@ bool ApplicationClass::RenderRefractionToTexture()
// Render the bath model using the refraction shader.
m_BathModel->Render(m_Direct3D->GetDeviceContext());
- result = m_ShaderManager->RenderRefractionShader(m_Direct3D->GetDeviceContext(), m_BathModel->GetIndexCount(), worldMatrix, viewMatrix, projectionMatrix, m_BathModel->GetTexture(0),
- m_Lights[0]->GetDirection(), m_Light->GetAmbientColor(), m_Lights[0]->GetDiffuseColor(), clipPlane);
+ result = m_ShaderManager->RenderRefractionShader(m_Direct3D->GetDeviceContext(), m_BathModel->GetIndexCount(), worldMatrix, viewMatrix, projectionMatrix,
+ m_BathModel->GetTexture(0), m_Lights[0]->GetDirection(), m_Lights[0]->GetAmbientColor(), m_Lights[0]->GetDiffuseColor(), clipPlane);
if (!result)
{
return false;
diff --git a/enginecustom/enginecustom.vcxproj b/enginecustom/enginecustom.vcxproj
index 891cd6b..6a6f8fa 100644
--- a/enginecustom/enginecustom.vcxproj
+++ b/enginecustom/enginecustom.vcxproj
@@ -211,6 +211,7 @@
+
diff --git a/enginecustom/enginecustom.vcxproj.filters b/enginecustom/enginecustom.vcxproj.filters
index 7df3b11..a3c1ca3 100644
--- a/enginecustom/enginecustom.vcxproj.filters
+++ b/enginecustom/enginecustom.vcxproj.filters
@@ -325,6 +325,9 @@
Assets
+
+ Assets
+