shadow map macos fix
This commit is contained in:
parent
1ff2103a91
commit
584fc662c1
2 changed files with 6 additions and 201 deletions
|
@ -46,6 +46,11 @@ Procedure HandleEventRunningGame()
|
||||||
*ActiveMenu.GameMenu = Menus(CurrentState)
|
*ActiveMenu.GameMenu = Menus(CurrentState)
|
||||||
EndIf
|
EndIf
|
||||||
|
|
||||||
|
CompilerSelect #PB_Compiler_OS
|
||||||
|
CompilerCase #PB_OS_Linux
|
||||||
|
GenerateShadowLayer()
|
||||||
|
CompilerEndSelect
|
||||||
|
|
||||||
; Player movement
|
; Player movement
|
||||||
If KeyboardReleased(#PB_Key_Left) And Player\X > 0
|
If KeyboardReleased(#PB_Key_Left) And Player\X > 0
|
||||||
If TileIsType(#TILESET_TYPE_FLOOR, Player\X-1, Player\Y) Or TileIsType(#TILESET_TYPE_GRASS, Player\X-1, Player\Y)
|
If TileIsType(#TILESET_TYPE_FLOOR, Player\X-1, Player\Y) Or TileIsType(#TILESET_TYPE_GRASS, Player\X-1, Player\Y)
|
||||||
|
@ -56,8 +61,6 @@ Procedure HandleEventRunningGame()
|
||||||
If Player\X < (Cam\X + Cam\Padding) And Cam\X > 0
|
If Player\X < (Cam\X + Cam\Padding) And Cam\X > 0
|
||||||
Cam\X - 1
|
Cam\X - 1
|
||||||
EndIf
|
EndIf
|
||||||
|
|
||||||
GenerateShadowLayer()
|
|
||||||
EndIf
|
EndIf
|
||||||
|
|
||||||
If KeyboardReleased(#PB_Key_Right) And Player\X < #MAP_WIDTH-1
|
If KeyboardReleased(#PB_Key_Right) And Player\X < #MAP_WIDTH-1
|
||||||
|
@ -69,8 +72,6 @@ Procedure HandleEventRunningGame()
|
||||||
If Player\X > (Cam\X + Cam\Width - Cam\Padding) And (Cam\X + Cam\Width) < #MAP_WIDTH-1
|
If Player\X > (Cam\X + Cam\Width - Cam\Padding) And (Cam\X + Cam\Width) < #MAP_WIDTH-1
|
||||||
Cam\X + 1
|
Cam\X + 1
|
||||||
EndIf
|
EndIf
|
||||||
|
|
||||||
GenerateShadowLayer()
|
|
||||||
EndIf
|
EndIf
|
||||||
|
|
||||||
If KeyboardReleased(#PB_Key_Up) And Player\Y > 0
|
If KeyboardReleased(#PB_Key_Up) And Player\Y > 0
|
||||||
|
@ -82,8 +83,6 @@ Procedure HandleEventRunningGame()
|
||||||
If Player\Y< (Cam\Y + Cam\Padding) And Cam\Y > 0
|
If Player\Y< (Cam\Y + Cam\Padding) And Cam\Y > 0
|
||||||
Cam\Y - 1
|
Cam\Y - 1
|
||||||
EndIf
|
EndIf
|
||||||
|
|
||||||
GenerateShadowLayer()
|
|
||||||
EndIf
|
EndIf
|
||||||
|
|
||||||
If KeyboardReleased(#PB_Key_Down) And Player\Y < #MAP_HEIGHT-1
|
If KeyboardReleased(#PB_Key_Down) And Player\Y < #MAP_HEIGHT-1
|
||||||
|
@ -95,8 +94,6 @@ Procedure HandleEventRunningGame()
|
||||||
If Player\Y > (Cam\Y + Cam\Height - Cam\Padding) And (Cam\Y + Cam\Height) < #MAP_HEIGHT-1
|
If Player\Y > (Cam\Y + Cam\Height - Cam\Padding) And (Cam\Y + Cam\Height) < #MAP_HEIGHT-1
|
||||||
Cam\Y + 1
|
Cam\Y + 1
|
||||||
EndIf
|
EndIf
|
||||||
|
|
||||||
GenerateShadowLayer()
|
|
||||||
EndIf
|
EndIf
|
||||||
EndProcedure
|
EndProcedure
|
||||||
; IDE Options = PureBasic 4.51 (Linux - x64)
|
; IDE Options = PureBasic 4.51 (Linux - x64)
|
||||||
|
|
File diff suppressed because one or more lines are too long
Loading…
Reference in a new issue