more lua stuff working now + cleanup client code

This commit is contained in:
Luuk van Oijen
2023-11-14 14:06:05 +01:00
parent 1c21298351
commit 4f57680a67
4 changed files with 228 additions and 144 deletions

View File

@@ -5,13 +5,16 @@ function onPluginLoaded()
print("HI!")
end
function onPlayerAuthenticated(name)
print("hi welcome mista " .. name)
function onPlayerAuthenticated(joined_name)
print("hi welcome mista " .. joined_name)
print("current players:")
for id, name in pairs(MP.GetPlayers()) do
print("- [" .. id .. "]" .. name)
end
print("yipee")
return 0 -- 0 = do not block
end
MP.RegisterEventHandler("onPluginLoaded", "onPluginLoaded")