add template script

This commit is contained in:
Syping 2021-08-06 06:04:34 +02:00
parent b7992849fd
commit 37a047012b

29
script/xmppbot.lua Normal file
View file

@ -0,0 +1,29 @@
function jidInitialised(account)
print("Account initialised")
print("From: "..jid(account))
print("Instance: "..jin(account))
end
function jidConnected(account)
print("Account connected")
print("From: "..jid(account))
print("Instance: "..jin(account))
end
function jidDisconnected(account)
print("Account disconnected")
print("From: "..jid(account))
print("Instance: "..jin(account))
end
function messageReceived(from, to, message)
print("Message received")
print("From: "..jid(from))
print("Instance: "..jin(from))
print("Message: "..message)
end
function presenceReceived(from, presenceType, statusType, statusText)
print("Presence received")
print("From: "..jid(from))
print("Instance: "..jin(from))
print("Presence Type: "..presenceType)
print("Status Type: "..statusType)
print("Status Text: "..statusText)
end