mirror of
https://github.com/NotAKidoS/NAK_CVR_Mods.git
synced 2025-09-03 06:49:22 +00:00
[LuaNetworkVariables] fixed readmoe
This commit is contained in:
parent
0a01534aa4
commit
cc7762293d
1 changed files with 7 additions and 7 deletions
|
@ -28,13 +28,13 @@ function Start()
|
||||||
|
|
||||||
-- Registers "ButtonClickedEvent" as a networked event. This provides context alongside the arguments passed.
|
-- Registers "ButtonClickedEvent" as a networked event. This provides context alongside the arguments passed.
|
||||||
NetworkModule:RegisterEventCallback("ButtonClickedEvent", function(context, message)
|
NetworkModule:RegisterEventCallback("ButtonClickedEvent", function(context, message)
|
||||||
print("ButtonClickedEvent triggered by " .. tostring(context.senderName) .. " with message: " .. tostring(message))
|
print("ButtonClickedEvent triggered by " .. tostring(context.SenderName) .. " with message: " .. tostring(message))
|
||||||
print("Context details:")
|
print("Context details:")
|
||||||
print(" senderId: " .. tostring(context.senderId))
|
print(" SenderId: " .. tostring(context.SenderId))
|
||||||
print(" senderName: " .. tostring(context.senderName))
|
print(" SenderName: " .. tostring(context.SenderName))
|
||||||
print(" lastInvokeTime: " .. tostring(context.lastInvokeTime))
|
print(" LastInvokeTime: " .. tostring(context.LastInvokeTime))
|
||||||
print(" timeSinceLastInvoke: " .. tostring(context.timeSinceLastInvoke))
|
print(" TimeSinceLastInvoke: " .. tostring(context.TimeSinceLastInvoke))
|
||||||
print(" isLocal: " .. tostring(context.isLocal))
|
print(" IsLocal: " .. tostring(context.IsLocal))
|
||||||
end)
|
end)
|
||||||
|
|
||||||
-- Secondry example
|
-- Secondry example
|
||||||
|
@ -63,7 +63,7 @@ end
|
||||||
-- Listener Functions --
|
-- Listener Functions --
|
||||||
|
|
||||||
function OnCoolEventOccured(context, value, value2)
|
function OnCoolEventOccured(context, value, value2)
|
||||||
print("CoolEvent triggered by " .. tostring(context.senderName))
|
print("CoolEvent triggered by " .. tostring(context.SenderName))
|
||||||
print("Received values: " .. tostring(value) .. ", " .. tostring(value2))
|
print("Received values: " .. tostring(value) .. ", " .. tostring(value2))
|
||||||
print("Context details:")
|
print("Context details:")
|
||||||
print(" SenderId: " .. tostring(context.SenderId))
|
print(" SenderId: " .. tostring(context.SenderId))
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue