• Including a server-entity file in a SWEP file?
    1 replies, posted
I have a SWEP and I need to include an entity file. For some reason the wiki is rather unclear on exactly how it should be typed. I tried: include("drillentity/init.lua") include("lua/drillentity.lua") The wiki says: include( "myLuaFolder/myLuaFile.lua" ) But it makes no sense what folder they're talking about. My path file that I seek to include in the SWEP is: addons/banksystemworking/lua/entities/drillentity/init.lua
You should not include the entity from the SWEP. The entity should include its own files from its own init.lua. If you need to use functions from the drillentity then you should make them global functions OR extract them to a common library that is autorun.
Sorry, you need to Log In to post a reply to this thread.