Setting up lua_scripts directory for azerothcore docker build #14850
Mrming1994
started this conversation in
Modules
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I'm running an AzerothCore server for personal access over LAN. I have the server running on docker as per the setup provided on the official website. I've also managed to attach the Eluna lua enging via the module provided on the AzerothCore GitHub.
I can see that Eluna has been successfully compiled with the worldserver, as I get this message following a call to :docker-compose up
ac-worldserver_1 | [Eluna]: Executed 0 Lua scripts in 0 ms
I also have no problems logging in via a client and playing normally.
Now, the problem I'm encountering is that I cannot seem to find where to place my lua scripts so that they will be used by the server. Digging through config files, I found this parameter in :azerothcore-wotlk/modules/mod-eluna-lua-engine/conf/mod_LuaEngine.conf.dist
Eluna.ScriptPath = "lua_scripts"
This constant is loaded into the main file, so I'm convinced this is the right place to be looking. However, there is no directory in the entire repository, including the attached module. I've tried placing it (and a basic script) in multiple subdirectories to no avail. Thinking it might be found outside the repository due to the use of docker, I ran and found a copy of the folder in this very inaccessible location:LuaEngine.cpplua_scriptshello_world.luasudo find / | grep lua_scripts
/var/snap/docker/common/var-lib-docker/overlay2/3d7f9d1de6602baf9a33ee24333ecdf01d537c2b7b439e90d645ff9643bfdd07/diff/azeroth-server/bin/lua_scripts
Obviously this is only accessible via , and I cannot easily use this location for development purposes.sudo
As a last resort, I tried changing the constant to an absolute path in the repository, but this was also unsuccessful. No scripts loaded, no hello world on login. Anyone know where I might look or place the directory?Eluna.ScriptPath
For reference, the :hello_world.lua
local PLAYER_EVENT_ON_LOGIN = 3
local function OnLogin(event, player)
player:SendBroadcastMessage("Hello world")
end
RegisterPlayerEvent(PLAYER_EVENT_ON_LOGIN, OnLogin)
Beta Was this translation helpful? Give feedback.
All reactions