Skip to content

Commit

Permalink
Merge pull request #21 from fellowship-of-the-roms/Expanded-Tilesets
Browse files Browse the repository at this point in the history
384 tilesets and gateless connections
  • Loading branch information
vulcandth committed Apr 6, 2024
2 parents cc7fbf0 + 43eebad commit b7fb9b0
Show file tree
Hide file tree
Showing 37 changed files with 1,144 additions and 450 deletions.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@
# compiled graphics
*.1bpp
*.2bpp
*.2bpp.vtiles2
*.2bpp.vtiles4
*.2bpp.vtiles5
*.lz
*.gbcpal
*.dimensions
Expand Down
10 changes: 10 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,7 @@ crystal_vc: pokecrystal.patch
clean: tidy
find gfx \
\( -name "*.[12]bpp" \
-o -name "*.2bpp.vtiles[245]" \
-o -name "*.lz" \
-o -name "*.gbcpal" \
-o -name "*.sgb.tilemap" \) \
Expand Down Expand Up @@ -267,6 +268,15 @@ gfx/mobile/stadium2_n64.2bpp: tools/gfx += --trim-whitespace
$(if $(tools/gfx),\
tools/gfx $(tools/gfx) -d1 -o $@ $@)

%.2bpp.vtiles2: %.2bpp
$Qtools/sub_2bpp.sh $< 128 > $@

%.2bpp.vtiles4: %.2bpp
$Qtools/sub_2bpp.sh $< 256 128 > $@

%.2bpp.vtiles5: %.2bpp
$Qtools/sub_2bpp.sh $< 128 128 > $@

%.gbcpal: %.png
$(RGBGFX) -c embedded -p $@ $<

Expand Down
11 changes: 11 additions & 0 deletions constants/map_data_constants.asm
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,17 @@ DEF MAP_PALETTE rb ; 7
DEF MAP_FISHGROUP rb ; 8
DEF MAP_LENGTH EQU _RS

; map landmark name signs
const_def
const SIGN_WOOD
const SIGN_CITY
const SIGN_FOREST
const SIGN_CAVE
const SIGN_ROUTE
const SIGN_WATER
const SIGN_BUILDING
DEF NUM_SIGNS EQU const_value

; map environments (wEnvironment)
; EnvironmentColorsPointers indexes (see data/maps/environment_colors.asm)
const_def 1
Expand Down
2 changes: 1 addition & 1 deletion constants/map_object_constants.asm
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ DEF OBJECT_PAL_INDEX rb ; 21
rb_skip 6
DEF OBJECT_LENGTH EQU _RS
DEF NUM_OBJECT_STRUCTS EQU 13 ; see wObjectStructs
DEF FIRST_VRAM1_OBJECT_STRUCT EQU 10
DEF FIRST_VRAM1_OBJECT_STRUCT EQU 8

; object_struct OBJECT_DIRECTION values
DEF OW_DOWN EQU DOWN << 2
Expand Down
2 changes: 1 addition & 1 deletion constants/tileset_constants.asm
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@
DEF NUM_TILESETS EQU const_value - 1

; wTileset struct size
DEF TILESET_LENGTH EQU 14
DEF TILESET_LENGTH EQU 18

; roof length (see gfx/tilesets/roofs)
DEF ROOF_LENGTH EQU 9
Expand Down
1 change: 1 addition & 0 deletions data/maps/setup_script_pointers.asm
Original file line number Diff line number Diff line change
Expand Up @@ -54,3 +54,4 @@ MapSetupCommands:
add_mapsetup DisableDynPalUpdates ; 2f
add_mapsetup EnableDynPalUpdates ; 30
add_mapsetup EnableDynPalUpdatesNoApply ; 31
add_mapsetup DeferredLoadMapGraphics ; 32
1 change: 1 addition & 0 deletions data/maps/setup_scripts.asm
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,7 @@ MapSetupScript_Connection:
mapsetup LoadBlockData
mapsetup LoadMapTileset
mapsetup SaveScreen
mapsetup DeferredLoadMapGraphics
mapsetup DecompressMetatiles
mapsetup LoadMapObjects
mapsetup FadeToMapMusic
Expand Down
4 changes: 3 additions & 1 deletion data/tilesets.asm
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
MACRO tileset
dba \1GFX, \1Meta, \1Coll, \1Attr
dba \1vTiles2GFX
dw \1vTiles4GFX, \1vTiles5GFX
dba \1Meta, \1Coll, \1Attr
dw \1Anim
ENDM

Expand Down
Loading

0 comments on commit b7fb9b0

Please sign in to comment.