Skip to content

Builtin Macros

Nenkai edited this page Jul 15, 2024 · 7 revisions

Special Compiler Macros

  • ROOT - Root Name (for project compilation)
  • PROJECT - Project Name (for project compilation)
  • IMPL - Get root impl (for project compilation, used in GT Sport) - expands to ROOT.getImpl()
  • __LINE__ - Current Line Number
  • __FILE__ - Current Source File
  • __DATE__ - Compile Date
  • __TIME__ - Compile Time
  • __TIMESTAMP__ - File Timestamp
  • __COUNTER__ - Counter, incremented by 1 on every use

Constants/Other

Tip

All macros are defined here.

UI

Widget Event Result

This is crucial and used for UI operations/events (onKeyPress, onInitialize, etc).

  • EVENTRESULT_CONTINUE
  • EVENTRESULT_STOP
  • EVENTRESULT_FILTER

TextFace Colors (used in GT6)

  • COLOR_DEFAULT (0x10)
  • COLOR_WHITE (0x11)
  • COLOR_RED (0x12)
  • COLOR_GREEN (0x13)
  • COLOR_BLUE (0x14)
  • COLOR_YELLOW (0x15)
  • COLOR_CYAN (0x16)
  • COLOR_BLACK (0x17)

Scroll Mode

Used for mScrollClip.scroll_mode.

  • SCROLL_MODE_FOLLOW_FOCUS (0) - follow_focus
  • SCROLL_MODE_FLOATING (1) - floating
  • SCROLL_MODE_MANUAL (2) - manual
  • SCROLL_MODE_FOLLOW_MODE (3) - follow_mode

Numerics

  • INT_MIN/INT_MAX
  • UINT_MIN/UINT_MAX
  • LONG_MIN/LONG_MAX
  • ULONG_MIN/ULONG_MAX

Controls

PS3 Pad Controls

  • CELL_PAD_CTRL_L3_LEFT (0xFF51)
  • CELL_PAD_CTRL_L3_UP (0xFF52)
  • CELL_PAD_CTRL_L3_RIGHT (0xFF53)
  • CELL_PAD_CTRL_L3_DOWN (0xFF54)
  • CELL_PAD_CTRL_R3_LEFT (0xFFB4)
  • CELL_PAD_CTRL_R3_UP (0xFFB8)
  • CELL_PAD_CTRL_R3_RIGHT (0xFFB6)
  • CELL_PAD_CTRL_R3_DOWN (0xFFB2)
  • CELL_PAD_CTRL_CROSS (0xFF0D)
  • CELL_PAD_CTRL_SQUARE (0xFFBF)
  • CELL_PAD_CTRL_TRIANGLE (0xFFBE)
  • CELL_PAD_CTRL_CIRCLE (0xFF1B)
  • CELL_PAD_CTRL_SELECT (0xFF63)
  • CELL_PAD_CTRL_START (0xFF8D)
  • CELL_PAD_CTRL_L1 (0xFFD7)
  • CELL_PAD_CTRL_L2 (0xFFD8)
  • CELL_PAD_CTRL_L3 (0xFFD9)
  • CELL_PAD_CTRL_R1 (0xFFDC)
  • CELL_PAD_CTRL_R2 (0xFFDD)
  • CELL_PAD_CTRL_R3 (0xFFDE)

PS2 Pad Controls

  • PS2_PAD_CTRL_L3_LEFT (0xFF51)
  • PS2_PAD_CTRL_L3_UP (0xFF52)
  • PS2_PAD_CTRL_L3_RIGHT (0xFF53)
  • PS2_PAD_CTRL_L3_DOWN (0xFF54)
  • PS2_PAD_CTRL_R3_LEFT (0xFFB4)
  • PS2_PAD_CTRL_R3_UP (0xFFB8)
  • PS2_PAD_CTRL_R3_RIGHT (0xFFB6)
  • PS2_PAD_CTRL_R3_DOWN (0xFFB2)
  • PS2_PAD_CTRL_CROSS (0xFF0D)
  • PS2_PAD_CTRL_SQUARE (0xFFBF)
  • PS2_PAD_CTRL_TRIANGLE (0xFFBE)
  • PS2_PAD_CTRL_CIRCLE (0xFF1B)
  • PS2_PAD_CTRL_SELECT", (0xFF63)
  • PS2_PAD_CTRL_START", (0xFF8D)
  • PS2_PAD_CTRL_L1 (0xFFC8)
  • PS2_PAD_CTRL_L2 (0xFFC9)
  • PS2_PAD_CTRL_R1 (0xFFD2)
  • PS2_PAD_CTRL_R2 (0xFFD3)

Sqlite

All error codes here