_STRING_SPLIT_AND_COUNT_SEGMENTS
Splits inputString on any of the characters in delimiters and returns the number of segments.
Signature
int _STRING_SPLIT_AND_COUNT_SEGMENTS(const char* inputString, const char* delimiters); // 0x94E8CA3DEE952789 b1207Parameters
| # | Name | Type |
|---|---|---|
| 1 | inputString | const char* |
| 2 | delimiters | const char* |
Facts
| Name | _STRING_SPLIT_AND_COUNT_SEGMENTS |
|---|---|
| Hash | 0x94E8CA3DEE952789 |
| Namespace | |
| Returns | int |
| Game build | 1207 |
Examples
Calls by hash work in every RedM runtime. Replace the placeholder arguments with your own values.
local result = Citizen.InvokeNative(0x94E8CA3DEE952789, -- _STRING_SPLIT_AND_COUNT_SEGMENTS
"text", -- const char* inputString
"text", -- const char* delimiters
Citizen.ResultAsInteger()
)
print(result)const result = Citizen.invokeNative("0x94E8CA3DEE952789", // _STRING_SPLIT_AND_COUNT_SEGMENTS
"text", // const char* inputString
"text", // const char* delimiters
Citizen.resultAsInteger()
);
console.log(result)int result = Function.Call<int>((Hash)0x94E8CA3DEE952789, // _STRING_SPLIT_AND_COUNT_SEGMENTS
"text", // const char* inputString
"text" // const char* delimiters
);Related MISC natives
Facts compiled from community research (alloc8or/rdr3-nativedb-data, femga/rdr3_discoveries); descriptions and examples by The Lab.