summaryrefslogtreecommitdiffstats
path: root/src/rw/Lights.cpp
diff options
context:
space:
mode:
authorNikolay Korolev <nickvnuk@gmail.com>2021-01-01 11:21:42 +0100
committerNikolay Korolev <nickvnuk@gmail.com>2021-01-01 11:21:42 +0100
commit575845772fc3f5385eab56044cf97ef0ce930e17 (patch)
tree1b51da6e1759bac72bec1392435c453eaee60158 /src/rw/Lights.cpp
parentlcs car ctrl 2 (diff)
parentMerge branch 'miami' of github.com:GTAmodding/re3 into miami (diff)
downloadre3-575845772fc3f5385eab56044cf97ef0ce930e17.tar
re3-575845772fc3f5385eab56044cf97ef0ce930e17.tar.gz
re3-575845772fc3f5385eab56044cf97ef0ce930e17.tar.bz2
re3-575845772fc3f5385eab56044cf97ef0ce930e17.tar.lz
re3-575845772fc3f5385eab56044cf97ef0ce930e17.tar.xz
re3-575845772fc3f5385eab56044cf97ef0ce930e17.tar.zst
re3-575845772fc3f5385eab56044cf97ef0ce930e17.zip
Diffstat (limited to 'src/rw/Lights.cpp')
-rw-r--r--src/rw/Lights.cpp41
1 files changed, 41 insertions, 0 deletions
diff --git a/src/rw/Lights.cpp b/src/rw/Lights.cpp
index 3657e2c7..e0dff850 100644
--- a/src/rw/Lights.cpp
+++ b/src/rw/Lights.cpp
@@ -3,6 +3,7 @@
#include <rpworld.h>
#include "Lights.h"
+#include "Timer.h"
#include "Timecycle.h"
#include "Coronas.h"
#include "Weather.h"
@@ -276,6 +277,46 @@ SetAmbientAndDirectionalColours(float f)
RpLightSetColor(pDirect, &DirectionalLightColour);
}
+// unused
+void
+SetFlashyColours(float f)
+{
+ if(CTimer::GetTimeInMilliseconds() & 0x100){
+ AmbientLightColour.red = 1.0f;
+ AmbientLightColour.green = 1.0f;
+ AmbientLightColour.blue = 1.0f;
+
+ DirectionalLightColour.red = DirectionalLightColourForFrame.red;
+ DirectionalLightColour.green = DirectionalLightColourForFrame.green;
+ DirectionalLightColour.blue = DirectionalLightColourForFrame.blue;
+
+ RpLightSetColor(pAmbient, &AmbientLightColour);
+ RpLightSetColor(pDirect, &DirectionalLightColour);
+ }else{
+ SetAmbientAndDirectionalColours(f * 0.75f);
+ }
+}
+
+// unused
+void
+SetFlashyColours_Mild(float f)
+{
+ if(CTimer::GetTimeInMilliseconds() & 0x100){
+ AmbientLightColour.red = 0.65f;
+ AmbientLightColour.green = 0.65f;
+ AmbientLightColour.blue = 0.65f;
+
+ DirectionalLightColour.red = DirectionalLightColourForFrame.red;
+ DirectionalLightColour.green = DirectionalLightColourForFrame.green;
+ DirectionalLightColour.blue = DirectionalLightColourForFrame.blue;
+
+ RpLightSetColor(pAmbient, &AmbientLightColour);
+ RpLightSetColor(pDirect, &DirectionalLightColour);
+ }else{
+ SetAmbientAndDirectionalColours(f * 0.9f);
+ }
+}
+
void
SetBrightMarkerColours(float f)
{