This commit is contained in:
TheLuda 2008-10-15 18:25:49 +02:00
parent 92441a0241
commit 2c38c1a8ee
8 changed files with 23 additions and 23 deletions

View file

@ -25,13 +25,13 @@ AM_CPPFLAGS = $(MANGOS_INCLUDES) -I$(srcdir) -I$(srcdir)/../../../dep/include -I
# libmangosscript shared library will later be reused by world server daemon.
lib_LTLIBRARIES = libmangosscript.la
libmangosscript_la_SOURCES = \
ScriptMgr.cpp \
ScriptMgr.h \
config.h \
system.cpp \
Scripts/sc_default.cpp \
Scripts/sc_defines.cpp \
Scripts/sc_defines.h
ScriptMgr.cpp \
ScriptMgr.h \
config.h \
system.cpp \
Scripts/sc_default.cpp \
Scripts/sc_defines.cpp \
Scripts/sc_defines.h
## libtool settings
# API versioning
@ -51,6 +51,6 @@ libmangosscript_la_LIBFLAGS = -version-info $(LTMANGOS_CURRENT):$(LTMANGOS_REVIS
## Additional files to include when running 'make dist'
# Scripts defaults.
EXTRA_DIST = \
Scripts/sc_default.cpp \
Scripts/sc_defines.cpp \
Scripts/sc_defines.h
Scripts/sc_default.cpp \
Scripts/sc_defines.cpp \
Scripts/sc_defines.h

View file

@ -3,7 +3,7 @@
1 - create a file myscript.cpp in scripts folder.
2 - copy the content of script_default.cpp, it as the structure on how the scripting fuctions are organized.
dont forget to change the name of fuctions, like GossipHello_default to GossipHello_myscript.
dont forget to change the name of fuctions, like GossipHello_default to GossipHello_myscript.
3 - in fuction AddSC_default change to AddSC_myscript.
4 - newscript->Name="default"; change the string to "myscript" this name is the one to be called from the db
@ -19,8 +19,8 @@ extern void AddSC_default();
and here
// -- Inicialize the Scripts to be Added --
AddSC_default();
// ----------------------------------------
AddSC_default();
// ----------------------------------------
now start using the player fuctions to script ;)
see the sc_defines.h for some fuctions to use.