FF7/Field/Script/Opcodes/61 SCRLO

From Final Fantasy Inside
< FF7‎ | Field‎ | Script‎ | Opcodes
Revision as of 17:47, 31 October 2020 by Dangarfield (talk | contribs) (Created page with "* Opcode: '''0x61''' * Short name: '''SCRL0''' * Long name: Scroll To Playable Character ==== Memory layout ==== {| border="1" cellspacing="1" cellpadding="3" style="border:...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search
  • Opcode: 0x61
  • Short name: SCRL0
  • Long name: Scroll To Playable Character

Memory layout

0x63 B S U T

Arguments

  • const UByte B: PRESUME -> Bank for the scroll speed, or zero if it is specified as a literal value. Always zero in game data
  • const UShort S: Speed of the scroll, in frames, or the address to find the speed if B is non-zero.
  • const UByte U: Unknown -> Always zero in game data. Seems to affect the speed above.
  • const UByte T: Type of scroll.

Description

Scrolls the current view so that the main playable character is in the center of the view. The script executes asynchronously and does not block whilst the camera movement is active but returns control to the next script operation. This is tweened over a period of S frames. If the main playable character also moves during this time period, the tween position is also updated to match the new playable character location. Once the camera has completed its movement, the camera NO LONGER follows the main playable character's movement. It stays in place.

Scroll Types

ID Scroll Type
0 No effect - Camera does not move, returns script, camera still follows the playable character is it did before
1 No effect - Camera does not move, returns script, camera still follows the playable character is it did before
2 Linear
3 Smooth (QuadraticInAndOut)