DisableAllControlsThisFrame

From GT-MP
Jump to: navigation, search
DisableAllControlsThisFrame
Client-Side Function
System-users.png Client-Side Javascript.png JavaScript

This function will disable all the game controls for instance "TAB" displaying weapon inventory. It only disables them for one frame so use this on OnUpdate. For more game controls, visit this Game Controls.

Dialog-warning.png API.disableAllControlsThisFrame() will be removed in version 0.1.7, see Deprecated.

Syntax

API.disableAllControlsThisFrame();

Usage example(s)

This will disable all controls forever until somehow stopped.

var debugging = true;

API.onUpdate.connect(function () {
   if (debugging) {
      API.disableAllControlsThisFrame();
   }
});

References