Fixed wrong bugcatchingconstest item pickup type..

By adding the IsOutside map Property
This commit is contained in:
JappaWakka 2023-04-01 09:15:57 +02:00
parent ba07491069
commit 17ef30605c
4 changed files with 21 additions and 2 deletions

View File

@ -1,5 +1,5 @@
{"Level"{LEV[{"Name"{str[National Park]}}{"MusicLoop"{str[bugcontest]}}]}}
{"Actions"{LEV[{"CanTeleport"{bool[0]}}{"CanDig"{bool[0]}}{"CanFly"{bool[0]}}{"EnvironmentType"{int[0]}}{"Weather"{int[0]}}{"Lighting"{int[0]}}{"BugCatchingContest"{str[nationalpark\end_contest_menu,nationalpark\sport_balls,Sport Balls]}}]}}
{"Actions"{LEV[{"CanTeleport"{bool[0]}}{"CanDig"{bool[0]}}{"CanFly"{bool[0]}}{"IsOutside"{bool[1]}}{"EnvironmentType"{int[0]}}{"Weather"{int[0]}}{"Lighting"{int[0]}}{"BugCatchingContest"{str[nationalpark\end_contest_menu,nationalpark\sport_balls,Sport Balls]}}]}}
Floor:
Grass:

View File

@ -1062,7 +1062,7 @@
#Region "Checks"
Private Shared Function IsOutside() As Boolean
If Screen.Level.CanFly = True And Screen.Level.CanDig = False And Screen.Level.CanTeleport = True Then
If Screen.Level.IsOutside = True OrElse Screen.Level.CanFly = True And Screen.Level.CanDig = False And Screen.Level.CanTeleport = True Then
Return True
End If
Return False

View File

@ -51,6 +51,7 @@ Public Class Level
Private _hiddenabilitychance As Integer = 0
Private _lightingType As Integer = 0
Private _isSafariZone As Boolean = False
Private _isOutside As Boolean = False
Private _isBugCatchingContest As Boolean = False
Private _bugCatchingContestData As String = ""
@ -538,6 +539,18 @@ Public Class Level
End Set
End Property
''' <summary>
''' Overrides whether the map is outside. Affects item pickup interaction.
''' </summary>
Public Property IsOutside As Boolean
Get
Return Me._isOutside
End Get
Set(value As Boolean)
Me._isOutside = value
End Set
End Property
''' <summary>
''' Whether the map is a part of the Bug Catching Contest. This changes the Battle Menu and the Menu Screen.
''' </summary>

View File

@ -1086,6 +1086,12 @@
Screen.Level.IsSafariZone = False
End If
If TagExists(Tags, "IsOutside") = True Then
Screen.Level.IsOutside = CBool(GetTag(Tags, "IsOutside"))
Else
Screen.Level.IsOutside = False
End If
If TagExists(Tags, "BugCatchingContest") = True Then
Screen.Level.IsBugCatchingContest = True
Screen.Level.BugCatchingContestData = CStr(GetTag(Tags, "BugCatchingContest"))