From 7b7b23260abb3c724cb403ded25cd257bcc8f99d Mon Sep 17 00:00:00 2001 From: JappaWakka Date: Fri, 27 Oct 2023 11:48:56 +0200 Subject: [PATCH] Fix cave fog + added Mist weather --- P3D/Content/SkyDomeResource/FogColors.png | Bin 165 -> 165 bytes P3D/World/World.vb | 15 ++++++++++++++- 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/P3D/Content/SkyDomeResource/FogColors.png b/P3D/Content/SkyDomeResource/FogColors.png index 8d3f3d637b9276d6cdc23fdb7c3a1e60c4a43e4c..022d7c8b3f8eee15d9fa41ab67d480aa47041c71 100644 GIT binary patch delta 46 zcmZ3=xRh~1o%)B38x0Lkos#cr!zDOuHC>z|+;wWt~$(69CO` B5oZ7Z delta 46 zcmZ3=xRh~1o%)^~m7R@&Vb@;#H}_0ui(Gk^hrw?F|D&x3)t55>fv2mV%Q~loCIH*o B63PGo diff --git a/P3D/World/World.vb b/P3D/World/World.vb index e123bfb1f..355db5833 100644 --- a/P3D/World/World.vb +++ b/P3D/World/World.vb @@ -28,6 +28,7 @@ Public Class World Sandstorm = 7 Ash = 8 Blizzard = 9 + Mist = 10 End Enum Public Enum EnvironmentTypes As Integer @@ -169,6 +170,14 @@ Public Class World GoTo endsub End If + If Weather = Weathers.Mist Then + Screen.Effect.FogStart = -1 + Screen.Effect.FogEnd = 19 + + Screen.Camera.FarPlane = 20 + GoTo endsub + End If + Select Case EnvironmentType Case EnvironmentTypes.Cave, EnvironmentTypes.Dark, EnvironmentTypes.Forest Select Case Core.GameOptions.RenderDistance @@ -469,6 +478,8 @@ endsub: Return Weathers.Blizzard Case 10 ' Thunderstorm Return Weathers.Thunderstorm + Case 11 'Mist + Return Weathers.Mist End Select Return Weathers.Clear End Function @@ -499,6 +510,8 @@ endsub: Return 9 Case Weathers.Thunderstorm Return 10 + Case Weathers.Mist + Return 11 Case Else Return 0 End Select @@ -644,7 +657,7 @@ endsub: Private Shared WeatherOffset As New Vector2(0, 0) Private Shared ObjectsList As New List(Of Rectangle) - Public Shared NoParticlesList() As Weathers = {Weathers.Clear, Weathers.Sunny, Weathers.Fog} + Public Shared NoParticlesList() As Weathers = {Weathers.Clear, Weathers.Sunny, Weathers.Fog, Weathers.Mist} Public Shared Sub DrawWeather(ByVal MapWeather As Weathers) If NoParticlesList.Contains(MapWeather) = False Then