server side LUA-script implementation