__namecall hook.
Parameters
string
required
The method name to substitute.
Example
Errors
Related
getnamecallmethod: read the current method name.
Documentation Index
Fetch the complete documentation index at: /llms.txt
Use this file to discover all available pages before exploring further.
Rewrite the method name inside a __namecall hook.
setnamecallmethod(method: string) -> ()
__namecall hook.
hookmetamethod(game, "__namecall", function(self, ...)
if getnamecallmethod() == "Kick" then
setnamecallmethod("GetFullName")
end
return oldNamecall(self, ...)
end)
| Message | Condition |
|---|---|
the replacement namecall method is not a string | Argument 1 was not a string. |
the replacement namecall method could not be read as a string | The string could not be read. |
not currently inside a namecall | No namecall is in progress. |
getnamecallmethod: read the current method name.