This repository has been archived by the owner on Apr 17, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 48
HookPoints: SignTextGet
Luke edited this page Feb 12, 2015
·
5 revisions
When any sign is viewed, this event is triggered.
Data Type | Object | Description |
---|---|---|
int | X | X coordinate of the sign. |
int | Y | Y coordinate of the sign. |
short | SignIndex | The sign index. |
string | Text | Text on the sign. |
C#
[Hook(HookOrder.NORMAL)]
void OnSignTextGet(ref HookContext ctx, ref HookArgs.SignTextGet args)
{
Tools.WriteLine(args.Text);
}
Lua
function YourPlugin:Initialized()
export.Hooks = {}
export.Hooks.SignTextGet =
{
Call = export.OnSignTextGet,
}
end
function YourPlugin:OnSignTextGet(ctx, args)
Tools.WriteLine(args.Text)
end