1
0
Commit Graph

114 Commits

Author SHA1 Message Date
madmaxoft@gmail.com
674fe1e955 Window, Chest, Furnace and Pawn are not using cPackets at all
git-svn-id: http://mc-server.googlecode.com/svn/trunk@762 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-08-19 21:14:45 +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
ab860e6573 Slight cChunk optimization
git-svn-id: http://mc-server.googlecode.com/svn/trunk@688 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-07-21 14:47:44 +00:00
lapayo94@gmail.com
14dce23845 A new Block handling system :o
It was really a lot of work :D
Took me the complete weekend :D

Would really like to here your opinion on this =)
The aim of this is to put all the actions for one block in one place so it is not spread around the source. (ToPickup, Action in cWorld, Action in cChunk, Action here, action there :D)

git-svn-id: http://mc-server.googlecode.com/svn/trunk@671 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-07-15 20:36:34 +00:00
madmaxoft@gmail.com
6cf4772b54 Leaves blocks allowed one more block of distance from a log block before they decay
git-svn-id: http://mc-server.googlecode.com/svn/trunk@666 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-07-15 13:34:53 +00:00
lapayo94@gmail.com
4b62d1c463 BlockArea name change reverted
fixed VS2008 building

git-svn-id: http://mc-server.googlecode.com/svn/trunk@649 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-07-09 07:00:28 +00:00
lapayo94@gmail.com
083228a10d Squirrel Plugins
I worked a little bit on the squirrel Bindings
They work now on linux and windows :) (OSX is untested, but should work also) but they are very limited at the moment. (Only made OnChat working)
I also fixed some small bugs.


git-svn-id: http://mc-server.googlecode.com/svn/trunk@648 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-07-08 21:01:08 +00:00
madmaxoft@gmail.com
a627a3a261 Leaves decay adjusted to 4 blocks in between the leaves and the log, instead of previous 3
git-svn-id: http://mc-server.googlecode.com/svn/trunk@645 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-07-02 19:51:31 +00:00
madmaxoft@gmail.com
919f896894 Leaves decay properly - if they are not connected to a log
git-svn-id: http://mc-server.googlecode.com/svn/trunk@644 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-07-02 19:22:05 +00:00
madmaxoft@gmail.com
602c2ec1b1 Made ForEach API safer to use, now supports Destroy()-ing objects, too ( http://forum.mc-server.org/showthread.php?tid=434&pid=3513#pid3513 )
git-svn-id: http://mc-server.googlecode.com/svn/trunk@633 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-06-19 20:31:21 +00:00
cedeel@gmail.com
beaf37a013 Crops aren't uprooted if farmland is dry.
Vanilla behavior confirmed.

git-svn-id: http://mc-server.googlecode.com/svn/trunk@630 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-06-18 16:25:57 +00:00
madmaxoft@gmail.com
e5fdc133bc Removed the deprecated GetBlockEntity(), added several enumerators to replace it.
git-svn-id: http://mc-server.googlecode.com/svn/trunk@629 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-06-17 19:58:39 +00:00
madmaxoft@gmail.com
d7669c6709 Fixed leaves blockticking - must touch neighboring chunks, too, instead of self at wrong places.
git-svn-id: http://mc-server.googlecode.com/svn/trunk@626 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-06-17 05:34:37 +00:00
cedeel@gmail.com
861fa61dfc Leaves: Applied patch by Luksor.
git-svn-id: http://mc-server.googlecode.com/svn/trunk@624 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-06-16 18:12:43 +00:00
madmaxoft@gmail.com
ada984facf Exported cWorld::ForEachEntity and cWorld::ForEachEntityInChunk; no idea if they actually work
git-svn-id: http://mc-server.googlecode.com/svn/trunk@620 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-06-16 08:35:07 +00:00
cedeel@gmail.com
92c59963f8 Attempt to bring sanity to newlines across systems.
git-svn-id: http://mc-server.googlecode.com/svn/trunk@606 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-06-14 13:06:06 +00:00
madmaxoft@gmail.com
e0f74160ea Snow cover breaks when the block below it is removed (FS #184).
git-svn-id: http://mc-server.googlecode.com/svn/trunk@591 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-06-09 16:27:42 +00:00
madmaxoft@gmail.com
8189487258 Sugarcane and cactus max height can be set in world.ini.
git-svn-id: http://mc-server.googlecode.com/svn/trunk@585 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-06-09 13:00:14 +00:00
madmaxoft@gmail.com
ec61713221 Cacti grow by themselves and by bonemeal
git-svn-id: http://mc-server.googlecode.com/svn/trunk@583 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-06-09 12:03:49 +00:00
madmaxoft@gmail.com
6d36a82e19 Sugarcane grows and can be grown using bonemeal.
git-svn-id: http://mc-server.googlecode.com/svn/trunk@578 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-06-08 14:17:33 +00:00
madmaxoft@gmail.com
876014b8e8 Bonemeal works on crops, melons, pumpkins, saplings and grass. Plant growing has been refactored into separate functions callable from Lua, too.
git-svn-id: http://mc-server.googlecode.com/svn/trunk@573 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-06-07 21:07:21 +00:00
madmaxoft@gmail.com
73a30d302b BlockChecking split into a separate function
git-svn-id: http://mc-server.googlecode.com/svn/trunk@571 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-06-07 19:06:27 +00:00
madmaxoft@gmail.com
c0a73ef89d Repeaters' delays can be set by rclk
git-svn-id: http://mc-server.googlecode.com/svn/trunk@570 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-06-07 11:57:51 +00:00
madmaxoft@gmail.com
508d5d6e12 Fixed a typo in grass spreading causing much of the "too many packets" error.
git-svn-id: http://mc-server.googlecode.com/svn/trunk@567 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-06-07 09:46:00 +00:00
madmaxoft@gmail.com
36650da187 Grass spreads to adjacent dirt blocks. Doesn't check dest light yet.
git-svn-id: http://mc-server.googlecode.com/svn/trunk@563 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-06-06 20:54:58 +00:00
madmaxoft@gmail.com
1cca9b13b3 Item-dropping code rewritten and centralized - now there's only one place to modify if we want to split or merge same-item drops: cWorld:SpawnItemPickups(). Also, mined blocks can now drop more items, and they recognize if they're being mined by the correct tool.
git-svn-id: http://mc-server.googlecode.com/svn/trunk@561 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-06-06 20:18:50 +00:00
madmaxoft@gmail.com
43c9546203 Fixed a nasty int overflow bug in blockticking code ( http://forum.mc-server.org/showthread.php?tid=457 )
git-svn-id: http://mc-server.googlecode.com/svn/trunk@533 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-06-01 06:25:30 +00:00
madmaxoft@gmail.com
85cf908260 Fixed melons and pumpkins generating in a wrong place.
git-svn-id: http://mc-server.googlecode.com/svn/trunk@530 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-05-31 16:46:05 +00:00
madmaxoft@gmail.com
7af3df03a0 Added support for SetNextBlockTick() function callable from Lua
git-svn-id: http://mc-server.googlecode.com/svn/trunk@527 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-05-30 21:29:51 +00:00
madmaxoft@gmail.com
3d031490be Melon and pumpkin stems now grow melons and pumpkins
git-svn-id: http://mc-server.googlecode.com/svn/trunk@526 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-05-30 20:31:31 +00:00
madmaxoft@gmail.com
403c99f8fa Fixed blocktick distribution
git-svn-id: http://mc-server.googlecode.com/svn/trunk@525 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-05-30 19:35:57 +00:00
madmaxoft@gmail.com
ceffb64760 Farmland gets hydrated and dehydrated. Fixed an off-by-one error in neighbor-chunk manipulation.
git-svn-id: http://mc-server.googlecode.com/svn/trunk@522 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-05-30 15:40:53 +00:00
madmaxoft@gmail.com
bb44d25d60 Fixed a crash when chunks were loaded / generated with entities ( http://forum.mc-server.org/showthread.php?tid=450 )
git-svn-id: http://mc-server.googlecode.com/svn/trunk@521 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-05-30 13:11:58 +00:00
madmaxoft@gmail.com
9d6a5b9ce0 Added code for the chunks to manipulate their neighbors while ticking. Also added some basic farming support - melon and pumpkin growing code. Untested and untestable so far, will test and fix later.
git-svn-id: http://mc-server.googlecode.com/svn/trunk@518 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-05-29 14:59:43 +00:00
madmaxoft@gmail.com
1a0bfd8d28 Chests and Furnaces are now saved properly into Anvil scheme.
git-svn-id: http://mc-server.googlecode.com/svn/trunk@516 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-05-28 16:47:57 +00:00
madmaxoft@gmail.com
a4a418a679 Merged the composable_generator branch into the trunk
git-svn-id: http://mc-server.googlecode.com/svn/trunk@504 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-05-25 07:18:52 +00:00
madmaxoft@gmail.com
05a1f89286 Fixed two "bottlenecks" found using profiling - MakeIndex() instead of MakeIndexNoCheck()
git-svn-id: http://mc-server.googlecode.com/svn/trunk@483 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-05-08 09:25:15 +00:00
madmaxoft@gmail.com
c51a4b9469 Added the "/regeneratechunk" command that regenerates either current chunk or a chunk specified with x, z parameters. TODO: permissions - we don't want guests erasing our chunks!
git-svn-id: http://mc-server.googlecode.com/svn/trunk@454 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-04-10 11:22:11 +00:00
madmaxoft@gmail.com
e1ef489e08 Removed the split between 1.2.3 and 1.1, left only 1.2.3 code
git-svn-id: http://mc-server.googlecode.com/svn/trunk@429 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-03-24 11:40:29 +00:00
madmaxoft@gmail.com
389062a1ed Fixed a deadlock by removing clients from all chunks upon their exit, not using the clients chunklists.
git-svn-id: http://mc-server.googlecode.com/svn/trunk@426 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-03-22 15:53:40 +00:00
madmaxoft@gmail.com
b974b1ea59 Unified the chunk data to use the BLOCKDATA datatype.
git-svn-id: http://mc-server.googlecode.com/svn/trunk@413 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-03-14 21:21:03 +00:00
madmaxoft@gmail.com
0b24efeb00 Split chunk data into separate arrays; decoupled most sources from cChunk.h dependency
git-svn-id: http://mc-server.googlecode.com/svn/trunk@411 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-03-14 20:56:09 +00:00
madmaxoft@gmail.com
e7731242c1 Using references instead of pointers for sending packets
git-svn-id: http://mc-server.googlecode.com/svn/trunk@394 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-03-10 21:34:47 +00:00
madmaxoft@gmail.com
732b7349fa Fixed mob spawn packet for 1.2 client, now client doesn't bail out when mobs are turned on
git-svn-id: http://mc-server.googlecode.com/svn/trunk@393 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-03-10 19:30:06 +00:00
faketruth
e5b91a8d97 Was using "#else if" which is not valid apparently, now using "#elif"
git-svn-id: http://mc-server.googlecode.com/svn/trunk@391 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-03-10 13:49:40 +00:00
faketruth
68f3ea56bd You can change axis ordering by setting AXIS_ORDER to AXIS_ORDER_XZY in cChunk.h !THIS WILL SCREW UP YOUR WORLDS THOUGH!
Still need to update world storage schemes, converters and such

git-svn-id: http://mc-server.googlecode.com/svn/trunk@390 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-03-10 02:39:36 +00:00
faketruth
62ba8f5a20 Using more of the index functions in cChunk, so it should be easy enough to flip the axis ordering now
Added some more functions that use Vector3i for block coordinates in cChunk

git-svn-id: http://mc-server.googlecode.com/svn/trunk@389 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-03-10 00:25:05 +00:00
faketruth
f43b65cf53 cClientHandles have a unique ID now to distinguish them
cAuthenticator uses unique client ID for authentication
Changed the kick function used by cAuthenticator to take a client ID instead of name, so the correct user is kicked
Using callback reference instead of pointer in GetChunkData and affiliates
GetChunkData returns false when failed, and true when succeeded
Renamed entity type enums to something prettier
Exposed some functions to Lua

git-svn-id: http://mc-server.googlecode.com/svn/trunk@388 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-03-09 13:42:28 +00:00
madmaxoft@gmail.com
4d65ffffc0 ChunkSender: Chunks are now compressed and sent to clients from a separate threads, proper passive waiting between threads. Not much tested, just appears to work :)
git-svn-id: http://mc-server.googlecode.com/svn/trunk@365 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-03-05 16:41:57 +00:00