Fix for StrengthRock softlock
This commit is contained in:
parent
ad6c008a98
commit
9a7543fb33
|
@ -431,6 +431,9 @@
|
||||||
|
|
||||||
If Me.Moved <= 0.0F Then
|
If Me.Moved <= 0.0F Then
|
||||||
Me.Moved = 0.0F
|
Me.Moved = 0.0F
|
||||||
|
If Me.EntityID.ToLower = "strengthrock" Then
|
||||||
|
CType(Screen.Camera, OverworldCamera).IsPushingStrengthRock = False
|
||||||
|
End If
|
||||||
|
|
||||||
Me.Position.X = CInt(Me.Position.X)
|
Me.Position.X = CInt(Me.Position.X)
|
||||||
Me.Position.Z = CInt(Me.Position.Z)
|
Me.Position.Z = CInt(Me.Position.Z)
|
||||||
|
|
|
@ -62,10 +62,14 @@
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Public Overrides Sub Update()
|
Public Overrides Sub Update()
|
||||||
If Me.ActivateScript = True And Screen.Camera.Position.X = Me.Position.X And Screen.Camera.Position.Z = Me.Position.Z And CInt(Screen.Camera.Position.Y) = CInt(Me.Position.Y) Then
|
If CType(Screen.Camera, OverworldCamera).IsPushingStrengthRock = False Then
|
||||||
Screen.Camera.StopMovement()
|
If Me.ActivateScript = True And Screen.Camera.Position.X = Me.Position.X And Screen.Camera.Position.Z = Me.Position.Z And CInt(Screen.Camera.Position.Y) = CInt(Me.Position.Y) Then
|
||||||
ActivateScript = False
|
Screen.Camera.StopMovement()
|
||||||
TriggerScript(False)
|
ActivateScript = False
|
||||||
|
TriggerScript(False)
|
||||||
|
End If
|
||||||
|
Else
|
||||||
|
TriggeredScriptBlock = False
|
||||||
End If
|
End If
|
||||||
|
|
||||||
MyBase.Update()
|
MyBase.Update()
|
||||||
|
|
|
@ -85,6 +85,7 @@
|
||||||
newPosition.Z += Screen.Camera.GetMoveDirection().Z
|
newPosition.Z += Screen.Camera.GetMoveDirection().Z
|
||||||
|
|
||||||
If CheckCollision(newPosition) = True Then
|
If CheckCollision(newPosition) = True Then
|
||||||
|
CType(Screen.Camera, OverworldCamera).IsPushingStrengthRock = True
|
||||||
Me.Moved = 1
|
Me.Moved = 1
|
||||||
Me.FaceDirection = Screen.Camera.GetPlayerFacingDirection()
|
Me.FaceDirection = Screen.Camera.GetPlayerFacingDirection()
|
||||||
SoundManager.PlaySound("destroy", False)
|
SoundManager.PlaySound("destroy", False)
|
||||||
|
|
|
@ -32,6 +32,7 @@ Public Class OverworldCamera
|
||||||
Public YawLocked As Boolean = False
|
Public YawLocked As Boolean = False
|
||||||
Public ThirdPersonOffset As Vector3 = New Vector3(0F, 0.3F, 1.5F)
|
Public ThirdPersonOffset As Vector3 = New Vector3(0F, 0.3F, 1.5F)
|
||||||
Public IsSliding As Boolean = False
|
Public IsSliding As Boolean = False
|
||||||
|
Public IsPushingStrengthRock As Boolean = False
|
||||||
|
|
||||||
'Debug variables
|
'Debug variables
|
||||||
Public oldDate As Date = Date.Now
|
Public oldDate As Date = Date.Now
|
||||||
|
@ -796,7 +797,7 @@ Public Class OverworldCamera
|
||||||
Move(walkSteps)
|
Move(walkSteps)
|
||||||
Else
|
Else
|
||||||
'Walked against something, set player transparent
|
'Walked against something, set player transparent
|
||||||
If Screen.Level.Surfing = False Then
|
If Screen.Level.Surfing = False AndAlso IsPushingStrengthRock = False Then
|
||||||
If _thirdPerson = True Then
|
If _thirdPerson = True Then
|
||||||
If _didWalkAgainst = True Then
|
If _didWalkAgainst = True Then
|
||||||
Screen.Level.OwnPlayer.Opacity = 0.5F
|
Screen.Level.OwnPlayer.Opacity = 0.5F
|
||||||
|
|
Loading…
Reference in New Issue