44 Commits
Author SHA1 Message Date
JaceCear 82dabc2f35 Extend INCPAL use in SA1. (#265)
* Align water_effects.h with SA3
2026-05-07 21:13:25 +01:00
Oliver Bell cc2110e85d Move SA1 to root
* name some engine globals (gSpriteTransform*)
* move the whole sa1 directory to the root
2026-05-02 23:39:11 +01:00
Oliver Bell c1de9a3a13 sa2: migrate data into sa2 sub directory 2026-04-03 09:47:08 +01:00
JaceCear 9da592bb8e Make palettes format-independent, and other improvments (#242)
* Remove unused RED|GREEN|BLUE_VALUE macros

* preproc: Add basic support for loading .pal files directly via INCPAL()

* Some potential boss_8 render fixes and misc. stuff

* Use INCPAL macro in src/data/sprite_animation.c (but that file's is unused rn?)

* Fix non-main-Makefiles not using preproc properly

* Remove all INCBIN(.gbapal) uses with INCPAL(.pal) in ./src

* Move gSpritePalettes to C

* Rename palette to time_display_singlepak.pal

* Remove obj_palettes.inc

* Use ColorRaw for known palettes

* Fix time_display match

* Rename palette to sound_test_bg.pal

* Add comment and scratch to sub_80236C8

* Use PALETTE_LEN_4BPP

* Document a vocal sample name. Thanks 'Asal (in Harmony)' for letting us know!

* Document palette names in /graphics

* Fix boss palette names

* Renmae to sBoss7Palettes

* Some Boss 7 documentation

* Add ShredWindowsGarbage to win32

* Make PLTT a Color[] in non-vanilla builds

* Make Tilemap use INCPAL
2026-03-17 23:00:00 +00:00
Oliver Bell 79b856b52d vc: complete match 2025-09-21 15:34:26 +01:00
Oliver Bell 8a6a4f0c62 japan: match animation frames 2025-09-09 01:31:35 +01:00
Oliver Bell be48808323 japan: add japan tiles to obj_tiles_4bpp 2025-09-09 01:12:13 +01:00
Oliver Bell 57bd63de86 japan: add japan animation tiles 2025-09-07 23:08:05 +01:00
Oliver Bell e6caf03f91 japan: match obj palettes 2025-09-07 22:42:06 +01:00
BlueSpeedster 680ad42796 Update UI Code (#213)
* Correct Score X Pos

* Set up Ring Container's OAM Attribute 1 to a Non-Hardcoded Number

* Correct Ring Container X Pos + Set new variables for Sprite Tile Data

* rename palette file + remove leftover labels

* Update UI 1Up Icon Palette name
2025-07-13 21:23:19 +02:00
1bc34d0ac8 Move Animation data to C, fix native sdl build (#157)
* Remove and move comments to the correct procedures

* Fix regular SDL compilation

* Move animation data from Asm to C

* Layout the anim macros in a common way. Add Big Endian support to them (I think?)

* add CI for sdl objs, fix some of the build on linux

* make native macos work

---------

Co-authored-by: bitten2up <bitten2up@courvix.com>
Co-authored-by: Oliver Bell <freshollie@gmail.com>
2024-10-10 01:07:04 +01:00
JaceCear cd970ffda0 Minor adjustments for stage select (#149)
* Minor adjustments for stage select

* Document RenderText

* Remove old, unused tilesets. Add debug_text tileset
2024-07-12 20:58:34 +02:00
JaceCearandOliver Bell fcbaf7b7c1 Boss 9 (#146)
* Move Boss_9 data to C

* sRGB_080D8E20 hex -> dec

* First pass on CreateTrueArea53Boss

* Move CreateTrueArea53Boss into non-matching

* Rename remaining MoveBossPositionFuncs

* Move TrueArea53BossMove into non-match

* Match Task_EggmanKidnapsVanilla

* Match Task_TrueArea53BossMain

* Match sub_804D8E0

* Match Task_804D9DC

* Match Task_804DB34

* More Boss 9 progress

* Make upper bound in PseudoRandBetween() exclusive, since many calls suggest this being the original pattern

* Match sub_804E078

* Move sub_804E15C into non-matching

* Start sub_804E4CC

* Move sub_804E4CC into non-match

* Match sub_804E66C

* Match sub_804E74C

* Match sub_804E974

* Move sub_804F1EC into non-matching

* Match sub_804F47C

* Match sub_804F5BC

* More progress

* Move sub_804F850 into non-matching

* Match sub_804FD58

* Match sub_804FE24, sub_804FEFC and sub_804FF9C

* Move sub_8050030 and sub_8050104 into non-matching

* Temporarily move sub_8050104 and sub_80501D4 into non-matching

* Almost match sub_8050958

* Remove boss_9.s

* Remove old stubs

* Minor cleanup and fix crash in Zone 3's background

* Add missing pointer refs in CreateTrueArea53Boss

* Almost match sub_80505B8 (basically on-par with sub_80501D4

* Ollie matched sub_80501D4 and sub_80505B8

Co-authored-by: Oliver Bell <freshollie@gmail.com>

* Tilemap unknown_stars -> music_plant_moving_stars

* Add DEBUG macro

* Progress on CreateTrueArea53Boss

* Some fixes for CreateTrueArea53Boss

---------

Co-authored-by: Oliver Bell <freshollie@gmail.com>
2024-06-19 12:37:24 +02:00
JaceCearandOliver Bell ea91089217 Boss 8 (#145)
* Unify adding entries to GFX queue

* Match CreateSuperEggRoboZ

* Some screen shake doc

* Move Task_804AB24 into non-matching

* Match sub_804AD68

* Move sub_804AE40 into non-matching

* move sub_804B2EC into non-match

* Match sub_804B43C

* Add SWITCH_ARM_VARIANT macro

* Match sub_804B594

* Match sub_804B734

* Match sub_804B984

* Match sub_804BAC0

* Match sub_804C5B8

* Match sub_804C3AC

* Move sub_804C240 to non-matching

* Match sub_804C080

* Match sub_804BE6C

* Move sub_804BC44 into non-matching. Remove boss_8_2.c

* Match sub_8031138 by making the generated code less efficient. Yay.

* Do a pass on sub_8004E14 and move it into non-matching

* Merge sprite_2.c and sprite_3.c into sprite.c

* Match sub_8023B5C

* Progress on sub_804AE40 by Ollie

Co-authored-by: Oliver Bell <freshollie@gmail.com>

* Merge animation_commands.c into sprite.c

* gUnknown_03002794 -> gRefSpriteTables

* Replace UB_FIX -> BUG_FIX; General cleanup

* sub_8004518 -> Base10DigitsToHexNibbles

* Move animation_commands_bg.c into background.c

---------

Co-authored-by: Oliver Bell <freshollie@gmail.com>
2024-06-09 11:04:44 +02:00
Oliver Bell b035c69cce finish boss 7 data 2024-05-27 08:21:46 +08:00
Oliver Bell 900c31029a create sdl_win32 build, add platform builds to CI (#144)
* fixes for 64bit build
* create sdl_win32 target
2024-05-24 03:10:04 +01:00
JaceCear 878cd1c504 Credits for this project (#140)
* Add defsym NON_MATCHING to ASFLAGS

* Use FLAGS_ macros instead of numbers

* Move debug_text_printer.h

* Add DCCredits

* Some formatting, some minor fixes

* Introduce ENABLE_DECOMP_CREDITS symbol

* More adjustments to the credits. Edit the Q_MUL macro

* Slight position adjustment for Sonic

* Minor fixes. Add note for weird Mod() compiler error

* Minor spelling mistake
2024-05-12 20:21:43 +02:00
Oliver Bell d4b5f365f4 extract boss 6 data, start documenting boss 6 2024-05-07 18:26:30 +01:00
BlueSpeedster 0e92bf9b1d Initial code required to build Japanese ROM (#135)
* Update UI Positions of Timer/1-Up
* Update results.c
2024-04-19 17:00:12 +01:00
JaceCearandOliver Bell 5a7cb638c1 Boss 3 (#133)
* Document Boss 3 pal data

* Add CreateEggTotem and move it into non-matching

* Match Task_803F3E8

* Match sub_803F4B8

* Match sub_803F5E0

* Start sub_803F698 and put it into non-matching

* Match sub_803F698

* Introduce AnimCmdResult

* Match sub_803F878

* Move EggTotemMove into non-matching

* Move sub_803FB88 into non-match

* Move sub_803FC14 into non-match

* Split boss_3.s

* Formatter

* Some progress

* Match sub_8040D74

* Match sub_8040E78

* Progress on sub_8040F14

* Match sub_8040F14

* Match Task_EggTotemMain and TaskDestructor_EggTotemMain

* Match Task_8041138

* Match multiple smaller procedures

* Reorganize boss_3 files

* Fix pointer references

* Progress on CreateEggTotemBullet

* Match CreateEggTotemBullet

* Progress on Task_EggTotemBullet

* Match Task_EggTotemBullet

* Add clarifying comment to Task_EggTotemBullet

* Add clarifying comment to Task_EggTotemBullet

* Remove bull_3_bullet.s

* sub_80122DC -> Player_UpdateHomingPosition

* Make the formatter happy

* Some cleanup in special_ring.c

* Progress on sub_8040B30

* Progress on sub_8040B30 (90.90%)

* Move sub_8040B30 into non-match

* Progress on sub_8040A00

* Move sub_8040A00 into non-match

* Match sub_80408C4

* Remove old comments

* Minor adjustment

* Ollie matched sub_8040A00

Co-authored-by: Oliver Bell <freshollie@gmail.com>

* Start sub_80407A4 and fix data detail of EggTotemDataA in sub_80408C4

* Progress on sub_80407A4

* Progress on sub_804063C. sub_804063C -> boss_3_2.c. Put sub_80407A4 into non-match

* Match sub_804063C

* Remove comments in sub_804063C

* Start sub_803FF44

* Remove degrees icon, because it trips up CI/CD

* First attempt at matching sub_803FF44

* Progress on sub_803FF44

* Progress on sub_803FF44

* Move sub_803FF44 into non-match

* Remove boss_3_2.c

* Move data into boss_3.c and remove boss_3.s

* Move structs into boss_3.c

* Name sprites properly

* Remove boss_3.s from ldscript.txt

* Fix build

* Formatter...

* Ollie matched sub_80407A4

Co-authored-by: Oliver Bell <freshollie@gmail.com>

* Fix the degrees UTF-8 thing for the build again

* Ollie matched sub_8040B30

Co-authored-by: Oliver Bell <freshollie@gmail.com>

* Fix var name

* Fix build

---------

Co-authored-by: Oliver Bell <freshollie@gmail.com>
2024-04-07 20:15:54 +02:00
JaceCear 01b12effbe input_buffer.c and Boss 4. (#129)
* Start sub_800DF8C

* Match most of sakit/input_buffer.c

* Very minor progress on sub_800DF8C

* Match Boss 4's bombs and debris

* Match TaskDestructor_AeroEggMain

* Match more Boss4 procedures

* Match sub_80424EC

* Match sub_80423EC

* Split AeroEgg struct into main/sub and match AeroEggResetPos

* Match sub_804217C

* Remove addresses

* Document some of AeroEggSub

* Add AE_UPDATE_PART_DEFEATED macro

* Rename to Player_DisableInputAndBossTimer/Player_DisableInputAndBossTimer_FinalBoss

* Get close to matching sub_8042024

* Check for boss lives properly

* sub_8042024 -> AeroEgg_InitPartsDefeated; move it into nonmatch

* Start sub_8041D34

* sub_8041D34 -> gTileInfoBossScrews

* Progress on sub_8041D34

* Progress on sub_8041D34

* Move sub_8041D34 into non-match

* Remove redundant struct copy

* Match sub_8041C48

* More Boss 4 procedures

* Get sub_8041A08 to ~91% and put into non-match

* Add Q/I aliases

* Add some comments to aliases, for consistency

* Match sub_8041A08

* Use Q/I macros

* Get sub_8041880 to 85.03% and move it into non-match

* Match Task_AeroEggExploding

* Match CreateAeroEgg. Remove boss_4.s

* Task_8042AB0 -> Task_AeroEggBombHitGround

* Progress on sub_800DF8C

* Progress on sub_800DF8C and move it into non-match. Remove input_buffer.s

* Remove asm/input_buffer.o from ldscript.txt

* Minor cleanup in sprite_2.c

* gUnknown_080D7F54 -> sPalAeroEggHit

* Rename AeroEggResetPos back to AeroEggMove
2024-02-18 11:14:58 +01:00
Oliver Bell 0f28ad1369 document boss2 2024-01-28 11:23:37 +00:00
JaceCearandOliver Bell 5b55841b18 BriBaSA_ex - Initial Commit (#123)
* c_header_parser: Add EQUALS and some compatibility fixes.

* Add stage_info.txt files to all maps

* Filter BriBaSA_ex as long as it doesn't have a Makefile

* Add fixes for the tokenizer

* Initial commit for BriBaSA_ex

* Update stage info

* Add spawn pos being shown as player character, add 'Go to spawn pos' keyboard shortcut, add ability to display item boxes.

* Renamed stage_info.txt -> metadata.txt, because regular tilemaps will make use of them

* BriBaSA_ex: Set camera to spawn pos when loading a map. Load all map paths on init. Cleanup.

* Implement drawing of most interactables

* Fix main not compiling when Raylib wasn't compiled before

* Add keyboard button controls and some cleanup

* Rename a few IA and anim constants

* Rename a few constants

* Add error output for unknown names when converting CSV->Bin using epos

* Add TILE_DIM and TILES_PER_METATILE, and some cleanup

* Move some procedures out of epos.c

* Minor cleanup

* Minor cleanup in csv_conv.c

* More cleanup and documentation

* More cleanup

* Move shared libraries inside tools to their own directories

* Remove redundant versions of shared libraries

* Fix warnings

* Add library binaries to .gitignore

* Add BriBaSA_ex Makefile

* Fix compilation

* Load entity data from CSV files and display them

* Fix some var and const names

* Fix includes

* Re-add Makefile for csv_conv

* Generalize drawing of IA textures and bounding boxes

* Split the code into multiple modules

* Rename a few IAs

* Rename Giant Propeller -> Propeller

* More adjustments for Propeller renaming

* BriBaSA_ex: Some restructuring

* Fix warning

* Add texture.c to build.bat

* Fix build errors from renaming IAs

* More restructuring

* Move constants to header file

* Cleanup

* Open buttons through 'UiElement()'

* Uncomment redundant call to FileExists

* Fix build

* BriBaSA: Fix crash

* Streamline entity data layout

* Split ring graphics into individual frames

* Make entities clickable

* Display metadata of highlit entity

* Print entity type if an Entity has one

* Fix IA bounding boxes

* Implement saving entities when clicking on 'Save Map'

* Add EntityData* to EntityDataPointer union

* Allow entity data to be edited

* Add IS_USER_KEY_PRESSED_ macros. Use them for the spawn position

* Fix gcc warnings

* Update readme

* Fix GCC warnings

* Fix Makefile compilation for Linux

* Update epos to use CsvEntityType

* Exclude tools dir when formatting

* Format...

* fix linux build and some makefile improvements

Co-authored-by: Oliver Bell <freshollie@gmail.com>

* fix formatter, undo some debug stuff

Co-authored-by: Oliver Bell <freshollie@gmail.com>

* fix CI

Co-authored-by: Oliver Bell <freshollie@gmail.com>

* try this

Co-authored-by: Oliver Bell <freshollie@gmail.com>

* this is better

Co-authored-by: Oliver Bell <freshollie@gmail.com>

* Replace MSVC-exclusive file functions

* remove comment

Co-authored-by: Oliver Bell <freshollie@gmail.com>
---------

Co-authored-by: Oliver Bell <freshollie@gmail.com>
2023-12-10 12:49:22 +01:00
Oliver Bell da062be3b2 finish boss1 2023-11-21 00:08:47 +00:00
JaceCear 4894d4930e Documentation and decompile most of Zone 7's backgrounds (#110)
* Start StageBgUpdateZone7Acts12

* Rename stage BG related procedures

* Match CreateStageBg_Zone7

* Rename gUnknown_03001884 -> gComputedBgBuffer

* Rename gUnknown_03005590 -> gStageTime

* Progress on Zone7BgUpdate_Outside

* Almost match Zone7BgUpdate_Outside

* Move Zone7BgUpdate_Outside into nonmatch

* Progress on Zone7BgUpdate_Inside, added some to-be-removed debug code

* Add link of Zone7BgUpdate_Inside

* Move Zone7BgUpdate_Inside into nonmatching (logic is OK)

* Rename gComputedBgBuffer -> gBgOffsetsHBlank

* Merge stage/background/zone_7_0.c and zone_7_1.c

* Give palette proper var name
2023-09-08 00:53:22 +02:00
Oliver Bell 9458841e48 finish boss5, document some attributes, extract data 2023-08-24 22:12:14 +01:00
JaceCear 88ee2b2928 Cleanup/Documentation Round 1 (#79)
* Rename PlayerCharacterIdleAnims to gPlayerCharacterIdleAnims

* Match sub_8011B88. Remove player_callbacks_0.s

* Simplify gBgAffineRegs. sub_8003914 (Lines 163,167) shows this way is probably more correct

* General cleanup

* Avoid using apostrophes in ASM comments, b/c of VS's syntax highlighting

* Shorten Enemy and IA initialization proc names

* Create_ -> CreateEntity_

* Remove a few asm incbins
2023-05-23 08:25:18 +02:00
Oliver Bell c0fb4214ca get closer to europe match 2023-05-13 12:58:29 +01:00
Oliver Bell 04a12bd4a5 start on europe match 2023-05-11 21:10:42 +01:00
Oliver Bell c659d318f9 start moving stage_ui data 2023-04-29 14:08:49 +01:00
Oliver Bell 7c27d0f097 restructure anims folder again 2023-03-08 12:44:32 +00:00
JaceCear e4ad2ec224 Add script/gbagfx changes 2023-03-04 01:44:53 +01:00
JaceCear 5b5bc33b83 Replace split obj images with non-split images 2023-03-04 01:31:04 +01:00
JaceCear 58aaf3f595 Add -ignore_trailing option to gbagfx 2023-02-26 00:53:28 +01:00
JaceCearandOliver Bell 3c9893e8b3 Extract LF tilesets and some game data, more docs (#54)
Co-authored-by: Oliver Bell <freshollie@gmail.com>
2023-02-17 12:22:50 +00:00
Oliver Bell e25b885c4f refactor graphics make rules 2023-02-13 13:07:51 +00:00
Oliver Bell 0d25bff10c finish decompiling collect rings time display 2023-01-20 15:34:54 +00:00
JaceCearandOliver Bell 238d730c49 Extract and match all 4bpp object frames (#31)
* Added obj palette data

* Add dumped obj graphics

* build graphics as part of pipeline

* update readme

* remove animation constant macros

Co-authored-by: Oliver Bell <freshollie@gmail.com>
2022-12-19 12:17:42 +00:00
Oliver Bell 5ceb3dc8c1 more data analysis, extract gSpriteTables 2022-09-02 15:30:48 +00:00
Oliver Bell 58990cd0bd extract build info and sound_test palette data 2022-09-02 14:21:09 +00:00
Oliver Bell 3abc9a231c cleanup 2022-06-01 15:46:03 +01:00
Oliver Bell c247b225a0 rename gAnimations 2022-06-01 15:42:49 +01:00
Oliver BellandJaceCear 8afc090587 dissassemble animations
Co-authored-by: JaceCear <11230293+JaceCear@users.noreply.github.com>
2022-06-01 14:22:12 +01:00
Oliver Bell 6294ff4630 begin extracing title screen data 2022-05-10 21:53:16 +01:00