• Including lua file (Clientside)
    2 replies, posted
Hello. I've recently being experienced weird issues with including files clientside (on a dedicated server). I'm pretty sure it's just me that do it wrong so I'm in need of assistance. To the problem: The file I want included is called thing.lua. It's placed in addons/testaddon/lua/content/ In addons/testaddon/lua/autorun/client/ I have a file called includefile.lua (I know the names don't really matter). Inside this file I will include the thing.lua file to run it. I've attempted to do this several ways: [lua] -- First method include("content/thing.lua") -- Second method include("../content/thing.lua") -- Also tried to delay it a bit timer.Simple(5, function() include("content/thing.lua") end) [/lua] No matter how I do it I get: Couldn't include file 'content/thing.lua(or the other method path)' (File not found) [...] Windows Dedicated Server Thanks!
You need a addCSLuaFile for them to get it. Add it in server autorun lua foldee
Yea, I just thought of that as well. Thank you for the confirmation!
Sorry, you need to Log In to post a reply to this thread.