GET_CURRENT_RESOURCE_NAME
Returns the name of the currently executing resource.
Signature
char* GET_CURRENT_RESOURCE_NAME();Returns char* — The name of the resource.
Description
Returns the name of the currently executing resource.
Usage
local retval = GetCurrentResourceName()
-- always works, by hash
local retval = Citizen.InvokeNative(0xe5e9ebbb, Citizen.ResultAsString())JavaScript and C#
const retval = GetCurrentResourceName();
// by hash
const retval = Citizen.invokeNative('0xe5e9ebbb', Citizen.returnResultAnyway(), Citizen.resultAsString());string retval = Function.Call<string>((Hash)0xe5e9ebbb);Sources
Something wrong or missing? Contribute a verified note — corrections ship through pull requests.