getnamecallmethod
Returns the current __namecall method name.
Syntax
getnamecallmethod() -> string
Parameters
This function takes no parameters.
Returns
| Type | Description |
|---|---|
string | The current __namecall method name |
Description
getnamecallmethod is part of the Metatables library. Metatable helpers operate below normal Lua protection: they read raw metatables, replace metamethods and inspect namecalls.
The call is read-only: it resolves the current value when invoked and does not change the underlying state.
Example
hookmetamethod(game, "__namecall", function(self, ...)
print(getnamecallmethod())
return self
end)
Notes
- Metatable changes are applied directly to the live object.