| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
|
|
|
|
|
|
|
| |
The screensaver used to return through .renderArrows (reloading the font,
re-clearing/re-arming OAM+LCDC -- all pointless when arrows are hidden) plus an
idle DelayFrame between every page, giving a ~1-frame hitch each screen. Add
.afterMove: in saver mode it skips all that and dispatches the next direction
immediately, so in-map pages chain back-to-back and the camera scrolls
continuously. Manual EXPLORE still redraws its arrows as before.
(Map-boundary crossings still briefly freeze while LoadMapData reloads the
neighbour -- inherent to the full map load; a same-tileset fast path would be a
larger, riskier change.)
|
| |
|
|
|
|
| |
~25s: boot -> SL0P menu -> EXPLORE camera flying north (Pallet -> Route 1 ->
Viridian, seamless map crossings + direction arrows) -> A-warp the trainer to
the viewed tile. Captured via deterministic input-replay + frame-capture.
|
| |
|
|
|
|
| |
~20s, captured via deterministic input-replay + frame-capture. Also mark
*.gif binary in .gitattributes so git stops CRLF-mangling the GIF blob
(the previous demo.gif was corrupted by LF normalization).
|
| |
|
|
| |
Captured via the emulator's new deterministic input-replay + frame-capture.
|
| |
|
|
|
|
|
|
| |
The instant cheats (MONEY/HEAL/COINS/BADGES/DEX/MAXTEAM/TEACH/HMS/REPEL,
NOWILD, and ITEMS-give) dropped you straight back to the menu with no sign
anything happened. Add SlopConfirm: play the item jingle and flash a centred
message box for ~0.8s before returning. NOWILD reports WILD MONS ON/OFF to
match the new state.
|
| |
|
|
|
|
|
|
| |
- New README.md showcasing the fork (fastboot, custom splash, SL0P menu,
EXPLORE camera, SAVER screensaver) with screenshots in screenshots/.
- Move upstream pret README to README.pret.md (kept for build info + credits).
- SL0P.md: update SAVER description to match current behaviour (straight until
blocked) and document the bounds clamp.
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
Crossing a map connection applies the connection's alignment offset blindly.
At an edge position the connection doesn't span, the resulting coord lands
outside the neighbour (e.g. Y = -8 = $f8), and since the bounds checks then
operate on the wrapped value the camera roams far outside the map, rendering
whatever WRAM lies past wOverworldMap as on-screen garbage. SlopClampCoords
(run in .renderView, i.e. after every entry/cross LoadMapData) clamps wYCoord
to [0,maxY] and wXCoord to [0,maxX] of the freshly-loaded map.
Verified: 120-sample saver soak across 19 maps -> 0 out-of-bounds; manual
EXPLORE crossing unaffected.
|
| |
|
|
|
|
|
|
|
|
| |
- Drop the occasional junction turn: keep the current heading until it is
actually blocked, then turn onto a random non-U-turn direction.
- Fix a freeze: a map's far edge (maxY/maxX = wCurrentMap*2 - 1) is always odd,
but scroll moves round down to even coords, so the camera stops one coord short
and 'coord != max' never flagged the edge as blocked -> the wander got stuck
clamping forever. SlopValidDirMask now treats a direction as open only if there
are >= 2 coords of room (one even step) or a connection to cross.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
New menu entry that auto-drives the EXPLORE camera across the overworld:
- persistent-direction wander (DFS-ish): keep heading, turn only when blocked
or occasionally at a junction, never an immediate U-turn. SlopSaverPickDir
synthesises a d-pad direction into the normal EXPLORE dispatch, so it inherits
smooth scrolling and smooth map-edge crossing.
- arrows hidden; player/Pikachu never drawn (clear+freeze OAM right after every
LoadMapData, before the first frame renders - also fixes a brief player flash
at crossings in manual EXPLORE).
- any button wakes it back to the menu.
State byte wSlopSaverDir reuses wUnusedCreditsByte (0=off, else current dir).
|
| |
|
|
|
|
|
|
| |
At a map boundary, smooth-scroll the remaining (even) distance up to the
edge, then either cross into the connected map (one unavoidable instant
load) or, with no connection, stop smoothly at the edge. Previously any
edge move hard-jumped a whole screen; now only crossing from exactly on a
boundary snaps.
|
| | |
|
| | |
|
| |
|
|
|
|
|
|
|
|
|
|
| |
In the paging camera, A now drops the player onto the map you're looking at. It
scans outward from the screen centre (wTileMap col 8,row 9 = the view centre) for
the nearest tile that IsTilePassable, adjusts wYCoord/wXCoord to it, sets
wDestinationWarpID=$ff so LoadMapData enters at those coords, and returns carry
set to close the menu and resume the overworld right there. Factored the view-
pointer math into SlopSetViewPtr (shared by the camera + the warp landing).
Verified: browse Pallet -> Route 1, A -> player lands on Route 1 at the centre
tile and walks around normally (sprite + Pikachu, wild data intact).
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Overlay real ▲▼◀▶ arrow sprites at the screen edges for every direction the
camera can currently page: either there's more map that way, or the map has a
connection that way. Arrows update live -- e.g. at a connectionless edge that
direction's arrow disappears.
Implementation: the font has only a down-arrow ($ee) and right-arrow ($ed), so
up/left are made with CGB OBJ Y/X-flip (the emulator supports OBJ flips). Drawn
as 4 sprites in wShadowOAM (8x8 OBJ mode, font loaded so $ed/$ee are OBJ-
reachable at 0x8ed0/0x8ee0). Set wUpdateSpritesEnabled=$ff after building them so
the vblank PrepareOAMData leaves shadow OAM alone instead of repopulating the
player sprite over the arrows.
Verified: Pallet mid-map shows all 4; Viridian shows N/S/W (no E); paging to a
connectionless edge drops that arrow and it returns on the way back.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Per feedback, EXPLORE should page whole screens on button presses (instant
redraw), not move/walk the character. Ripped out the walk-engine approach
entirely -- reverted the CollisionCheckOnLand noclip hook and the OverworldLoop
simulated-joypad paging hook, and removed both helpers.
EXPLORE is now a self-contained camera loop that renders straight from the map
block buffer:
- view pointer = wOverworldMap + (by+1)*stride + bx (LoadCurrentMapView)
- a d-pad press shifts the camera coords by ~one screen and re-renders
- at a map edge it crosses to the connected map using that connection's
alignment offset (or clamps if none), LoadMapData + re-render
- B restores the origin view + returns to the SL0P menu
No character walking, sprites hidden for a clean camera. Verified: within-map
paging steps a screen at a time, seams cross with correct offsets (Pallet ->
Route1 -> Viridian), 25-page random stress with no corruption, and normal
gameplay resumes after exit.
|
| |
|
|
|
|
|
|
|
| |
Hiding the player left the Yellow Pikachu follower visible and chasing an
invisible player -- that's the 'glitchy sprite', and with no visible player the
movement looked like it wasn't responding. Reverted the UpdatePlayerSprite hide
hook. EXPLORE is now a plain visible noclip ghost-walk: you (and Pikachu) glide
through walls and across map seams, and control is obvious. Verified tap-by-tap
movement in every direction, through Pallet's fence.
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
- UpdatePlayerSprite: when wSlopNoclip is set, jump to .disableSprite so the
player sprite is hidden -> true free-roam camera (bankable bank, no ROM0 cost).
- SlopExplore was returning carry-set into .exitProceed, which bare-returns and
assumes a warp will redraw the screen; since noclip doesn't warp, the menu
window lingered. Now it closes like the B path (SlopMenuRestoreFlags + push
bank + jp CloseTextDisplay) so the overworld is rebuilt cleanly.
- SL0P.md: document EXPLORE noclip camera + the hooks.
Verified A/B in Pallet: noclip on -> player gone, walls/seams passable; off ->
player back, collision restored, menu closes cleanly.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Ground-truth from render_overworld.py showed Kanto is ONE seamless world joined
along shared edges with per-connection offsets -- so a map-by-map browser is the
wrong model. Replaced it with noclip free-roam that leans on the engine's own
player-walk + connection-crossing machinery (which already handles seams/offsets
correctly):
- wSlopNoclip flag (reused the dead wUnusedObtainedBadges byte at D356, 0 r/w,
not unioned, in the saved region -> safe).
- CollisionCheckOnLand: 5-byte hook at the top -> when noclip is set, return
no-collision. Freed the room in ROM0 by deleting the unreferenced Func_0db5
(dead farcall LoadToggleableObjectData) in LoadMapHeader.
- EXPLORE menu entry now just toggles wSlopNoclip and closes the menu, dropping
you into the overworld to glide through walls/NPCs/ledges and walk across map
connections exactly as the world data defines them.
Verified: Pallet -> (walk north through the fences) -> seam-cross into Route 1 at
y=35 -> continue north; toggle off restores collision (player blocked).
|
| |
|
|
|
|
|
|
|
|
|
| |
Ground-truth overworld generator, no emulator. Parses map_const dimensions, the
per-map headers (tileset + connections with their alignment OFFSET), the .blk
block data, .bst blocksets (4x4 tile indices) and .2bpp tilesets, renders every
map full-size, and places them by the connection-offset math (BFS from Pallet):
north:(ax+o,ay-Bh) south:(ax+o,ay+Ah) west:(ax-Bw,ay+o) east:(ax+Aw,ay+o)
Produces a coherent 170x180-block (5440x5760px) Kanto overworld from 36 connected
maps -- confirming connections join maps along shared edges with an offset, not
as independent centered screens.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Root cause of the 'maps look wrong' bug: LoadMapData renders the view from
wCurrentTileBlockMapViewPointer, which the engine ONLY ever sets from warp /
connection / walk data (LoadDestinationWarpPosition, the connected-map handler,
advance_player_sprite) -- never from wXCoord/wYCoord. My old code set coords and
called LoadMapData, so every map was drawn from a STALE pointer left over from
the previous map: arbitrary, inconsistent windows.
Fix: after LoadMapData loads the block map into wOverworldMap, compute a centered
pointer directly --
stride = wCurMapWidth + MAP_BORDER*2
ptr = wOverworldMap + (height/2 + 1)*stride + width/2
-- clear wYBlockCoord/wXBlockCoord, and call LoadCurrentMapView to redraw. On
exit, save/restore the origin's real view pointer (+ block coords) before
reloading so the overworld comes back correctly.
Verified by DFS-traversing the whole connection graph and stitching 36 centered
maps into a coherent Kanto overworld image.
|
| |
|
|
|
|
|
| |
After rendering each map in EXPLORE, overlay N/S/E/W letters at the screen edges
for the directions that have a real connection (from wCurMapConnections), so you
can see which moves are valid before pressing. P1 done: browse the overworld
connection graph, see exits, no warping yet.
|
| |
|
|
|
|
|
|
|
| |
New EXPLORE entry in the SL0P menu renders any overworld map (LoadMapData, no
NPCs, OBJ layer disabled so even the player sprite is hidden), centered on the
map. U/D/L/R jump to the connected map in that direction when wCurMapConnections
has that flag, following the connection graph (verified Pallet<->Route 1). B
restores the origin map + coords and returns to the menu (movement intact).
Arrows/indicators next.
|
| |
|
|
|
|
|
|
| |
wc5d8 looked unused but the game writes it via computed addresses (observed it
change 56->44->35 while walking/warping), so the NOWILD flag got clobbered and
encounters still happened. wUnusedFlag is a genuine unused WRAM0 byte (verified
stable at 0 through walking + warping, not in the save block so it defaults off
each boot). NOWILD flag now persists reliably.
|
| |
|
|
|
|
|
|
|
|
| |
The SL0P menu jumped straight to CloseTextDisplay on close, but that routine
ends with 'pop af' + bankswitch expecting the caller's bank to have been pushed
(DisplayTextID does this at open, which we bypass). The unbalanced pop ate a
stack word -> wrong bank -> corrupted overworld/collision state, leaving the
player unable to move after closing the menu. Now we push hLoadedROMBank first,
and dropped the bogus LoadScreenTilesFromBuffer2 (CloseTextDisplay's
LoadCurrentMapView rebuilds wTileMap/collision itself).
|
| | |
|
| |
|
|
|
| |
SL0P MENU now 12 entries. HMs let you use field moves anywhere to complement
the warp/noclip goals.
|
| |
|
|
|
| |
Sets every party member's 4 moves to Hyper Beam / Earthquake / Ice Beam /
Thunderbolt with 31 PP each. SL0P MENU now 11 entries.
|
| |
|
|
|
|
| |
COINS sets game-corner coins to 9999. ITEMS submenu grows to 12: balls, Rare
Candy, Full Restore, Max Revive, Max Elixer, PP Up, and all five evolution
stones (Moon/Fire/Thunder/Water/Leaf). Top menu is now 10 entries.
|
| |
|
|
|
|
|
|
|
| |
NOWILD toggles wild encounters off (hooked in TryDoWildEncounter, a banked
file) with an ON indicator drawn on its menu row; the flag lives in the unused
wc5d8 WRAM0 byte (renamed wSlopNoWild, always-accessible, defaults 0). REPEL
refills repel steps to 255. (A NOCLIP toggle was prototyped but its hook lands
in the full home bank - deferred until I free ROM0 budget.) SL0P MENU now: WARP
HEAL MONEY BADGES DEX MAXTEAM ITEMS NOWILD REPEL.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
SL0P MENU grows to 7 entries:
WARP - town warp submenu
HEAL - full party HP + status
MONEY - set cash to 999999
BADGES - all 8 gym badges
DEX - mark every Pokemon owned+seen
MAXTEAM - whole party to Lv100, perfect DVs, maxed EVs, 999 stats/HP
ITEMS - submenu: give x99 of Master/Ultra Ball, Rare Candy, Full Restore,
Max Revive, Max Elixer, PP Up, Nugget (stacks via GiveItem)
All verified live: money 999999, badges FF, dex filled, party Lv100/999/FFFF DVs,
Master Ball x99 in the bag.
|
| |
|
|
|
|
|
|
|
|
|
|
| |
Refactor the flat warp menu into a table-driven top-level SL0P MENU opened by
SELECT. Each entry = a name in SlopMenuText + a routine in SlopMenuHandlers;
handlers return carry set (a warp was started, exit) or clear (back to the
menu). Ships two entries:
WARP -> WarpSubmenu (the 13-destination town list)
HEAL -> SlopHealParty (restore party HP + clear status), demoing an action
Shared open/close display handling (hide sprites, single-space flags, wTileMap
push, restore). Add an entry by appending a name+handler and bumping
SLOP_MENU_COUNT. (renamed engine/warp_menu.asm -> engine/slop_menu.asm)
|
| |
|
|
|
|
|
|
| |
Replace the plain-text splash with an actual rendered graphic: gfx/slop/intro.png
(bordered banner, big drop-shadowed SL0P logo) -> deduped tiles + tilemap via a
custom rgbgfx Makefile rule (164 tiles). SlopSplash loads it into VRAM (BG map,
0x8000 tiles), holds ~2s, fades out, and restores LCDC_DEFAULT so the overworld
BG addressing + OBJ sprites are intact. Reproducible from the PNG.
|
| |
|
|
|
|
| |
New SlopSplash (engine/slop_intro.asm) clears the screen, draws the two centered
lines, pushes to VRAM and holds ~2s, then MainMenu's autoload continues into the
game. Replaces the vanilla intro/title for the fast-boot-into-save flow.
|
| |
|
|
|
| |
Two centered title lines above a horizontally-centered box (moved to col 3,
row 2; cursor/items shifted to match). Cursor alignment verified.
|
| |
|
|
|
|
|
|
|
|
|
| |
- Hide the overworld behind the menu: wUpdateSpritesEnabled=$ff + ClearSprites
+ ClearScreen so no map tiles or NPCs bleed through.
- Single-space the list via BIT_SINGLE_SPACED_LINES + BIT_DOUBLE_SPACED_MENU
(restored on exit) so all 13 fly destinations fit: the 11 towns + Route 4 +
Route 10 (every map with FlyWarpData coords).
- No more bird: don't set BIT_USED_FLY (teleport-in instead of fly-in), and
redirect _LeaveMapAnim's .flyAnimation to the plain warp-pad fade. Verified 0
sprites active through the warp transition.
|
| |
|
|
|
|
|
|
|
|
|
| |
SELECT in the overworld now opens a drawn town list (Pallet..Indigo) with a
moving cursor; A warps to the highlighted town via the fly-warp machinery, B
cancels. WarpMenu draws its box into wTileMap then replicates the tail of
DisplayTextIDInit (CopyScreenTileBufferToVRAM + hWY=0 + LoadFontTilePatterns +
hAutoBGTransferEnabled) so the menu is actually pushed to the screen - without
it the box drew into the shadow buffer but the overworld's direct-to-VRAM
scrolled map left it invisible. HandleMenuInput drives selection; the chosen
index maps through WarpMapTable to a map id.
|
| |
|
|
|
|
|
|
|
|
|
| |
- home/overworld.asm: SELECT in the overworld farcalls WarpMenu, then restarts
the overworld loop so the fly-warp flags get processed.
- engine/warp_menu.asm (new): WarpMenu reuses the fly-warp machinery
(wDestinationMap + BIT_FLY_WARP/BIT_USED_FLY). B1 warps to Pallet
unconditionally to validate the hook; the real destination menu is next.
- Moved the fastboot intro-skip out of home/init.asm into PlayIntro (bank 10)
to reclaim ~10 bytes of home ROM0 for the overworld hook. Net boot behavior
is unchanged; new-game path still shows the intro.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
Three small hooks, all gated on CheckForPlayerNameInSRAM (carry = save present):
- home/init.asm: skip 'predef PlayIntro' when a save exists
- engine/movie/title.asm (PrepareTitleScreen): jp MainMenu, skipping the
title screen (only the boot path hits PrepareTitleScreen; return-to-title
paths jp DisplayTitleScreen directly, so they're unaffected)
- engine/menus/main_menu.asm (MainMenu): after TryLoadSaveFile, if
wSaveFileStatus==2 jp SpecialEnterMap, skipping the CONTINUE menu
Exported CheckForPlayerNameInSRAM (:: ) so home/init.asm can farcall it.
New game (no save) path is fully preserved. Ship pokeyellow.gbc only; the
_DEBUG build overflows home ROM0 by 8 bytes with the init hook.
|
| | |
|
| | |
|
| |
|
|
|
|
|
|
| |
`PIKAMOVEMENT_*` constants (#158)
- Rename `wd471` to` wPikachuSpawnStateFlags`, with `BIT_PIKACHU_SPAWN_*` bits
- Rename `wd492` to `wPikachuMapScriptFlags`, with `BIT_PIKACHU_MAP_*` bits
- Introduce `PIKAMOVEMENT_*` constants for `ApplyPikachuMovementData`
- Refactor `BillsHouse` scripts and Pikachu/Bill movement data
|
| | |
|
| | |
|
| | |
|
| |
|
| |
This variable serves as an override for Pikachu's emotion following specific events like refusing a Thunder Stone. It is automatically cleared when its mood normalizes.
|
| | |
|
| | |
|
| |\ |
|
| | | |
|
| | | |
|