diff options
author | Seline <none@none> | 2008-10-14 11:57:03 -0500 |
---|---|---|
committer | Seline <none@none> | 2008-10-14 11:57:03 -0500 |
commit | 2265aef916e3b2d63d87faa68a2b51e7d747c54c (patch) | |
tree | b05420685b7d202aade6f70a6f511adbfb79e37f /src/bindings/interface | |
parent | 222cbfd4644412fb8e5aeed7c37c88797d09964a (diff) |
[svn] * Merge Temp dev SVN with Assembla.
* Changes include:
- Implementation of w12x's Outdoor PvP and Game Event Systems.
- Temporary removal of IRC Chat Bot (until infinite loop when disabled is fixed).
- All mangos -> trinity (to convert your mangos_string table, please run mangos_string_to_trinity_string.sql).
- Improved Config cleanup.
- And many more changes.
--HG--
branch : trunk
Diffstat (limited to 'src/bindings/interface')
-rw-r--r-- | src/bindings/interface/Makefile.am | 3 | ||||
-rw-r--r-- | src/bindings/interface/ScriptMgr.cpp | 50 | ||||
-rw-r--r-- | src/bindings/interface/ScriptMgr.h | 10 | ||||
-rw-r--r-- | src/bindings/interface/Scripts/sc_default.cpp | 8 | ||||
-rw-r--r-- | src/bindings/interface/Scripts/sc_defines.cpp | 8 | ||||
-rw-r--r-- | src/bindings/interface/Scripts/sc_defines.h | 8 | ||||
-rw-r--r-- | src/bindings/interface/config.h | 14 | ||||
-rw-r--r-- | src/bindings/interface/system.cpp | 8 |
8 files changed, 62 insertions, 47 deletions
diff --git a/src/bindings/interface/Makefile.am b/src/bindings/interface/Makefile.am index 7da976f6cbf..bcca2128203 100644 --- a/src/bindings/interface/Makefile.am +++ b/src/bindings/interface/Makefile.am @@ -4,7 +4,7 @@ # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 3 of the License, or +# the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, @@ -52,3 +52,4 @@ libtrinityscript_la_LIBADD = $(MYSQL_LIBS) $(POSTGRE_LIBS) EXTRA_DIST = \ Readme.txt + diff --git a/src/bindings/interface/ScriptMgr.cpp b/src/bindings/interface/ScriptMgr.cpp index 100159803f5..2db437526d1 100644 --- a/src/bindings/interface/ScriptMgr.cpp +++ b/src/bindings/interface/ScriptMgr.cpp @@ -1,5 +1,7 @@ /* - * Copyright (C) 2005-2008 MaNGOS <http://www.mangosproject.org/> + * Copyright (C) 2008 Trinity <http://www.trinitycore.org/> + * + * Thanks to the original authors: MaNGOS <http://www.mangosproject.org/> * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -8,12 +10,12 @@ * * 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 + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ #include "config.h" @@ -34,7 +36,7 @@ int num_inst_scripts; extern void AddSC_default(); // ------------------- -MANGOS_DLL_EXPORT +TRINITY_DLL_EXPORT void ScriptsFree() { // Free resources before library unload for(int i=0;i<nrscripts;i++) @@ -47,7 +49,7 @@ void ScriptsFree() num_inst_scripts = 0; } -MANGOS_DLL_EXPORT +TRINITY_DLL_EXPORT void ScriptsInit() { nrscripts = 0; @@ -76,7 +78,7 @@ Script* GetScriptByName(std::string Name) return NULL; } -MANGOS_DLL_EXPORT +TRINITY_DLL_EXPORT bool GossipHello ( Player * player, Creature *_Creature ) { Script *tmpscript = GetScriptByName(_Creature->GetScriptName()); @@ -86,7 +88,7 @@ bool GossipHello ( Player * player, Creature *_Creature ) return tmpscript->pGossipHello(player,_Creature); } -MANGOS_DLL_EXPORT +TRINITY_DLL_EXPORT bool GossipSelect( Player *player, Creature *_Creature,uint32 sender, uint32 action ) { debug_log("DEBUG: Gossip selection, sender: %d, action: %d",sender, action); @@ -98,7 +100,7 @@ bool GossipSelect( Player *player, Creature *_Creature,uint32 sender, uint32 act return tmpscript->pGossipSelect(player,_Creature,sender,action); } -MANGOS_DLL_EXPORT +TRINITY_DLL_EXPORT bool GossipSelectWithCode( Player *player, Creature *_Creature, uint32 sender, uint32 action, const char* sCode ) { debug_log("DEBUG: Gossip selection, sender: %d, action: %d",sender, action); @@ -110,7 +112,7 @@ bool GossipSelectWithCode( Player *player, Creature *_Creature, uint32 sender, u return tmpscript->pGossipSelectWithCode(player,_Creature,sender,action,sCode); } -MANGOS_DLL_EXPORT +TRINITY_DLL_EXPORT bool QuestAccept( Player *player, Creature *_Creature, Quest *_Quest ) { Script *tmpscript = GetScriptByName(_Creature->GetScriptName()); @@ -120,7 +122,7 @@ bool QuestAccept( Player *player, Creature *_Creature, Quest *_Quest ) return tmpscript->pQuestAccept(player,_Creature,_Quest); } -MANGOS_DLL_EXPORT +TRINITY_DLL_EXPORT bool QuestSelect( Player *player, Creature *_Creature, Quest *_Quest ) { Script *tmpscript = GetScriptByName(_Creature->GetScriptName()); @@ -130,7 +132,7 @@ bool QuestSelect( Player *player, Creature *_Creature, Quest *_Quest ) return tmpscript->pQuestSelect(player,_Creature,_Quest); } -MANGOS_DLL_EXPORT +TRINITY_DLL_EXPORT bool QuestComplete( Player *player, Creature *_Creature, Quest *_Quest ) { Script *tmpscript = GetScriptByName(_Creature->GetScriptName()); @@ -140,7 +142,7 @@ bool QuestComplete( Player *player, Creature *_Creature, Quest *_Quest ) return tmpscript->pQuestComplete(player,_Creature,_Quest); } -MANGOS_DLL_EXPORT +TRINITY_DLL_EXPORT bool ChooseReward( Player *player, Creature *_Creature, Quest *_Quest, uint32 opt ) { Script *tmpscript = GetScriptByName(_Creature->GetScriptName()); @@ -150,7 +152,7 @@ bool ChooseReward( Player *player, Creature *_Creature, Quest *_Quest, uint32 op return tmpscript->pChooseReward(player,_Creature,_Quest,opt); } -MANGOS_DLL_EXPORT +TRINITY_DLL_EXPORT uint32 NPCDialogStatus( Player *player, Creature *_Creature ) { Script *tmpscript = GetScriptByName(_Creature->GetScriptName()); @@ -160,7 +162,7 @@ uint32 NPCDialogStatus( Player *player, Creature *_Creature ) return tmpscript->pNPCDialogStatus(player,_Creature); } -MANGOS_DLL_EXPORT +TRINITY_DLL_EXPORT uint32 GODialogStatus( Player *player, GameObject *_GO ) { Script *tmpscript = NULL; @@ -172,7 +174,7 @@ uint32 GODialogStatus( Player *player, GameObject *_GO ) return tmpscript->pGODialogStatus(player,_GO); } -MANGOS_DLL_EXPORT +TRINITY_DLL_EXPORT bool ItemHello( Player *player, Item *_Item, Quest *_Quest ) { Script *tmpscript = NULL; @@ -184,7 +186,7 @@ bool ItemHello( Player *player, Item *_Item, Quest *_Quest ) return tmpscript->pItemHello(player,_Item,_Quest); } -MANGOS_DLL_EXPORT +TRINITY_DLL_EXPORT bool ItemQuestAccept( Player *player, Item *_Item, Quest *_Quest ) { Script *tmpscript = NULL; @@ -196,7 +198,7 @@ bool ItemQuestAccept( Player *player, Item *_Item, Quest *_Quest ) return tmpscript->pItemQuestAccept(player,_Item,_Quest); } -MANGOS_DLL_EXPORT +TRINITY_DLL_EXPORT bool GOHello( Player *player, GameObject *_GO ) { Script *tmpscript = NULL; @@ -208,7 +210,7 @@ bool GOHello( Player *player, GameObject *_GO ) return tmpscript->pGOHello(player,_GO); } -MANGOS_DLL_EXPORT +TRINITY_DLL_EXPORT bool GOQuestAccept( Player *player, GameObject *_GO, Quest *_Quest ) { Script *tmpscript = NULL; @@ -220,7 +222,7 @@ bool GOQuestAccept( Player *player, GameObject *_GO, Quest *_Quest ) return tmpscript->pGOQuestAccept(player,_GO,_Quest); } -MANGOS_DLL_EXPORT +TRINITY_DLL_EXPORT bool GOChooseReward( Player *player, GameObject *_GO, Quest *_Quest, uint32 opt ) { Script *tmpscript = NULL; @@ -232,7 +234,7 @@ bool GOChooseReward( Player *player, GameObject *_GO, Quest *_Quest, uint32 opt return tmpscript->pGOChooseReward(player,_GO,_Quest,opt); } -MANGOS_DLL_EXPORT +TRINITY_DLL_EXPORT bool AreaTrigger ( Player *player, AreaTriggerEntry* atEntry ) { Script *tmpscript = NULL; @@ -243,7 +245,7 @@ bool AreaTrigger ( Player *player, AreaTriggerEntry* atEntry ) return tmpscript->pAreaTrigger(player, atEntry); } -MANGOS_DLL_EXPORT +TRINITY_DLL_EXPORT bool ReceiveEmote ( Player *player, Creature *_Creature, uint32 emote ) { Script *tmpscript = GetScriptByName(_Creature->GetScriptName()); @@ -252,7 +254,7 @@ bool ReceiveEmote ( Player *player, Creature *_Creature, uint32 emote ) return tmpscript->pReceiveEmote(player,_Creature, emote); } -MANGOS_DLL_EXPORT +TRINITY_DLL_EXPORT bool ItemUse( Player *player, Item* _Item, SpellCastTargets const& targets) { Script *tmpscript = NULL; @@ -263,7 +265,7 @@ bool ItemUse( Player *player, Item* _Item, SpellCastTargets const& targets) return tmpscript->pItemUse(player,_Item,targets); } -MANGOS_DLL_EXPORT +TRINITY_DLL_EXPORT CreatureAI* GetAI(Creature *_Creature ) { Script *tmpscript = GetScriptByName(_Creature->GetScriptName()); @@ -272,7 +274,7 @@ CreatureAI* GetAI(Creature *_Creature ) return tmpscript->GetAI(_Creature); } -MANGOS_DLL_EXPORT +TRINITY_DLL_EXPORT InstanceData* CreateInstanceData(Map *map) { if(!map->IsDungeon()) return NULL; diff --git a/src/bindings/interface/ScriptMgr.h b/src/bindings/interface/ScriptMgr.h index 0cc0b4362b8..45bf084bc6a 100644 --- a/src/bindings/interface/ScriptMgr.h +++ b/src/bindings/interface/ScriptMgr.h @@ -1,5 +1,7 @@ /* - * Copyright (C) 2005-2008 MaNGOS <http://www.mangosproject.org/> + * Copyright (C) 2008 Trinity <http://www.trinitycore.org/> + * + * Thanks to the original authors: MaNGOS <http://www.mangosproject.org/> * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -8,12 +10,12 @@ * * 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 + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ #ifndef SCRIPTMGR_H @@ -86,7 +88,7 @@ extern int num_inst_scripts; #define VISIBLE_RANGE (50.0f) -struct MANGOS_DLL_DECL ScriptedAI : public CreatureAI +struct TRINITY_DLL_DECL ScriptedAI : public CreatureAI { ScriptedAI(Creature* creature) : m_creature(creature) {} ~ScriptedAI() {} diff --git a/src/bindings/interface/Scripts/sc_default.cpp b/src/bindings/interface/Scripts/sc_default.cpp index a37ef14c796..6125747d355 100644 --- a/src/bindings/interface/Scripts/sc_default.cpp +++ b/src/bindings/interface/Scripts/sc_default.cpp @@ -1,5 +1,7 @@ /* - * Copyright (C) 2005-2008 MaNGOS <http://www.mangosproject.org/> + * Copyright (C) 2008 Trinity <http://www.trinitycore.org/> + * + * Thanks to the original authors: MaNGOS <http://www.mangosproject.org/> * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -8,12 +10,12 @@ * * 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 + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ #include "sc_defines.h" diff --git a/src/bindings/interface/Scripts/sc_defines.cpp b/src/bindings/interface/Scripts/sc_defines.cpp index 0c93b89649b..787c68d246b 100644 --- a/src/bindings/interface/Scripts/sc_defines.cpp +++ b/src/bindings/interface/Scripts/sc_defines.cpp @@ -1,5 +1,7 @@ /* - * Copyright (C) 2005-2008 MaNGOS <http://www.mangosproject.org/> + * Copyright (C) 2008 Trinity <http://www.trinitycore.org/> + * + * Thanks to the original authors: MaNGOS <http://www.mangosproject.org/> * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -8,12 +10,12 @@ * * 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 + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ #include "sc_defines.h" diff --git a/src/bindings/interface/Scripts/sc_defines.h b/src/bindings/interface/Scripts/sc_defines.h index c906726f09d..0e47bfb2e2d 100644 --- a/src/bindings/interface/Scripts/sc_defines.h +++ b/src/bindings/interface/Scripts/sc_defines.h @@ -1,5 +1,7 @@ /* - * Copyright (C) 2005-2008 MaNGOS <http://www.mangosproject.org/> + * Copyright (C) 2008 Trinity <http://www.trinitycore.org/> + * + * Thanks to the original authors: MaNGOS <http://www.mangosproject.org/> * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -8,12 +10,12 @@ * * 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 + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ #ifndef SC_DEFINES_H diff --git a/src/bindings/interface/config.h b/src/bindings/interface/config.h index 68d428a3809..6959677178f 100644 --- a/src/bindings/interface/config.h +++ b/src/bindings/interface/config.h @@ -1,5 +1,7 @@ /* - * Copyright (C) 2005-2008 MaNGOS <http://www.mangosproject.org/> + * Copyright (C) 2008 Trinity <http://www.trinitycore.org/> + * + * Thanks to the original authors: MaNGOS <http://www.mangosproject.org/> * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -8,12 +10,12 @@ * * 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 + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ #ifndef CONFIG_H @@ -23,9 +25,9 @@ #ifdef WIN32 //#include <windows.h> -#define MANGOS_DLL_EXPORT extern "C" __declspec(dllexport) +#define TRINITY_DLL_EXPORT extern "C" __declspec(dllexport) #elif defined( __GNUC__ ) -#define MANGOS_DLL_EXPORT extern "C" +#define TRINITY_DLL_EXPORT extern "C" #else -#define MANGOS_DLL_EXPORT extern "C" export +#define TRINITY_DLL_EXPORT extern "C" export #endif diff --git a/src/bindings/interface/system.cpp b/src/bindings/interface/system.cpp index ad5548072e6..8da34985fe4 100644 --- a/src/bindings/interface/system.cpp +++ b/src/bindings/interface/system.cpp @@ -1,5 +1,7 @@ /* - * Copyright (C) 2005-2008 MaNGOS <http://www.mangosproject.org/> + * Copyright (C) 2008 Trinity <http://www.trinitycore.org/> + * + * Thanks to the original authors: MaNGOS <http://www.mangosproject.org/> * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -8,12 +10,12 @@ * * 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 + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ #ifdef WIN32 |