Difference between revisions of "FF7/Field/Script/Opcodes/49 MENU"

From Final Fantasy Inside
< FF7‎ | Field‎ | Script‎ | Opcodes
Jump to navigation Jump to search
my_wiki>Synergy Blades
m
my_wiki>BukTop
(Created page with "* Opcode: '''0x49''' * Short name: '''MENU''' * Long name: Menu ==== Memory layout ==== {| style="border: 1px solid black; border-collapse: collapse" border="1" cellspacin...")
Line 3: Line 3:
 
* Long name: Menu
 
* Long name: Menu
  
==== Memory layout ====
+
==== Memory layout ====
{| border="1" cellspacing="1" cellpadding="3" style="border: 1px solid black; border-collapse: collapse;"
+
 
 +
{| style="border: 1px solid black; border-collapse: collapse" border="1" cellspacing="1" cellpadding="3"
 
! width="40" | 0x49
 
! width="40" | 0x49
 
! width="40" | ''B''
 
! width="40" | ''B''
Line 11: Line 12:
 
|}
 
|}
  
==== Arguments ====
+
==== Arguments ====
* '''const UByte''' ''B'': Bank for parameter, or zero if ''P'' is specified as a literal value.
+
 
* '''const UByte''' ''T'': Type of menu, or special event.
+
* '''const UByte''' ''B''<nowiki>: Bank for parameter, or zero if </nowiki>''P'' is specified as a literal value.
* '''const UByte''' ''P'': Parameter to the menu, or address of parameter value, if ''B'' is non-zero.
+
* '''const UByte''' ''T''<nowiki>: Type of menu, or special event. </nowiki>
 +
* '''const UByte''' ''P''<nowiki>: Parameter to the menu, or address of parameter value, if </nowiki>''B'' is non-zero.
  
==== Description ====
+
==== Description ====
  
 
MENU has two uses. Its primary function is to display a menu or other special screen; these menus range from the character name entry screen, to a shop, and even the staff credit display. The type of display can be found in the first table below.
 
MENU has two uses. Its primary function is to display a menu or other special screen; these menus range from the character name entry screen, to a shop, and even the staff credit display. The type of display can be found in the first table below.
Line 24: Line 26:
 
Some types of menu are erroneous or produce erratic behaviour, and were most likely used for testing. As such, they are not listed here.
 
Some types of menu are erroneous or produce erratic behaviour, and were most likely used for testing. As such, they are not listed here.
  
==== Standard Menu Types ====
+
==== Standard Menu Types ====
  
{| border="1" cellspacing="1" cellpadding="3" style="border: 1px solid black; border-collapse: collapse;"
+
{| style="border: 1px solid black; border-collapse: collapse" border="1" cellspacing="1" cellpadding="3"
! style="background:rgb(204,204,204)" width="40" | ID
+
! style="background: rgb(204,204,204)" width="40" | ID
! style="background:rgb(204,204,204)" width="200" | Menu Type
+
! style="background: rgb(204,204,204)" width="200" | Menu Type
 
|-
 
|-
 
| align="center" | 5
 
| align="center" | 5
Line 47: Line 49:
 
| align="center" | E
 
| align="center" | E
 
| Save Screen
 
| Save Screen
|-
 
 
|}
 
|}
  
==== Special Event Types ====
+
==== Special Event Types ====
  
{| border="1" cellspacing="1" cellpadding="3" style="border: 1px solid black; border-collapse: collapse;"
+
{| style="border: 1px solid black; border-collapse: collapse" border="1" cellspacing="1" cellpadding="3"
! style="background:rgb(204,204,204)" width="40" | ID
+
! style="background: rgb(204,204,204)" width="40" | ID
! style="background:rgb(204,204,204)" width="350" | Event Type
+
! style="background: rgb(204,204,204)" width="350" | Event Type
 
|-
 
|-
 
| align="center" | F
 
| align="center" | F
Line 64: Line 65:
 
| align="center" | 13
 
| align="center" | 13
 
| Restore Cloud's Materia
 
| Restore Cloud's Materia
|-
 
 
|}
 
|}
  
==== Parameters ====
+
==== Parameters ====
  
 
* Character Name Entry: Parameter indicates the name of the character to edit, and follows the standard Character IDs, as well as 0x64 to indicate the Chocobo naming screen.
 
* Character Name Entry: Parameter indicates the name of the character to edit, and follows the standard Character IDs, as well as 0x64 to indicate the Chocobo naming screen.

Revision as of 17:59, 24 March 2018

  • Opcode: 0x49
  • Short name: MENU
  • Long name: Menu

Memory layout

0x49 B T E

Arguments

  • const UByte B: Bank for parameter, or zero if P is specified as a literal value.
  • const UByte T: Type of menu, or special event.
  • const UByte P: Parameter to the menu, or address of parameter value, if B is non-zero.

Description

MENU has two uses. Its primary function is to display a menu or other special screen; these menus range from the character name entry screen, to a shop, and even the staff credit display. The type of display can be found in the first table below.

The other function is to provide a set of special events that would normally be accomplished through a set of opcodes, but are instead coded directly into a MENU call. These events are provided in the second table.

Some types of menu are erroneous or produce erratic behaviour, and were most likely used for testing. As such, they are not listed here.

Standard Menu Types

ID Menu Type
5 FF7 Credits
6 Character Name Entry
7 Party Select
8 Shop
9 Main Menu
E Save Screen

Special Event Types

ID Event Type
F Yuffie's Materia Steal (Remove All Materia)
12 Remove Cloud's Materia
13 Restore Cloud's Materia

Parameters

  • Character Name Entry: Parameter indicates the name of the character to edit, and follows the standard Character IDs, as well as 0x64 to indicate the Chocobo naming screen.