Difference between revisions of "CallFunction"

From Final Fantasy Hacktics Wiki
Jump to navigation Jump to search
 
Line 6: Line 6:
  
 
== Function : Byte (hex) ==
 
== Function : Byte (hex) ==
*x01: Inventory is reset (New Game inventory). Units join silently (Join After Event + Save Formation = Join as Guest / Join After Event = Join silently as a playable character) without the need of [[Event_Instruction_76|{76} {{IE_76}}]].
+
*x01: Inventory is reset (New Game inventory) unless Var 0x27 (Current Event) has an ID of 0x4E or above. Units join silently (Join After Event + Save Formation = Join as Guest / Join After Event = Join silently as a playable character) without the need of [[Event_Instruction_76|{76} {{IE_76}}]]. NOTE: Skipped if Var 0x1FC (Brave Story Event?) is flagged.
 
*x02: A year passes
 
*x02: A year passes
 
*x03: Increases Blue team units' Brave by +10 (used in Mandalia Destroy corps event)
 
*x03: Increases Blue team units' Brave by +10 (used in Mandalia Destroy corps event)
 
*x04: BlueRemoveUnit all enemy units
 
*x04: BlueRemoveUnit all enemy units
*x05: Used once during a lightning strike. Use unknown.
+
*x05: Used once during a lightning strike. Saves 0x00000001 to 0x801696F8. Use unknown.
*x06: Displays a save screen (https://ffhacktics.com/smf/index.php?topic=10124.msg193711#msg193711)
+
*x06: Displays a save screen (https://ffhacktics.com/smf/index.php?topic=10124.msg193711#msg193711)  NOTE: Skipped if Var 0x1FC (Brave Story Event?) is flagged. NOTE 2: Behaves differently if this is Event ID 0x12C (vanilla's final event)
*x08: Has some code among that of other CallFunctions at [[00143bd0 - 00145f74]], but purpose unknown.
+
*x07: A year passes. Again.
 +
*x08: Zeroes out 0x800459CC and 0x800459D8. Purpose unknown.
 
*x09: Sets Var x53 to a value of 0x01, which mutes the text audio cue.
 
*x09: Sets Var x53 to a value of 0x01, which mutes the text audio cue.
 
*x0A: Sets Var x53 to a value of 0x00, which restores the text audio cue.
 
*x0A: Sets Var x53 to a value of 0x00, which restores the text audio cue.
Line 18: Line 19:
 
*x0C: Changes the currently playing song to song 13 Ultema, the Perfect Body
 
*x0C: Changes the currently playing song to song 13 Ultema, the Perfect Body
 
*x0D: Used in Altima -> Altima 2 transformation event: Move ENTD Unit 9 to the coordinates of ENTD Unit 8
 
*x0D: Used in Altima -> Altima 2 transformation event: Move ENTD Unit 9 to the coordinates of ENTD Unit 8
*x0E: Used when the Bethla Sluice is opened up. (Possible unit remover?)
+
*x0E: Used when the Bethla Sluice is opened up to remove units that were washed away.
 
*x0F: Moves ENTD Unit 4 to the coordinates of ENTD Unit 2*
 
*x0F: Moves ENTD Unit 4 to the coordinates of ENTD Unit 2*
 
*x10: Moves ENTD Unit 5 to the coordinates of ENTD Unit 3*
 
*x10: Moves ENTD Unit 5 to the coordinates of ENTD Unit 3*
 
*x11: Used in Dycedarg -> Adramelk transformation event
 
*x11: Used in Dycedarg -> Adramelk transformation event
*x12: Used in Zalera Death event
+
*x12: Used in Zalera Death event to prevent the Stone from keeping the Float animation
  
 
<nowiki>*</nowiki> Edit at 0x801342E4
 
<nowiki>*</nowiki> Edit at 0x801342E4

Latest revision as of 16:49, 10 May 2025

{43} CallFunction

CallFunction(xFC)

Can call various different functions to alter many different things in the game.


Function : Byte (hex)

  • x01: Inventory is reset (New Game inventory) unless Var 0x27 (Current Event) has an ID of 0x4E or above. Units join silently (Join After Event + Save Formation = Join as Guest / Join After Event = Join silently as a playable character) without the need of {76} DarkScreen. NOTE: Skipped if Var 0x1FC (Brave Story Event?) is flagged.
  • x02: A year passes
  • x03: Increases Blue team units' Brave by +10 (used in Mandalia Destroy corps event)
  • x04: BlueRemoveUnit all enemy units
  • x05: Used once during a lightning strike. Saves 0x00000001 to 0x801696F8. Use unknown.
  • x06: Displays a save screen (https://ffhacktics.com/smf/index.php?topic=10124.msg193711#msg193711) NOTE: Skipped if Var 0x1FC (Brave Story Event?) is flagged. NOTE 2: Behaves differently if this is Event ID 0x12C (vanilla's final event)
  • x07: A year passes. Again.
  • x08: Zeroes out 0x800459CC and 0x800459D8. Purpose unknown.
  • x09: Sets Var x53 to a value of 0x01, which mutes the text audio cue.
  • x0A: Sets Var x53 to a value of 0x00, which restores the text audio cue.
  • x0B: Destroys Murond Death City's entrance (requires Arrangement 0x0001 and using a map destructive effect)
  • x0C: Changes the currently playing song to song 13 Ultema, the Perfect Body
  • x0D: Used in Altima -> Altima 2 transformation event: Move ENTD Unit 9 to the coordinates of ENTD Unit 8
  • x0E: Used when the Bethla Sluice is opened up to remove units that were washed away.
  • x0F: Moves ENTD Unit 4 to the coordinates of ENTD Unit 2*
  • x10: Moves ENTD Unit 5 to the coordinates of ENTD Unit 3*
  • x11: Used in Dycedarg -> Adramelk transformation event
  • x12: Used in Zalera Death event to prevent the Stone from keeping the Float animation

* Edit at 0x801342E4