In the US 1.1 version of Star Fox 64, the Arwing rolls when Z or R is pressed twice. The first press sets that button's counter to 10, which Player_UpdateArwingRoll counts down once per player update, and a second press while it is above 0 starts the roll, turning the ship 30 degrees an update for 10 updates and then slowing by 5 degrees an update until it stops. barrelRollAlpha falls by 30 every update while it is above 0, and in each update the roll's count is still above 0 after counting down (9 of its 10) it then gains 100, capped at 180, a net rise of 70 an update. While that value is above 0, the enemy-shot update (Effect_EnemyShot_Update) widens the shot's box around the player by 100 units on each axis, sends a shot inside it off in a new direction, and applies no damage. | src/engine/fox_play.c L3397–3419src/engine/fox_play.c L4823–4839src/engine/fox_play.c L4846–4870src/engine/fox_play.c L5534–5549src/engine/fox_effect.c L2902–2926 | Code |
In the US 1.1 version of Star Fox 64, the Arwing's boost and brake share one meter, boostMeter, which counts up from 0 as it is used and stops at 90. Holding the boost button adds 3 a player update on rails and 1.5 in all-range mode (Player_ArwingBoost), and holding brake adds the same amounts (Player_ArwingBrake). Each of the two functions takes back 0.5 a update on rails (0.35 in all-range mode) whenever its own action isn't running, so the meter falls by 1 an update on rails when neither button is held. Reaching 90, holding both buttons with the meter above 0, or letting go of both with the meter above 0 sets boostCooldown, which blocks both actions until the meter is back to 0. | src/engine/fox_play.c L4951–4968src/engine/fox_play.c L5024–5031src/engine/fox_play.c L5047–5051src/engine/fox_play.c L5064–5069src/engine/fox_play.c L5092–5098src/engine/fox_play.c L5130–5165src/engine/fox_play.c L5601–5606 | Code |
In the US 1.1 version of Star Fox 64, holding A counts a charge counter up by 1 a player update to a cap of 21, and an update without A held counts it down by 1 (Player_UpdateLockOn). A fresh press of A, whose own update first adds 1 to the counter, fires the charged shot (PLAYERSHOT_LOCK_ON) if an enemy is locked on or the counter is then above 10 (so 10 or more before the press). Either path fires only if the player's charged-shot slot (gPlayerShots[14 - player->num]) is free, holds a shot of another type, or holds a charged shot that has lost its target (the locked path) or grown past scale 1 (the counter path); a press that fires nothing sets the counter to 0. Once the counter is above 20, while A is held, nothing is locked, and Z and R aren't both held, it launches a search shot every fourth game frame, and the first targetable enemy within 300 units of that shot on each axis (200 in all-range mode) is locked on for a count of 20, which counts down only while A is up. Each update while its target stays locked, the charged shot turns toward it (PlayerShot_UpdateLockOnShot). | src/engine/fox_play.c L3186–3220src/engine/fox_play.c L3164–3172src/engine/fox_play.c L3222–3260src/sys/sys_joybus.c L69–70src/engine/fox_beam.c L1758–1769src/engine/fox_enmy.c L2848–2852src/engine/fox_beam.c L2174–2222 | Code |
In the US 1.1 version of Star Fox 64, Player_Setup gives the player 255 shield units (less with a Versus handicap), and healing stops at Play_GetMaxShields: 383 with three or more gold rings, otherwise 255. A hit's damage, doubled in Expert mode, drains from the shield at 2 units an update (Player_UpdateShields), and an enemy laser's damage is 20; a hit while gHasShield is set does none. Each Arwing wing starts at 60 health (10 in Expert mode). A hit the code gives direction 1 or 2 takes 20 from the right or left wing, directions 3 and 4 take 15 from one wing at random, and direction 0, which enemy shots pass, takes none; a wing at 0 breaks. While either wing is broken or absent (WINGSTATE_NONE; the test is <= WINGSTATE_BROKEN), Player_Shoot sets the lasers back to single every update. | src/engine/fox_play.c L4405–4436src/engine/fox_play.c L64–69src/engine/fox_play.c L5463–5484src/engine/fox_play.c L867–895src/engine/fox_play.c L916–978src/engine/fox_play.c L819–827src/engine/fox_play.c L3299–3305include/sf64player.h L27–29src/engine/fox_effect.c L2925–2926src/engine/fox_edata_info.c L472include/sf64object.h L153–168 | Code |