isScenarioTypeEnabled
IS_SCENARIO_TYPE_ENABLED0x3A815DB3EA088722The GTA V native IS_SCENARIO_TYPE_ENABLED of the TASK namespace, as LS:MP client scripts call it: the global function isScenarioTypeEnabled, in JavaScript and in Lua.
isScenarioTypeEnabled(scenarioType: string): booleanisScenarioTypeEnabled(scenarioType: string): booleanUsage
const result = isScenarioTypeEnabled(scenarioType);local result = isScenarioTypeEnabled(scenarioType)Parameters
| Parameter | Type | JavaScript | Lua |
|---|---|---|---|
scenarioType | string | string | string |
Returns
BOOL JavaScript boolean, Lua booleanNotes
From the community native database. Names are LS:MP’s; samples may be written for C++ or another framework.
Full list of scenario types used in scripts by DurtyFree: https://github.com/DurtyFree/gta-v-data-dumps/blob/master/scenariosCompact.json
Occurrences in the b617d scripts:
"PROP_HUMAN_SEAT_CHAIR",
"WORLD_HUMAN_DRINKING",
"WORLD_HUMAN_HANG_OUT_STREET",
"WORLD_HUMAN_SMOKING",
"WORLD_MOUNTAIN_LION_WANDER",
"WORLD_HUMAN_DRINKING"
Sometimes used together with isStringNullOrEmpty in the scripts.
scenarioType could be the same as scenarioName, used in for example taskStartScenarioAtPosition.
Reference
- Namespace
- Tasks TASK
- In the game
BOOL IS_SCENARIO_TYPE_ENABLED(const char* scenarioType)- Hash
0x3A815DB3EA088722