From db6a12682060e219782e27fead96fbe5c06b20c1 Mon Sep 17 00:00:00 2001 From: "Matthew D. Steele" Date: Sun, 20 Oct 2024 17:35:38 -0400 Subject: [PATCH] Document all actors' Param and Flags --- src/actors/acid.inc | 1 + src/actors/breakball.inc | 2 ++ src/actors/breakbomb.inc | 1 + src/actors/breakfire.inc | 1 + src/actors/bullet.inc | 2 ++ src/actors/child.inc | 1 + src/actors/crawler.inc | 13 +++++++++++++ src/actors/ember.inc | 1 + src/actors/flamestrike.inc | 1 + src/actors/grenade.inc | 2 ++ src/actors/particle.inc | 2 ++ src/actors/rhino.inc | 3 +++ src/actors/rocket.inc | 5 +++++ src/actors/rodent.inc | 12 ++++++++++++ src/actors/spine.inc | 1 + src/actors/toddler.inc | 5 +++++ src/actors/waterfall.inc | 1 - 17 files changed, 53 insertions(+), 1 deletion(-) diff --git a/src/actors/acid.inc b/src/actors/acid.inc index d0bafada..1fbbf042 100644 --- a/src/actors/acid.inc +++ b/src/actors/acid.inc @@ -25,6 +25,7 @@ ;;; is removed. ;;; * State2: Unused. ;;; * State3: Unused. +;;; * State4: Unused. ;;; The OBJ tile ID for acid projectile actors. kTileIdObjProjAcid = $80 diff --git a/src/actors/breakball.inc b/src/actors/breakball.inc index 4f997c33..1b54f7fb 100644 --- a/src/actors/breakball.inc +++ b/src/actors/breakball.inc @@ -18,9 +18,11 @@ ;;;=========================================================================;;; ;;; State bytes for breakball projectiles: +;;; * Flags: Unused. ;;; * State1: Unused. ;;; * State2: Unused. ;;; * State3: Unused. +;;; * State4: Unused. ;;; The hit radius of a breakball projectile actor, in pixels. kProjBreakballRadius = 3 diff --git a/src/actors/breakbomb.inc b/src/actors/breakbomb.inc index 7439057a..76dd3672 100644 --- a/src/actors/breakbomb.inc +++ b/src/actors/breakbomb.inc @@ -24,6 +24,7 @@ ;;; breakbomb expires. ;;; * State2: Unused. ;;; * State3: Unused. +;;; * State4: Unused. ;;; The first tile ID for drawing breakbomb projectile actors. kTileIdObjProjBreakbombFirst = $80 diff --git a/src/actors/breakfire.inc b/src/actors/breakfire.inc index 29e3addd..e8b63f1d 100644 --- a/src/actors/breakfire.inc +++ b/src/actors/breakfire.inc @@ -26,6 +26,7 @@ ;;; somehow wraps back around to zero without the breakfire bouncing, then ;;; the breakfire will expire. Resets to zero when the breakfire bounces. ;;; * State3: Unused. +;;; * State4: Unused. ;;; The first tile ID for drawing breakfire projectile actors. kTileIdObjProjBreakfireFirst = $ab diff --git a/src/actors/bullet.inc b/src/actors/bullet.inc index 557c4e72..b59e7005 100644 --- a/src/actors/bullet.inc +++ b/src/actors/bullet.inc @@ -18,11 +18,13 @@ ;;;=========================================================================;;; ;;; State bytes for bullet projectiles: +;;; * Flags: Unused. ;;; * State1: Counter that starts at zero and increments every frame; if it ;;; wraps back around to zero before the bullet hits anything, then the ;;; bullet is removed. ;;; * State2: Unused. ;;; * State3: Unused. +;;; * State4: Unused. ;;; OBJ tile IDs for bullet projectile actors: kTileIdObjProjBulletFirst = $8e diff --git a/src/actors/child.inc b/src/actors/child.inc index af4fc9cb..a75fc937 100644 --- a/src/actors/child.inc +++ b/src/actors/child.inc @@ -31,6 +31,7 @@ ;;; unchanged; if false ($00), the child is automatically drawn facing the ;;; player avatar. ;;; * State3: Unused. +;;; * State4: Unused. ;;;=========================================================================;;; diff --git a/src/actors/crawler.inc b/src/actors/crawler.inc index a5ba634e..b1c671c6 100644 --- a/src/actors/crawler.inc +++ b/src/actors/crawler.inc @@ -18,6 +18,19 @@ ;;;=========================================================================;;; ;;; State bytes for beetle and hothead baddies: +;;; * Param: The initial flags to set (0 or bObj::FlipH and/or bObj::FlipV). +;;; * Flags: The meaning of these depends on if the baddie is crawling +;;; horizontally (on a floor or ceiling) or vertically (on a wall): +;;; * If the baddie is crawling horizontally, then the bObj::FlipH bit is +;;; set if the baddie is facing left, or cleared if it is facing right; +;;; and the bObj::FlipV bit is set if the baddie is crawling +;;; upside-down on the ceiling, or cleared if it is crawling +;;; right-side-up on the floor. +;;; * If the baddie is crawling vertically, then the bObj::FlipH bit is +;;; set if the baddie is just to the left of the wall, or cleared if it +;;; is just to the right of the wall; and the bObj::FlipV bit is set if +;;; the baddie is crawling downwards, or cleared if it is crawling +;;; upwards. ;;; * State1: Toggles between 1 and 0 each frame; used to make baddie move ;;; by one pixel every other frame. ;;; * State2: Unused for beetles; for hotheads, this is the number of diff --git a/src/actors/ember.inc b/src/actors/ember.inc index bf57f83f..bfad0b30 100644 --- a/src/actors/ember.inc +++ b/src/actors/ember.inc @@ -25,6 +25,7 @@ ;;; ember is removed. ;;; * State2: Unused. ;;; * State3: Unused. +;;; * State4: Unused. ;;; The OBJ tile ID for ember projectile actors. kTileIdObjProjEmber = $86 diff --git a/src/actors/flamestrike.inc b/src/actors/flamestrike.inc index b9e284aa..6f79fc70 100644 --- a/src/actors/flamestrike.inc +++ b/src/actors/flamestrike.inc @@ -25,6 +25,7 @@ ;;; * State2: The current visual height of the flamestrike, in tiles. ;;; * State3: A timer that counts up or down each frame, depending on the ;;; current mode. +;;; * State4: Unused. ;;; Possible values for a flamestrike projectile actor's State1 byte. .ENUM eProjFlamestrike diff --git a/src/actors/grenade.inc b/src/actors/grenade.inc index 54507d7b..507748cc 100644 --- a/src/actors/grenade.inc +++ b/src/actors/grenade.inc @@ -18,11 +18,13 @@ ;;;=========================================================================;;; ;;; State bytes for grenade projectiles: +;;; * Flags: Unused. ;;; * State1: Counter that starts at zero and increments every frame; if it ;;; wraps back around to zero before the grenade hits anything, then the ;;; grenade explodes. ;;; * State2: Unused. ;;; * State3: Unused. +;;; * State4: Unused. ;;; How many frames the room shakes for when a grenade hits the ground. kGrenadeShakeFrames = 4 diff --git a/src/actors/particle.inc b/src/actors/particle.inc index 05f0cd5a..abbed235 100644 --- a/src/actors/particle.inc +++ b/src/actors/particle.inc @@ -18,10 +18,12 @@ ;;;=========================================================================;;; ;;; State bytes for smoke particles: +;;; * Flags: Unused. ;;; * State1: Counter that starts at zero and increments every frame; once it ;;; reaches kParticleNumFrames, the particle expires. ;;; * State2: Unused. ;;; * State3: Unused. +;;; * State4: Unused. ;;; How long a smoke particle actor animates before disappearing, in frames. kSmokeParticleNumFrames = 12 diff --git a/src/actors/rhino.inc b/src/actors/rhino.inc index 76b286fe..01412f6a 100644 --- a/src/actors/rhino.inc +++ b/src/actors/rhino.inc @@ -18,6 +18,9 @@ ;;;=========================================================================;;; ;;; State bytes for rhino baddies: +;;; * Param: The initial flags to set (0 or bObj::FlipH). +;;; * Flags: The bObj::FlipH bit is set if the rhino is facing left, or +;;; cleared if it is facing right. ;;; * State1: The current eBadRhino state value. ;;; * State2: A timer that counts up/down each frame, depending on the ;;; current eBadRhino value. diff --git a/src/actors/rocket.inc b/src/actors/rocket.inc index dfd1f13e..d4b32898 100644 --- a/src/actors/rocket.inc +++ b/src/actors/rocket.inc @@ -18,11 +18,16 @@ ;;;=========================================================================;;; ;;; State bytes for rocket projectiles: +;;; * Flags: For a horizontally-moving rocket, the bObj::FlipH bit will be +;;; set if the rocket is moving left, or cleared if it is moving right. +;;; For a vertically-moving rocket, the bObj::FlipV bit will be set if the +;;; rocket is moving up, or cleared if it is moving down. ;;; * State1: Counter that starts at zero and increments every frame; if it ;;; wraps back around to zero before the rocket hits anything, then the ;;; rocket is removed. ;;; * State2: Unused. ;;; * State3: Unused. +;;; * State4: Unused. ;;; How many frames the room shakes for when a rocket hits the ground. kRocketShakeFrames = 30 diff --git a/src/actors/rodent.inc b/src/actors/rodent.inc index a696cec5..96a3a869 100644 --- a/src/actors/rodent.inc +++ b/src/actors/rodent.inc @@ -19,6 +19,18 @@ ;;; State bytes for rodent baddies: ;;; * Param: Unused. +;;; * Flags: The meaning of these depends on if the rodent is running +;;; horizontally (on a floor or ceiling) or vertically (on a wall): +;;; * If the rodent is running horizontally, then the bObj::FlipH bit is +;;; set if the rodent is facing left, or cleared if it is facing right; +;;; and the bObj::FlipV bit is set if the rodent is running +;;; upside-down on the ceiling, or cleared if it is running +;;; right-side-up on the floor. +;;; * If the rodent is running vertically, then the bObj::FlipH bit is +;;; set if the rodent is just to the left of the wall, or cleared if it +;;; is just to the right of the wall; and the bObj::FlipV bit is set if +;;; the rodent is running downwards, or cleared if it is running +;;; upwards. ;;; * State1: The current eBadRodent state value. ;;; * State2: A timer that counts up/down each frame, depending on the ;;; current eBadRodent value. diff --git a/src/actors/spine.inc b/src/actors/spine.inc index 3c2d997a..9f0f5f9f 100644 --- a/src/actors/spine.inc +++ b/src/actors/spine.inc @@ -26,6 +26,7 @@ ;;; wraps back around to zero before the spine hits anything, then the ;;; spine is removed. ;;; * State3: Unused. +;;; * State4: Unused. ;;; Tile IDs for drawing spine projectile actors. kTileIdObjProjSpineFirst = $b8 diff --git a/src/actors/toddler.inc b/src/actors/toddler.inc index 22f0877b..deda06af 100644 --- a/src/actors/toddler.inc +++ b/src/actors/toddler.inc @@ -18,9 +18,14 @@ ;;;=========================================================================;;; ;;; State bytes for toddler NPCs: +;;; * Param: The bNpcToddler parameter. +;;; * Flags: The bObj::FlipH bit is set if the toddler is facing left, or +;;; cleared if they are facing right. The Pri bit is set if the toddler +;;; should appear behind the background. ;;; * State1: How many more frames until the toddler turns around. ;;; * State2: Unused. ;;; * State3: Unused. +;;; * State4: Unused. ;;; The first tile ID for toddler NPC actors. kTileIdObjToddlerFirst = $80 diff --git a/src/actors/waterfall.inc b/src/actors/waterfall.inc index 5684744e..3470c9ba 100644 --- a/src/actors/waterfall.inc +++ b/src/actors/waterfall.inc @@ -19,7 +19,6 @@ ;;; State bytes for waterfall smoke: ;;; * Flags: Unused. -;;; * Param: The platform index for the water below. ;;; * State1: The platform index for the water below. ;;; * State2: The current height of the waterfall, in pixels. ;;; * State3: Boolean; true ($ff) if this waterfall has been shut off and the