Commit Graph

112 Commits

Author SHA1 Message Date
Rochet2
346d88dd5e Eluna fix mangos compilation 2018-01-15 22:19:17 +02:00
Rochet2
0aef6217af Merge pull request #256 from MangosServer/master
MaNGOS requested changes
2018-01-15 15:45:24 +02:00
Foereaper
d644b3a7f0 Added game event related methods 2017-11-12 12:37:27 +01:00
H0zen
7cc2b1306e MaNGOS changes 2017-11-10 22:41:38 +02:00
Rochet2
86a0ae93f0 Fix TC build 2017-08-02 21:16:03 +03:00
Rochet2
9e97353f9d Enhance sql documentation 2017-07-30 14:33:40 +03:00
Rochet2
5638cc53f8 Implement delay ranges https://github.com/ElunaLuaEngine/Eluna/issues/205 2017-07-25 21:51:46 +03:00
Rochet2
963352e4f5 Move GetPlayers from global method to map method.
For backwards compatibility for GetPlayersInMap(mapid, instid) use GetMapById(mapid, instid):GetPlayers()
2017-07-19 19:41:49 +03:00
Rochet2
199efc2ec8 Change documentation a bit 2017-07-19 18:56:22 +03:00
Rochet2
e8849c02cd Update hook documentations 2017-07-19 18:54:51 +03:00
Rochet2
8b3cbd1c7d Add game event start/stop hooks https://github.com/ElunaLuaEngine/Eluna/issues/143 2017-07-19 18:41:39 +03:00
Rochet2
f1117fc2d8 Fix TC build 2017-06-24 23:22:43 +03:00
Rochet2
39afb1d3b7 Fix TC build after fbbe247114 2017-04-19 21:00:22 +03:00
Rochet2
cc2037461c Optimize table usage in methods 2017-03-19 16:27:46 +02:00
Rochet2
b7c379a42c Change Eluna to a global variable
Remove Eluna* from being passed. You can now get it through Eluna::GetEluna(L)
Change function call cleanup to lua_settop instead of manual loop
Explicitly delete the copy constructor and copy assignment operators
2017-03-19 15:48:48 +02:00
Rochet2
90c5c02c69 Fix crash when accessing players not on any map 2017-03-15 12:42:57 +02:00
Rochet2
3a6b8a3491 Fix TC build after 7567cafec8 2017-03-06 20:49:51 +02:00
Rochet2
8aad5257f0 Fix gameobject rotations. Closes https://github.com/ElunaLuaEngine/Eluna/issues/207 2016-10-11 21:17:47 +03:00
Rochet2
e91a065239 Fix TC build 2016-08-01 18:28:43 +03:00
Nicolas Viseur
e686bcb33f Update PerformIngameSpawn() (#202)
Update PerformIngameSpawn() when spawning a gobject with the save boolean set on true, so the gobject will spawn ingame just like in the cs_gobject.cpp file, instead of not spawning at all.
2016-07-02 10:14:11 +03:00
Rochet2
d6cbadfec9 Fix https://github.com/ElunaLuaEngine/Eluna/issues/194 2016-03-17 11:39:18 +02:00
Rochet2
4cd17fd9d9 packet send hook can no longer return new packet 2016-03-14 21:42:12 +02:00
Rochet2
37eec855c5 Add MaNGOS required changes 2016-03-04 23:25:43 +02:00
Rochet2
849d26e3a0 Fix TC build 2016-02-14 22:20:19 +02:00
Rochet2
33e3bf9de2 Fix some mangos compatibility 2016-01-24 19:29:42 +02:00
Rochet2
cc5f623b5c Update GlobalMethods.h
Fix some typos in documentation reported by Pursche
2016-01-24 11:52:38 +02:00
Rochet2
2fce645b7e new year 2016-01-05 20:19:47 +02:00
Rochet2
3f3de007ef More AddTaxiPath documentation 2015-12-16 22:36:25 +02:00
Rochet2
2bb387dcff Update GlobalMethods.h 2015-12-16 21:06:37 +02:00
Rochet2
28161fa2fc Remove corpse methods (report if needing them) and made changes to objectaccessor required by TC
See 402a3c45ff for more
2015-09-30 22:01:36 +03:00
Rochet2
8daaf04994 Fix TC build 2015-09-24 11:48:07 +03:00
Rochet2
34439b2ff3 Eluna fix TC taxi path node container 2015-09-15 01:20:39 +03:00
Rochet2
581c176da1 Fix and unify GetCoreVersion
Fixed for cmangos (tbc)
2015-09-06 14:01:47 +03:00
Patman64
31470c2cf7 Allow scripting of instances w/ persistent data
Some fixes for TC and changes overall

Pass map object to hook via function arguments

The map object is no longer stored inside the instance data table.

Fix mistake in base64 decoder

It was failing whenever it encountered a '=' character, which is
completely valid.

Make ElunaInstanceAI::Load always load something

When it failed to load data, it was leaving nothing on the stack. Since
subsequent code expected Load to always load something, this was causing
issues.

Now, when Load fails to load anything, it just leaves a new empty table on
the stack.

Also: the error messages for Load have been improved.

Modify lua-marshal to allow saving of functions/userdata.

Some additional code was needed to save functions due to the inclusion of
a reference to _ENV within their upvalues (since Lua 5.2).

During encoding, a placeholder is left where the _ENV reference would be.
During decoding, a reference to the current _G is swapped with the
placeholder.

Make ElunaInstanceAI::Load re-initialize if data failed to load.

Also improve error messages by not including the raw data.

Improve storage format of upvalues

Instead of storing the upvalues by name, store by index. A wrapper is
still used in case the upvalue is nil, to prevent holes in the upvalues table.

A special field in the upvalues table, "E", is used to store the index of
the _ENV reference (if there was one). A reference to the current globals
table is set as the upvalue upon decoding.

Remove wrapping from upvalue storing, instead save amount of upvalues
2015-08-01 00:35:41 +03:00
Rochet2
561e38e037 Fix some documentation 2015-07-15 18:23:31 +03:00
Foereaper
447021e849 Fix RegisterGroupEvent hooks
Thanks to Grandelf, see http://emudevs.com/showthread.php/4953 for more info.
2015-06-22 19:13:57 +02:00
Patman64
51d6454f04 Fix cMaNGOS build 2015-06-08 00:10:10 -04:00
Rochet2
3aa6d0544b Fix TC compile 2015-06-04 12:30:43 +03:00
Patman64
7397c98a61 Merge new_bindings, closes #151
Refer to 6194ddb43c for new C++11 required changes for mangos based cores
2015-06-01 20:37:32 +03:00
Rochet2
5c68b7301a Fix few doc types 2015-05-11 21:19:52 +03:00
Patman64
3490d21bcd Make the register functions optionally return a cancel callback.
It's now possible to have complete flexibility with cancelling bindings,
i.e. it's possible to re-implement all of the other ways to cancel bindings
using the callback.

This sytem has been designed with complete safety in mind:
 - It is safe to call the callback more than once (does nothing after the
   first call).
 - The callback does not expire, and can be stored for as long as
   necessary.
 - If a callback is returned, there is no other way to cancel the binding
   (again, due to safety).
2015-05-01 20:29:48 -04:00
Rochet2
210f36ba54 Fix a warning on linux 2015-03-07 21:28:33 +02:00
Rochet2
6badad938d Add more GUID documentation 2015-03-07 17:12:09 +02:00
Patman64
cda4607493 Allow clear events functions to clear events of all types. 2015-02-21 23:05:12 -05:00
Rochet2
6b5fed561c Eluna fix problem with reloading timed events 2015-02-15 02:45:29 +02:00
Rochet2
1b9a2ae018 MangosTwo change fixes 2015-02-15 02:44:24 +02:00
Rochet2
849651d4c0 Change player access from sessions to players 2015-02-15 02:44:23 +02:00
Rochet2
e6e4ecdab1 Fix push and taxi crashes and add new taxi changes 2015-01-24 02:29:11 +02:00
Tommy
9fe397aaf5 Fix RemoveCorpse and RemoveCorpse return values
Small bracket clean up
2015-01-20 23:23:58 -05:00
Rochet2
3d645d8048 Add StackTracePlus, Rewrite not to recreate eluna on reload 2015-01-20 17:05:41 +02:00