MiscClient

hasCheatWithHashBeenActivated

HAS_CHEAT_WITH_HASH_BEEN_ACTIVATED0x071E2A839DE82D90

The GTA V native HAS_CHEAT_WITH_HASH_BEEN_ACTIVATED of the MISC namespace, as LS:MP client scripts call it: the global function hasCheatWithHashBeenActivated, in JavaScript and in Lua.

SignatureJavaScript
hasCheatWithHashBeenActivated(hash: Hash, amount: number): boolean
SignatureLua
hasCheatWithHashBeenActivated(hash: Hash, amount: integer): boolean

Usage

JavaScript
const result = hasCheatWithHashBeenActivated(hash, amount);
Lua
local result = hasCheatWithHashBeenActivated(hash, amount)

Parameters

ParameterTypeJavaScriptLua
hashHashnumberinteger
amountintnumberinteger

Returns

BOOL JavaScript boolean, Lua boolean

Notes

From the community native database. Names are LS:MP’s; samples may be written for C++ or another framework.

This native appears on the cheat_controller script and tracks a combination of buttons, which may be used to toggle cheats in-game. Credits to ThreeSocks for the info. The hash contains the combination, while the "amount" represents the amount of buttons used in a combination. The following page can be used to make a button combination: gta5offset.com/ts/hash/

INT_SCORES_SCORTED was a hash collision

Reference

Namespace
Misc MISC
In the game
BOOL HAS_CHEAT_WITH_HASH_BEEN_ACTIVATED(Hash hash, int amount)
Hash
0x071E2A839DE82D90
Formerly
_HAS_BUTTON_COMBINATION_JUST_BEEN_ENTERED

Open in the interactive natives reference