Go Back   EQEmulator Home > EQEmulator Forums > Development > Development::Server Code Submissions

Reply
 
Thread Tools Display Modes
  #1  
Old 02-03-2013, 10:24 AM
Tabasco's Avatar
Tabasco
Discordant
 
Join Date: Sep 2009
Posts: 269
Default

Good work! I always enjoyed working with lua and I'm looking forward to hooking this into some kind of general modding framework.
__________________
http://dungeoncrawl.us.to
Reply With Quote
  #2  
Old 02-03-2013, 10:59 AM
Zaela_S
Hill Giant
 
Join Date: Jun 2012
Posts: 216
Default

Oh, spotted one little mistake at the top of the first file, emblua.h:

Code:
#ifdef EMBLUA
#include "lua.hpp"
#include "masterentity.h"
#endif
should be

Code:
#ifdef EMBLUA
#include "lua.hpp"
#endif
#include "masterentity.h"
Reply With Quote
  #3  
Old 02-03-2013, 10:03 PM
cavedude's Avatar
cavedude
The PEQ Dude
 
Join Date: Apr 2003
Location: -
Posts: 1,988
Default

Thank you for sharing! I'm very excited to get working on this.


Here are the required changes to CMake if anybody else wishes to try it out right away:

Code:
Index: CMakeLists.txt
===================================================================
--- CMakeLists.txt	(revision 2480)
+++ CMakeLists.txt	(working copy)
@@ -91,11 +91,13 @@
 ADD_DEFINITIONS(-DSHAREMEM)
 ADD_DEFINITIONS(-DINVERSEXY)
 ADD_DEFINITIONS(-DFIELD_ITEMS)
+ADD_DEFINITIONS(-DEMBLUA)
 
 FIND_PACKAGE(ZLIB REQUIRED)
 FIND_PACKAGE(MySQL REQUIRED)
 FIND_PACKAGE(PerlLibs REQUIRED)
-INCLUDE_DIRECTORIES("${ZLIB_INCLUDE_DIRS}" "${PERL_INCLUDE_PATH}" "${MySQL_INCLUDE_DIR}")
+FIND_PACKAGE(Lua51 REQUIRED)
+INCLUDE_DIRECTORIES("${ZLIB_INCLUDE_DIRS}" "${PERL_INCLUDE_PATH}" "${MySQL_INCLUDE_DIR}" "${LUA_INCLUDE_DIR}")
 
 IF(EQEMU_BUILD_SERVER OR EQEMU_BUILD_LOGIN)
     ADD_SUBDIRECTORY(common)
Index: zone/CMakeLists.txt
===================================================================
--- zone/CMakeLists.txt	(revision 2480)
+++ zone/CMakeLists.txt	(working copy)
@@ -16,6 +16,7 @@
     command.cpp
     doors.cpp
     effects.cpp
+    emblua.cpp
     embparser.cpp
     embperl.cpp
     embxs.cpp
@@ -31,6 +32,7 @@
     horse.cpp
     inventory.cpp
     loottables.cpp
+    lua_spawn.cpp
     Map.cpp
     merc.cpp
     mob.cpp
@@ -100,6 +102,7 @@
     client_packet.h
     command.h
     doors.h
+    emblua.h
     embparser.h
     embperl.h
     embxs.h
@@ -114,6 +117,9 @@
     hate_list.h
     horse.h
     loottable.h
+    lua_general.h
+    lua_mob.h
+    lua_spawn.h
     map.h
     masterentity.h
     maxskill.h
@@ -161,7 +167,7 @@
 
 ADD_DEFINITIONS(-DZONE)
 
-TARGET_LINK_LIBRARIES(zone Common ${PERL_LIBRARY} debug ${MySQL_LIBRARY_DEBUG} optimized ${MySQL_LIBRARY_RELEASE})
+TARGET_LINK_LIBRARIES(zone Common ${PERL_LIBRARY} ${LUA_LIBRARY} debug ${MySQL_LIBRARY_DEBUG} optimized ${MySQL_LIBRARY_RELEASE})
 
 IF(MSVC)
     SET_TARGET_PROPERTIES(zone PROPERTIES LINK_FLAGS_RELEASE "/OPT:REF /OPT:ICF")
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

   

All times are GMT -4. The time now is 08:34 PM.


 

Everquest is a registered trademark of Daybreak Game Company LLC.
EQEmulator is not associated or affiliated in any way with Daybreak Game Company LLC.
Except where otherwise noted, this site is licensed under a Creative Commons License.
       
Powered by vBulletin®, Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Template by Bluepearl Design and vBulletin Templates - Ver3.3