GameMaker:Built-in Variables

From GMG Manual

Jump to: navigation, search
  • counter

Stores the variable that displays as an automatically updating counter in the bottom right of the game window.

  • CurrentCard

Stores the number of the card the player is currently on.

  • Barvalue

Stores the value of the Status Bar.

  • Date$

Stores the current date as reported by the system in mm/dd/yy format.

  • Inventory$

Stores the currently seleted inventory item.

  • IsMoviePlaying

Stores 1 if a Quicktime movie (.mov) is playing, -1 if a sound format (midi, wav) is playing, or 0 if nothing is playing.

  • IsSoundPlaying

Stores -1 if a sound resource is playing or 0 if no sound is playing.

  • KeyDown$

Stores the string value of a key being pressed. Arrow keys return UPARROW, DOWNARROW, LEFTARROW, or RIGHTARROW, and the delete key returns DELETE.

  • LoopScript

Increases by 1 every time a script loops.

  • MouseHorz

Stores the horizontal position of the mouse.

  • MouseDown

Stores 1 if the mouse button is down, or 0 if the mouse button is up.

  • MouseVert

Stores the vertical position of the mouse

  • RecentCard

Stores the number of the card previously accessed by the player.

  • SpriteClicked

Stores the number of the sprite that was last clicked or 0 if no sprite has been clicked yet. Updates whenever the mouse is clicked.

  • Time$

Stores the current time as reported by the system in hh:mm:ss format.

  • TotalCards

Stores the total number of cards accessed by the player, including multiple accesses to the same card.

  • Userask$

Stores the most recent contents of a USERASK dialog.

Personal tools