aboutsummaryrefslogtreecommitdiff
path: root/advtrains/textures
Commit message (Collapse)AuthorAge
* Add bord computer to trainsorwell962018-01-09
| | | | | | | | Features: - couple/decouple trains from a driver stand - new couple lock system (owner based, overridable by 'train_remove' privilege) - all train operators can now change the inside/outside text, allows for multilines Accessible via right-click menu or by pressing Sneak+Jump keys
* Remove zip release files, move mod to root, exclude assets from Makefile (#92)rubenwardy2017-09-20
|
* Restructure mod directoryorwell962017-01-04
|
* Add Automatic Train Control systemorwell962017-01-04
|
* Turning mod into a modpack and separating the trains from the core modorwell962016-12-20
com">This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details. You should have received a copy of the GNU Lesser General Public License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. */ #ifndef S_BASE_H_ #define S_BASE_H_ #include <iostream> #include <string> extern "C" { #include <lua.h> } #include "irrlichttypes.h" #include "jthread/jmutex.h" #include "jthread/jmutexautolock.h" #include "common/c_types.h" #define SCRIPTAPI_LOCK_DEBUG class Server; class Environment; class GUIEngine; class ServerActiveObject; class ScriptApiBase { public: ScriptApiBase(); virtual ~ScriptApiBase(); bool loadMod(const std::string &scriptpath, const std::string &modname); bool loadScript(const std::string &scriptpath); /* object */ void addObjectReference(ServerActiveObject *cobj); void removeObjectReference(ServerActiveObject *cobj); protected: friend class LuaABM; friend class InvRef; friend class ObjectRef; friend class NodeMetaRef; friend class ModApiBase; friend class ModApiEnvMod; friend class LuaVoxelManip; lua_State* getStack() { return m_luastack; } void realityCheck(); void scriptError(const char *fmt, ...); void stackDump(std::ostream &o); Server* getServer() { return m_server; } void setServer(Server* server) { m_server = server; } Environment* getEnv() { return m_environment; } void setEnv(Environment* env) { m_environment = env; } GUIEngine* getGuiEngine() { return m_guiengine; } void setGuiEngine(GUIEngine* guiengine) { m_guiengine = guiengine; } void objectrefGetOrCreate(ServerActiveObject *cobj); void objectrefGet(u16 id); JMutex m_luastackmutex; #ifdef SCRIPTAPI_LOCK_DEBUG bool m_locked; #endif private: lua_State* m_luastack; Server* m_server; Environment* m_environment; GUIEngine* m_guiengine; }; #endif /* S_BASE_H_ */