View Single Post
09-12-18, 03:51 AM
Join Date: Jun 2006
In short: No, you can't create a merge in that way.
If you break things out into individual files they have their own context (e.g, locals are local to that space, etc) which is a good thing for managing large amounts of code and simplifies design and debugging.
Those file segments have access to as shared namespace that is passed to each segment -- to capture it, place " local addonName, nameSpace = ... " (the first var is the string-name of the addon, the second is the namespace table) at the top of each file.
If you just want to break things apart, store your addon-global vars in the namespace table, then you can declare the file-order in the .toc file, which loads and executes in order, iirc.
Not sure why you'd want to go through that rather than use they hyper-friendly lua function but it might get you past one-massive-why-would-you-do-that-to-yourself-file problem.
User Configurable To-Do List
Choose the Font for Your Mail
View Public Profile
Send a private message to VincentSDSH
Find More Posts by VincentSDSH