feat(sasch40): overhaul Act III tavern schankraum and canonical papa markus scene
- Generate and integrate authentic 16-bit LucasArts taproom scene with Theke, brass taps, bartender, drinking patrons, and bunker trapdoor - Realign Schankraum hotspots for Verena, Lutz in hot tub, Armend at forge, room transitions, and centered bunker trapdoor - Update Papa Markus canonical portrait and Taiwan street dining scene to be bald and clean-shaven with glasses and modern attire - Enforce hotspot zero-occlusion rules for signposts, characters, and mobile room navigation bars - Document Papa Markus specifications, tavern invariants, and layout guidelines in AGENTS.md - Add automated sister capture and playthrough recording scripts
This commit is contained in:
@@ -166,7 +166,8 @@ function onRight(pressed: boolean) {
|
||||
defineExpose({
|
||||
onJump,
|
||||
onLeft,
|
||||
onRight
|
||||
onRight,
|
||||
triggerSisterRescue
|
||||
})
|
||||
|
||||
// Touch controls on screen halves
|
||||
@@ -357,9 +358,11 @@ function drawGame(ctx: CanvasRenderingContext2D) {
|
||||
|
||||
// 1. Background sky parallax
|
||||
if (bgImg && bgImg.complete && bgImg.naturalWidth > 0) {
|
||||
const scrollFactor = (cameraY / (levelHeight - H))
|
||||
const bgY = -scrollFactor * (bgImg.naturalHeight - H)
|
||||
ctx.drawImage(bgImg, 0, bgY, W, bgImg.naturalHeight * (W / bgImg.naturalWidth))
|
||||
const drawnH = bgImg.naturalHeight * (W / bgImg.naturalWidth)
|
||||
const maxScroll = Math.max(0, drawnH - H)
|
||||
const scrollFactor = Math.max(0, Math.min(1, cameraY / (levelHeight - H)))
|
||||
const bgY = -scrollFactor * maxScroll
|
||||
ctx.drawImage(bgImg, 0, bgY, W, drawnH)
|
||||
} else {
|
||||
// Fallback sky gradient
|
||||
const skyGrad = ctx.createLinearGradient(0, 0, 0, H)
|
||||
@@ -603,6 +606,11 @@ function gameLoop() {
|
||||
onMounted(() => {
|
||||
window.addEventListener('keydown', handleKeyDown)
|
||||
window.addEventListener('keyup', handleKeyUp)
|
||||
;(window as any).__platformer = {
|
||||
triggerSisterRescue,
|
||||
setRescuedSister: (s: any) => { rescuedSister.value = s },
|
||||
startLevel
|
||||
}
|
||||
initCurrentLevel()
|
||||
animationFrameId = requestAnimationFrame(gameLoop)
|
||||
})
|
||||
@@ -610,6 +618,7 @@ onMounted(() => {
|
||||
onUnmounted(() => {
|
||||
window.removeEventListener('keydown', handleKeyDown)
|
||||
window.removeEventListener('keyup', handleKeyUp)
|
||||
delete (window as any).__platformer
|
||||
if (animationFrameId) cancelAnimationFrame(animationFrameId)
|
||||
})
|
||||
</script>
|
||||
|
||||
Reference in New Issue
Block a user