1
0
Commit Graph

232 Commits

Author SHA1 Message Date
madmaxoft@gmail.com
90c398a392 Inventory code cleanup, players can now see each other's armor
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1493 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-05-19 18:22:37 +00:00
madmaxoft@gmail.com
25cda4e8b4 cItems: Added runtime bounds-checking to avoid server crashes with badly written plugins.
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1472 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-05-12 15:58:29 +00:00
nielsbreu@gmail.com
7dc9b2ce8d Fixed error while compiling.
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1464 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-05-09 15:08:20 +00:00
nielsbreu@gmail.com
4e44c4b33a function SpawnItemPickups is now exported to Lua. Lua is able to create a Items object.
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1463 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-05-09 14:32:27 +00:00
madmaxoft@gmail.com
7cbf36bf17 Refactored window clicking code to use different click actions
First part of solving FS #371; should fix #370.

git-svn-id: http://mc-server.googlecode.com/svn/trunk@1459 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-05-08 09:45:07 +00:00
madmaxoft@gmail.com
a0f7dea3be Added dtAdmin damage type for use in plugins
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1429 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-04-28 18:40:26 +00:00
keyboard.osh@gmail.com
b75fc5f4e8 Initial implementation of explosions and TNT block
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1392 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-04-18 02:42:45 +00:00
madmaxoft@gmail.com
a49c004278 Rewritten entities so that they are owned by individual chunks and ticked within their chunk's Tick()
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1385 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-04-13 21:02:10 +00:00
madmaxoft@gmail.com
58fb05980d Fixed a bit of coding style and function names in cItem
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1384 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-04-11 10:05:53 +00:00
madmaxoft@gmail.com
dc878898f3 Dispensers rewritten to use ItemGrid
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1383 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-04-10 21:40:30 +00:00
madmaxoft@gmail.com
929d299965 ItemGrid: Renamed all Item to Slot - better and consistent naming
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1381 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-04-10 21:03:15 +00:00
madmaxoft@gmail.com
cc26f16463 Added cItemGrid to represent an XY grid of items; converted chests to use cItemGrid.
http://forum.mc-server.org/showthread.php?tid=831

git-svn-id: http://mc-server.googlecode.com/svn/trunk@1380 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-04-10 19:52:03 +00:00
madmaxoft@gmail.com
502935c061 Mineshafts: Added random loot to generated chests and fixed chest direction
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1365 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-04-06 21:21:57 +00:00
madmaxoft@gmail.com
59f3adf210 MineShafts: Added tracks to corridors
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1342 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-03-31 19:23:09 +00:00
madmaxoft@gmail.com
41e0927843 cChunkDesc: Added the RandomFillRelCuboid() function
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1341 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-03-31 19:05:41 +00:00
madmaxoft@gmail.com
412a80b5c2 cCuboid: Added the IsCompletelyInside() function
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1339 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-03-31 18:22:55 +00:00
madmaxoft@gmail.com
394933fc47 Added cCuboid:Assign() and cChunkDesc:FloorRelCuboid()
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1333 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-03-31 16:22:35 +00:00
madmaxoft@gmail.com
ad10b8718f ChunkDesc: Extended the interface, RelCuboid functions now take either a cCuboid or a set of 6 coords.
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1330 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-03-30 21:03:56 +00:00
madmaxoft@gmail.com
c76092e329 ChunkDesc: Cuboid-based manipulation
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1324 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-03-29 20:47:51 +00:00
madmaxoft@gmail.com
a633c45e8e Cuboid: Added DoesIntersect(), more IsInside() and more constructors
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1323 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-03-29 19:45:42 +00:00
madmaxoft@gmail.com
d023589a19 Cuboid: Added the DifX/Y/Z functions
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1320 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-03-29 16:45:00 +00:00
madmaxoft@gmail.com
e0707a7af6 BlockArea: Implemented mirroring without meta manipulation
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1316 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-03-25 12:16:23 +00:00
madmaxoft@gmail.com
387135cdc3 Updated bindings for new cChunkDesc functions
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1288 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-03-19 10:16:18 +00:00
madmaxoft@gmail.com
1ed3b3aed2 Rewritten generators so that they use the cChunkDesc class (and thus can use cBlockArea merging)
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1282 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-03-17 17:55:03 +00:00
madmaxoft@gmail.com
ff403fdbf0 Added water and lava springs.
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1269 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-03-14 09:52:57 +00:00
madmaxoft@gmail.com
7593707713 Pickups are now being saved into Anvil.
Also changed cEntity rotation datatype to double

git-svn-id: http://mc-server.googlecode.com/svn/trunk@1262 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-03-09 14:35:43 +00:00
madmaxoft@gmail.com
9d2c841843 IPv6 support + removed cTCPLink from Lua API
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1253 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-03-05 09:53:29 +00:00
madmaxoft@gmail.com
01b24d73ea Player can sit in minecarts (but not move them yet)
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1249 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-03-03 19:05:11 +00:00
madmaxoft@gmail.com
0e2340ee34 Added missing item types, fixed placing stone walls.
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1243 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-03-03 14:00:49 +00:00
madmaxoft@gmail.com
39d5d6b85f Updated cEntity API; removed functions that are unusable from Lua, added a few query functions.
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1231 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-03-01 15:49:24 +00:00
madmaxoft@gmail.com
4ce0c5a983 Moved the Speed member into cEntity class instead of its descendants.
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1222 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-02-21 21:55:36 +00:00
madmaxoft@gmail.com
99876ea4ba Added HOOK_EXECUTE_COMMAND for intercepting executed commands and console commands.
Note that built-in console commands are exempt to this hook - they are always performed and the hook is not called. Also note that, for reasons unknown, the HookNotify plugin doesn't list the callback arguments.

git-svn-id: http://mc-server.googlecode.com/svn/trunk@1221 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-02-21 13:47:01 +00:00
madmaxoft@gmail.com
32ee4aaf1e Removed all E_ITEM_ symbols equivalent to E_BLOCK_, and all obsolete item and block symbols.
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1218 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-02-16 11:12:56 +00:00
madmaxoft@gmail.com
34b3c13404 Plugins can now bind console commands
FS #300
Most console commands are now implemented in the Core plugin.

git-svn-id: http://mc-server.googlecode.com/svn/trunk@1214 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-02-15 13:00:59 +00:00
madmaxoft@gmail.com
6aadbef815 Exported forgotten API functions in cPluginManager: ExecuteCommand(), ForceExecuteCommand()
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1212 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-02-13 20:05:57 +00:00
madmaxoft@gmail.com
8b1a8bee34 Added HOOK_WEATHER_CHANGING.
http://www.mc-server.org/support/index.php?do=details&task_id=299

git-svn-id: http://mc-server.googlecode.com/svn/trunk@1210 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-02-13 19:22:08 +00:00
madmaxoft@gmail.com
cb22e195e2 More API functions in cBlockArea: Create(), Fill(), FillRelArea()
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1208 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-02-11 12:27:02 +00:00
madmaxoft@gmail.com
345da37e96 Added cBlockArea:Merge() API function to merge two block areas using different strategies.
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1207 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-02-10 15:15:41 +00:00
madmaxoft@gmail.com
bda7c4ac13 Added cBlockArea:Expand() API function (untested)
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1203 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-02-09 11:03:22 +00:00
madmaxoft@gmail.com
b55afc940b cChunkDesc can now read and write cBlockAreas.
A simple example is provided in the Debuggers plugin.

git-svn-id: http://mc-server.googlecode.com/svn/trunk@1201 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-02-08 20:57:42 +00:00
madmaxoft@gmail.com
7c0a7d662d Prepared cChunkDesc for further API extension; used it as the sole container for generated chunk data, including entities / block entities.
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1200 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-02-08 16:01:44 +00:00
madmaxoft@gmail.com
fe7e07d69d Added cBlockArea:CopyTo() and :CopyFrom(), so now block areas can be duplicated easily.
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1199 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-02-07 10:45:30 +00:00
madmaxoft@gmail.com
ed47a8e409 cBlockArea can now be saved as a .schematic file.
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1198 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-02-07 10:09:42 +00:00
madmaxoft@gmail.com
afdbb1d71b cBlockArea can now be loaded from a .schematic file.
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1195 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-02-06 22:29:29 +00:00
madmaxoft@gmail.com
a091413125 Added a new API call to cBlockArea: Crop().
Also fixed cBlockArea:MakeIndex(), the indexing was wrong.

git-svn-id: http://mc-server.googlecode.com/svn/trunk@1194 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-02-06 18:22:30 +00:00
madmaxoft@gmail.com
dedb414a50 Added new hooks: OnChunkAvailable(), OnChunkUnloaded() and OnChunkUnloading(). Modified OnChunkGenerated() signature.
http://forum.mc-server.org/showthread.php?tid=464&pid=6312#pid6312

git-svn-id: http://mc-server.googlecode.com/svn/trunk@1193 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-02-05 19:57:22 +00:00
madmaxoft@gmail.com
019c8b5bc7 Moved command API into cPluginManager.
As specified in http://forum.mc-server.org/showthread.php?tid=765 , commands are now bound using a single function, cPluginManager:BindCommand().

git-svn-id: http://mc-server.googlecode.com/svn/trunk@1183 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-02-01 19:55:42 +00:00
madmaxoft@gmail.com
71bbf2d44b Renamed HOOK_KILLED to HOOK_KILLING to match naming conventions.
Also tweaked the mechanics so that plugins may revive without dropping other plugins out of the picture.

git-svn-id: http://mc-server.googlecode.com/svn/trunk@1182 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-01-28 16:54:11 +00:00
madmaxoft@gmail.com
05534bbee1 Renamed HOOK_COLLECT_PICKUP to HOOK_COLLECTING_PICKUP to match other hooks' naming.
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1180 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-01-28 16:17:26 +00:00
madmaxoft@gmail.com
67048ee057 Added cItems to Lua API.
Now HOOK_BLOCK_TO_PICKUPS is fully functional, as demonstrated by HookNotify.

git-svn-id: http://mc-server.googlecode.com/svn/trunk@1178 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-01-27 03:45:40 +00:00
madmaxoft@gmail.com
1a127f5510 Added the HOOK_BLOCK_TO_PICKUPS hook that fires when a block is dug up and should be converted to pickups.
Note that cItems is used in the function signature but not yet exported in the API, TODO!

git-svn-id: http://mc-server.googlecode.com/svn/trunk@1176 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-01-27 02:00:33 +00:00
madmaxoft@gmail.com
1a9960a396 Removed cMCLogger from Lua API
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1175 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-01-27 01:58:23 +00:00
madmaxoft@gmail.com
7a6ec4fb17 Changed HOOK_PLAYER_MOVED to HOOK_PLAYER_MOVING to match the scheme used for names.
-ING means the event is being processed and may be refused by a plugin, -ED means it has already happenned and the plugin cannot do anything about it.

git-svn-id: http://mc-server.googlecode.com/svn/trunk@1174 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-01-26 07:50:06 +00:00
madmaxoft@gmail.com
2960f43782 Merged the usable portion of the "gens" branch.
Splitting off the Composable generator and fiddling with LuaChunk / ChunkDesc is good, other generators not good yet.

git-svn-id: http://mc-server.googlecode.com/svn/trunk@1171 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-01-25 10:12:29 +00:00
madmaxoft@gmail.com
7632b5ed62 Renamed rclk hook to HOOK_PLAYER_RIGHT_CLICK.
http://forum.mc-server.org/showthread.php?tid=464&pid=6163#pid6163

git-svn-id: http://mc-server.googlecode.com/svn/trunk@1158 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-01-18 18:28:27 +00:00
madmaxoft@gmail.com
9fa8c4f45b Fixed missing bindings in cPlugin
FS #291 - crash on "/help" issued via client

git-svn-id: http://mc-server.googlecode.com/svn/trunk@1143 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-01-14 08:21:13 +00:00
madmaxoft@gmail.com
43e6840719 Merged branch "branches/hooks" into "trunk".
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1139 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-01-12 04:46:01 +00:00
madmaxoft@gmail.com
7860d5156a cBlockArea now has a GetBlockTypeMeta() and GetRelBlockTypeMeta() methods
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1118 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-01-04 05:20:14 +00:00
madmaxoft@gmail.com
0cc3ab7c1e cPickup now uses full cItem, instead of a pointer
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1114 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-12-28 02:45:20 +00:00
madmaxoft@gmail.com
b29af701b9 MTRand reference is now passed as a Tick() parameter so that it isn't created and destroyed over and over again. All entities will handle physics (empty callback for now)
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1096 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-12-22 10:15:53 +00:00
madmaxoft@gmail.com
afaf104b40 Added more constants into eEntityType; made them a compulsory parameter to the constructor, so that all entities have proper type.
Also added a few utility functions to cEntity for distinguishing the types (IsPlayer(), IsPickup() etc.)

git-svn-id: http://mc-server.googlecode.com/svn/trunk@1092 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-12-21 12:52:14 +00:00
madmaxoft@gmail.com
033af999ba Reworked the IsA() / GetClass() framework to actually be useful. Added GetParentClass().
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1090 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-12-21 12:21:20 +00:00
madmaxoft@gmail.com
912a1e7adc Refactored the TakeDamage API to take equipped weapon and armor into consideration (PvP untested)
http://forum.mc-server.org/showthread.php?tid=625

git-svn-id: http://mc-server.googlecode.com/svn/trunk@1087 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-12-21 11:04:08 +00:00
madmaxoft@gmail.com
2fcdbfd428 Added primary server version interface to cRoot and "primaryserverversion" console command.
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1059 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-11-20 21:28:43 +00:00
madmaxoft@gmail.com
6b34a94477 Cleanup: Removed deprecated functions from Lua API
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1033 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-11-11 14:05:48 +00:00
madmaxoft@gmail.com
e34f097543 Hopefully a fix for crash when chunks are added to a client being destroyed.
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1032 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-11-11 14:00:58 +00:00
madmaxoft@gmail.com
4cebaa99f8 Refactored the world time.
Now it is stored in two values - WorldAge (only incremented, plugins cannot change) and TimeOfDay (plugins can change). Since sub-tick precision is needed in Tick(), we store it both as number of seconds (double) and number of ticks (Int64) is calculated off of that.

git-svn-id: http://mc-server.googlecode.com/svn/trunk@1022 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-11-01 21:38:20 +00:00
madmaxoft@gmail.com
08a20492ef Added the [Server].PrimaryServerVersion setting to settings.ini; 1.4.2 gets the correct version
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1018 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-10-31 19:54:42 +00:00
madmaxoft@gmail.com
96f7246df1 Added cWorld:SpawnMob(PosX, PosY, PosZ, EntityType) to Lua API
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1014 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-10-28 14:57:35 +00:00
madmaxoft@gmail.com
e30bec4fd6 Double chests are now working, and with sound. (FS #69)
git-svn-id: http://mc-server.googlecode.com/svn/trunk@993 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-10-20 21:53:09 +00:00
madmaxoft@gmail.com
d006ea5337 Made cWorld's block query functions more orthogonal, added GetBlockInfo() returning all info on a block.
git-svn-id: http://mc-server.googlecode.com/svn/trunk@986 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-10-20 11:40:34 +00:00
faketruth
2a197705ac Converted some const char*s and std::strings to AStrings
Added a cPlayer:RemoveFromGroup() so players can be removed from groups programmatically
Added a cClientHandle:SetUsername to be used by Lua. I'm curious what ThuGie can do with his plugin.

git-svn-id: http://mc-server.googlecode.com/svn/trunk@978 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-10-18 21:54:56 +00:00
faketruth
41ba1a7642 Completely removed support for old style Lua plugins (can use both Plugin and NewPlugin in settings.ini for now)
Removed cPlugin_Lua, obviously
cPluginManager stores plugins by their (folder)name
cPluginManager now scans the Plugins folder for potential plugins and adds them as non-loaded plugins
Added a DisablePlugin and LoadPlugin to disable and load plugins on a per-plugin basis instead of all at once
cPluginManager::FindPlugins refreshes the plugin list by removing non-existing plugins and adding new plugins
Made it incredibly easy to use new plugins from the WebAdmin
Exposed some food/hunger related functions in cPlayer to Lua

git-svn-id: http://mc-server.googlecode.com/svn/trunk@959 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-10-13 23:34:47 +00:00
madmaxoft@gmail.com
a2f6243b21 Added delayed ticking to Lua API
git-svn-id: http://mc-server.googlecode.com/svn/trunk@953 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-10-13 08:56:12 +00:00
madmaxoft@gmail.com
4c370798d5 BlockArea writing support (BlockTypes with BlockMeta only)
git-svn-id: http://mc-server.googlecode.com/svn/trunk@933 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-10-06 16:58:31 +00:00
madmaxoft@gmail.com
ea2ed2c918 Moved blockticking into blockhandler classes.
Also slightly refactored the variable / argument names (BlockID is deprecated, use BlockType instead)

git-svn-id: http://mc-server.googlecode.com/svn/trunk@921 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-10-03 08:52:11 +00:00
madmaxoft@gmail.com
0130e73316 Added BLOCK_FACE_NONE into the plugin API
git-svn-id: http://mc-server.googlecode.com/svn/trunk@919 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-10-03 07:23:39 +00:00
madmaxoft@gmail.com
cade71ff68 Fixed Lua bindings for file renaming in previous commits
git-svn-id: http://mc-server.googlecode.com/svn/trunk@889 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-09-23 22:25:33 +00:00
madmaxoft@gmail.com
ecfe6ab65b Source files cleanup: The rest of the files renamed.
git-svn-id: http://mc-server.googlecode.com/svn/trunk@887 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-09-23 22:09:57 +00:00
madmaxoft@gmail.com
7abb5f7604 Source files cleanup: OSSupport-related files in a separate subfolder, renamed.
git-svn-id: http://mc-server.googlecode.com/svn/trunk@885 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-09-23 21:23:33 +00:00
madmaxoft@gmail.com
3953277568 Source files cleanup: Removed unused cBlockToPickup
git-svn-id: http://mc-server.googlecode.com/svn/trunk@884 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-09-23 21:09:13 +00:00
faketruth
6bc916fc3c Added cPlugin_NewLua::GetLocalDirectory() and exported it to Lua so plugins can store their settings in their own folder.
Core now stores banned players and whitelist data in its own directory

git-svn-id: http://mc-server.googlecode.com/svn/trunk@850 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-09-08 20:49:29 +00:00
madmaxoft@gmail.com
8c43857b73 Added the ItemToString() and ItemTypeToString() functions.
Ref.: http://forum.mc-server.org/showthread.php?tid=434&pid=4506#pid4506

git-svn-id: http://mc-server.googlecode.com/svn/trunk@847 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-09-08 16:08:29 +00:00
faketruth
f075bed23c ToLua does not like the override keyword :(
git-svn-id: http://mc-server.googlecode.com/svn/trunk@821 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-09-02 13:54:33 +00:00
faketruth
9db307bb53 Exported cWorld::DoWithChestAt to Lua
Exported cChestEntity to Lua for handling in DoWithChestAt

git-svn-id: http://mc-server.googlecode.com/svn/trunk@820 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-09-02 13:34:59 +00:00
madmaxoft@gmail.com
63bd1976cc Added a Player parameter to OnUpdatedSign and OnUpdatingSign Lua callbacks and to the cWorld:UpdateSign method (http://forum.mc-server.org/showthread.php?tid=464&pid=4393#pid4393)
git-svn-id: http://mc-server.googlecode.com/svn/trunk@814 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-09-01 21:31:20 +00:00
madmaxoft@gmail.com
f1d62b77cd Gotten completely rid of all cPackets. The cProtocol125 class now does all the parsing and writing by itself.
git-svn-id: http://mc-server.googlecode.com/svn/trunk@802 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-08-29 21:02:39 +00:00
madmaxoft@gmail.com
66f4c9e0c0 Cut out all packet handling to a separate cProtocol descendant
git-svn-id: http://mc-server.googlecode.com/svn/trunk@796 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-08-27 17:31:16 +00:00
madmaxoft@gmail.com
7cf9ddaa48 cSocket doesn't use cPackets.
git-svn-id: http://mc-server.googlecode.com/svn/trunk@790 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-08-25 21:59:13 +00:00
madmaxoft@gmail.com
f0fc0edd21 cPickup doesn't use cPackets.
Also, Lua API change, OnCollectItem -> OnCollectPickup; first param is cPlayer to match other callbacks.

git-svn-id: http://mc-server.googlecode.com/svn/trunk@786 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-08-24 09:49:00 +00:00
madmaxoft@gmail.com
e92b9e7ecb Monster classes don't use cPackets. Chat messages are sent / broadcast without cPackets. BlockEntities don't use cPackets.
git-svn-id: http://mc-server.googlecode.com/svn/trunk@783 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-08-24 07:58:26 +00:00
madmaxoft@gmail.com
263ce31bd6 Added plugin name to deprecation messages
Removed duplicate inheritance of m_Name in cPlugin_NewLua by making cWebPlugin interface-only

git-svn-id: http://mc-server.googlecode.com/svn/trunk@782 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-08-23 20:49:21 +00:00
faketruth
7c84349990 WebAdmin should not cause crashes anymore
Got rid of cWebPlugin_Lua
cPlugin_Lua is also a cWebPlugin now, so plugins don't need a separate cWebPlugin object
Changed some stuff to use AString instead of char*

git-svn-id: http://mc-server.googlecode.com/svn/trunk@777 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-08-22 14:22:21 +00:00
madmaxoft@gmail.com
427e582d5f Almost all packets' handling is now rewritten not to use cPacket descendants elsewhere than in cClientHandle.
git-svn-id: http://mc-server.googlecode.com/svn/trunk@761 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-08-19 19:42:32 +00:00
madmaxoft@gmail.com
eb3ed1aec1 Another handful of packets rewritten.
Also changed cItem::m_ItemID into m_ItemType of type short. Easier handling. m_ItemID kept for compatibility reasons (Lua-interface etc.)

git-svn-id: http://mc-server.googlecode.com/svn/trunk@756 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-08-19 11:51:17 +00:00
madmaxoft@gmail.com
1b5eaa92b5 Chat packet handled in the new way; fixed missing packet sending for inventory slot.
Again, API change! cPlugin:OnChat() has had its parameters swapped, to match all the other callbacks - Player first, Message second

git-svn-id: http://mc-server.googlecode.com/svn/trunk@751 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-08-18 10:38:15 +00:00
madmaxoft@gmail.com
2691e8daed Packet refactoring, phase two, partial. Rewritten a few packet handling functions not to use cPacket-descendant objects.
This breaks plugin API! Plugins need to modify their hook functions to match those used in the Core plugin

git-svn-id: http://mc-server.googlecode.com/svn/trunk@750 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-08-18 09:56:28 +00:00
madmaxoft@gmail.com
9e3aadb7d0 Updated Bindings to match the new armor categories and torch metas
git-svn-id: http://mc-server.googlecode.com/svn/trunk@729 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-08-11 19:49:36 +00:00
madmaxoft@gmail.com
6711fcd636 Fixed a crash in creative inventory (FS 235, patch submitted by l0udPL)
git-svn-id: http://mc-server.googlecode.com/svn/trunk@722 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-08-10 19:01:36 +00:00
madmaxoft@gmail.com
2a72c5c838 Fixed a few gcc pedantic warnings; made BLOCKTYPE an unsigned char type.
git-svn-id: http://mc-server.googlecode.com/svn/trunk@711 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-08-03 11:53:11 +00:00