2011-08-20 14:49:54 +02:00
|
|
|
|
|
2011-08-20 18:30:12 +02:00
|
|
|
|
#DATA_PATH = "../data/"
|
2011-08-20 22:37:31 +02:00
|
|
|
|
#TILE_SIZE = 20
|
2011-08-21 12:42:55 +02:00
|
|
|
|
#SHADOW_RADIUS = 6
|
2011-08-21 11:48:49 +02:00
|
|
|
|
#MAP_WIDTH = 120
|
|
|
|
|
#MAP_HEIGHT = 120
|
2011-08-21 02:16:30 +02:00
|
|
|
|
; TODO: Aus der XML lesen
|
2011-08-20 18:18:52 +02:00
|
|
|
|
|
2011-08-21 14:31:28 +02:00
|
|
|
|
; Tileset entries
|
|
|
|
|
#TILESET_TYPE_PLAYER = 0
|
|
|
|
|
#TILESET_TYPE_FLOOR = 1
|
|
|
|
|
#TILESET_TYPE_WALL = 2
|
|
|
|
|
#TILESET_TYPE_SOLID = 3
|
|
|
|
|
#TILESET_TYPE_GRASS = 4
|
|
|
|
|
|
2011-08-21 16:51:16 +02:00
|
|
|
|
; Player directions
|
|
|
|
|
#PLAYER_DIR_UP = 0
|
2011-08-21 17:58:18 +02:00
|
|
|
|
#PLAYER_DIR_RIGHT = 1
|
|
|
|
|
#PLAYER_DIR_DOWN = 2
|
|
|
|
|
#PLAYER_DIR_LEFT = 3
|
2011-08-21 16:51:16 +02:00
|
|
|
|
|
2011-08-20 14:49:54 +02:00
|
|
|
|
; Global variables
|
|
|
|
|
Global Fullscreen = 0
|
2011-08-20 17:49:22 +02:00
|
|
|
|
Global Title.s = "ESCape - Build " + Str(#PB_Editor_BuildCount)
|
2011-08-20 14:49:54 +02:00
|
|
|
|
Global Screen.ScreenDimension\width = 800
|
|
|
|
|
Screen.ScreenDimension\height = 600
|
|
|
|
|
|
2011-08-20 20:15:44 +02:00
|
|
|
|
; Player
|
2011-08-21 16:51:16 +02:00
|
|
|
|
Global Player.Player\X = 0
|
|
|
|
|
Player.Player\Y = 0
|
|
|
|
|
Player.Player\TileNumber = 0
|
|
|
|
|
Player.Player\Direction = #PLAYER_DIR_RIGHT
|
2011-08-20 20:15:44 +02:00
|
|
|
|
|
2011-08-20 22:37:31 +02:00
|
|
|
|
; Camera
|
|
|
|
|
Global Cam.Camera\X = 0
|
|
|
|
|
Cam.Camera\Y = 0
|
2011-08-20 23:51:33 +02:00
|
|
|
|
Cam.Camera\Width = (Screen\Width/#TILE_SIZE)-1
|
|
|
|
|
Cam.Camera\Height = (Screen\Height/#TILE_SIZE)-1
|
|
|
|
|
Cam.Camera\Padding = 10
|
2011-08-20 20:15:44 +02:00
|
|
|
|
|
2011-08-20 14:49:54 +02:00
|
|
|
|
NewMap GameStates.GameState()
|
|
|
|
|
Global NewMap Menus.GameMenu()
|
|
|
|
|
Global CurrentState.s = "MAIN_MENU"
|
|
|
|
|
Global *ActiveMenu.GameMenu
|
|
|
|
|
|
|
|
|
|
; Fonts
|
2011-08-20 20:15:44 +02:00
|
|
|
|
Global Font_H1 = LoadFont(1, "Arial", 40, #PB_Font_Bold)
|
2011-08-20 17:40:18 +02:00
|
|
|
|
Global Font_H2 = LoadFont(2, "Verdana", 18)
|
2011-08-21 02:16:30 +02:00
|
|
|
|
Global Font_H3 = LoadFont(3, "Verdana", 10)
|
2011-08-20 17:40:18 +02:00
|
|
|
|
|
|
|
|
|
; Graphics
|
2011-08-20 20:14:22 +02:00
|
|
|
|
Global GFXLogo.i
|
|
|
|
|
Global GFXTileset.i
|
2011-08-21 14:31:28 +02:00
|
|
|
|
Global Dim Tileset.TilsetEntry(36)
|
2011-08-21 17:59:16 +02:00
|
|
|
|
Global ShadowOfDarkness.i
|
2011-08-20 18:18:52 +02:00
|
|
|
|
|
|
|
|
|
; Sounds
|
2011-08-20 21:40:04 +02:00
|
|
|
|
Global MenuSoundStarted = 0
|
2011-08-20 19:11:45 +02:00
|
|
|
|
LoadSound(0, #DATA_PATH + "sound/menu_change.wav")
|
|
|
|
|
LoadSound(1, #DATA_PATH + "sound/menu_select.wav")
|
2011-08-20 21:40:04 +02:00
|
|
|
|
LoadSound(2, #DATA_PATH + "sound/title_song.wav")
|
2011-08-20 22:37:31 +02:00
|
|
|
|
|
2011-08-21 12:42:55 +02:00
|
|
|
|
; Map
|
2011-08-20 22:52:29 +02:00
|
|
|
|
Global Dim TileMap.Tile(#MAP_WIDTH, #MAP_HEIGHT)
|
2011-08-21 17:59:16 +02:00
|
|
|
|
Global Dim ShadowMap.Shadow(#MAP_WIDTH, #MAP_HEIGHT)
|
|
|
|
|
; IDE Options = PureBasic 4.51 (Linux - x64)
|
|
|
|
|
; CursorPosition = 47
|
|
|
|
|
; FirstLine = 11
|
|
|
|
|
; EnableXP
|
|
|
|
|
; EnableCompileCount = 0
|
2011-08-21 17:59:26 +02:00
|
|
|
|
; EnableBuildCount = 0
|