Last active
January 1, 2016 11:19
-
-
Save PilzAdam/8136915 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
towny = {} | |
local function make_registration() | |
local t = {} | |
local registerfunc = function(func) table.insert(t, func) end | |
return t, registerfunc | |
end | |
towny.registered_on_town_join, towny.register_on_town_join = make_registration() | |
-- wenn dann ein player einer town joined: (also wenn der spielre den button drückt oder so) | |
for _,func in ipairs(towny.registered_on_town_join) do | |
func() | |
end | |
-- neue funktionen registrieren mit: (auch in anderen mods die towny in depends.txt haben) | |
towny.register_on_town_join(func) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment