09C8

From GTAMods Wiki
Jump to navigation Jump to search

San Andreas ARE_SUBTITLES_SWITCHED_ON


Description
Checks if subtitles are switched on
Syntax
09C8:   menu_subtitles_switched_on
Parameter
[none]

This conditional opcode returns true if the subtitles menu option is switched on.

For GTA III and Vice City

This opcode does not exist in GTA III and Vice City but it is possible to check if subtitles are switched on. The following example, using Sanny Builder with CLEO for GTA III and Vice City in an external script (not the main one) and tested on US v1.0, should work similarly to this opcode. Place this at the end of the file for Vice City:

:opcode_09C8
05E0: [email protected] = read_memory 0x869650 size 1 virtual_protect 0
  [email protected] == 1
05F6: ret 0

or for GTA III:

:opcode_09C8
05E0: [email protected] = read_memory 0x5F2E54 size 1 virtual_protect 0
  [email protected] == 1
05F6: ret 0

Use this line as a substitute for opcode 09C8. This can be placed anywhere within the external script as a conditional statement:

// ...
if
    05F5: call_scm_func @opcode_09C8 inputs 0
then
    // [RETURNED TRUE]
else
    // [RETURNED FALSE]
end
// ...

Keywords

check, are, menu, subtitle, subtitles, option, switch, switched, on