1
0
Commit Graph

103 Commits

Author SHA1 Message Date
madmaxoft@gmail.com
73fb71e164 Crouching will allow block placement on otherwise functional blocks.
Fixes FS #382

git-svn-id: http://mc-server.googlecode.com/svn/trunk@1607 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-06-18 20:15:29 +00:00
madmaxoft@gmail.com
32f28bf1fb Added a crude limiter for explosions sent to client.
Now the client can survive even 3000k TNT blocks exploding without jerking much.

git-svn-id: http://mc-server.googlecode.com/svn/trunk@1606 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-06-18 19:32:31 +00:00
madmaxoft@gmail.com
b2138b132c More TNT fixes.
Chain-reaction TNTs are spawned in proper coordinates (FS #390)
Centralized Primed TNT entity spawning and made available to the plugins.
Internal changes for better TNT performance.

git-svn-id: http://mc-server.googlecode.com/svn/trunk@1604 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-06-18 19:09:51 +00:00
madmaxoft@gmail.com
588d4dc907 Added an elaborative comment on the deadlock prevention code
(FS #375)

git-svn-id: http://mc-server.googlecode.com/svn/trunk@1597 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-06-16 08:51:05 +00:00
madmaxoft@gmail.com
a67760f7c9 First attempt at fixing the inter-threading deadlocks between the tick thread and the socket thread
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1591 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-06-15 15:29:20 +00:00
madmaxoft@gmail.com
3ee5236284 Removed cLadder, cSign, cStairs, cTorch and cVine classes, moved their functionality into the appropriate BlockHandlers / ItemHandlers
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1555 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-06-04 19:22:14 +00:00
madmaxoft@gmail.com
dff77e8e56 Implemented proper player crouching.
Fixes FS #365

git-svn-id: http://mc-server.googlecode.com/svn/trunk@1553 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-06-04 14:18:03 +00:00
madmaxoft@gmail.com
9684f90f83 LuaWindow: Initial code, the window can be opened, but not much manipulated
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1532 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-05-30 19:34:09 +00:00
madmaxoft@gmail.com
9be27992e2 Moved BlockEntities to a separate folder
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1527 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-05-28 19:12:47 +00:00
madmaxoft@gmail.com
cf87169737 Refactored cInventory to use cItemGrid for the actual Storage
This makes the API more orthogonal and is easier to use in the plugins. Also changes in the inventory are now propagated to the needed places (armor updates to BroadcastEntityEquipment etc.) even when the inventory is changed by a plugin.

git-svn-id: http://mc-server.googlecode.com/svn/trunk@1503 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-05-24 07:30:39 +00:00
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
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
9b9a37e507 Fixed Linux compilation, slight code cleanup
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1396 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-04-19 08:21:39 +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
4aed49a70f Fixed personal crafting grid not being tossed on inventory close.
FS #355, http://www.mc-server.org/support/index.php?do=details&task_id=355

git-svn-id: http://mc-server.googlecode.com/svn/trunk@1358 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-04-04 11:47:31 +00:00
keyboard.osh@gmail.com
8f047b0704 Added support for head yaw tracking and packet sending and fixed bug in BroadcastMovementUpdate
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1350 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-04-02 06:48:31 +00:00
keyboard.osh@gmail.com
8557ed8359 Added support for the packet #28 (0x1C): ENTITY_VELOCITY
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1283 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-03-18 02:51:55 +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
71cd0199fd Made FAST_FLOOR_DIV work correctly, replaced all floorf() divisions with it.
Still not perfect - chunk and region calculations can be made into a single CPU instruction - SAR - but not all compilers are known to support that (">>" operator on signed datatypes needs to perform arithmetic shift, C/C++ standard makes it implementation-specific; MSVC and GCC do what we need, LLVM unknown)

git-svn-id: http://mc-server.googlecode.com/svn/trunk@1224 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-02-27 10:01:20 +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
d47ff55203 Minecarts can now be placed.
No interaction, no physics, though.

git-svn-id: http://mc-server.googlecode.com/svn/trunk@1219 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-02-18 16:48:50 +00:00
madmaxoft@gmail.com
48d30dfca2 Fixed one-hit-blocks not being broken server-side
FS #301

git-svn-id: http://mc-server.googlecode.com/svn/trunk@1213 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-02-14 21:47:57 +00:00
luksor111@gmail.com
a10239c415 Added missing dig status.
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1141 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-01-13 12:59:48 +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
2e64b2e5f5 Not sending multiple DC packets to the client.
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1120 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-01-05 19:05:15 +00:00
luksor111@gmail.com
4ce5f215ed Fixed OnBlockPlace hook
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1113 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-12-27 21:08:03 +00:00
madmaxoft@gmail.com
17a2c1b388 Adjusted the protocol framework to support different types of falling block spawning.
In brief, with cProtocol, "say what you want done, not how you want me to do it".
But still 1.4.6 crashes on falling block spawning.

git-svn-id: http://mc-server.googlecode.com/svn/trunk@1104 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-12-26 09:12:00 +00:00
madmaxoft@gmail.com
b4ac9d702b Added the 1.4.6 protocol
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1099 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-12-24 22:09:01 +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
luksor111@gmail.com
e176745781 Removed chat messages from console
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1082 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-12-20 06:46:15 +00:00
luksor111@gmail.com
05d71675f6 Added dispensers (they can't dispense items yet)
Fixed crash when digging snow
Moved BlockPlace hook check, so Core plugin will no longer block item usage
Player chat messages are now visible in the console

git-svn-id: http://mc-server.googlecode.com/svn/trunk@1081 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-12-19 21:19:36 +00:00
madmaxoft@gmail.com
65bc09f8e8 Fixed wrong c++ standard assumptions about bools.
Should fix FS #265.
http://forum.mc-server.org/showthread.php?tid=629&pid=5415#pid5415

git-svn-id: http://mc-server.googlecode.com/svn/trunk@1053 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-11-18 21:50:05 +00:00
madmaxoft@gmail.com
b65a22fc1f Fixed boolean comparison.
Don't compare booleans to false / true, use them directly.

git-svn-id: http://mc-server.googlecode.com/svn/trunk@1048 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-11-16 16:03:56 +00:00
madmaxoft@gmail.com
052abcabc7 Removed log message when spawning players on a client.
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1047 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-11-16 15:56:41 +00:00
luksor111@gmail.com
f32091f98c Fixed block breaking in survival.
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1038 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-11-12 11:10:01 +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
luksor111@gmail.com
9855316494 You can now see particles and hear sounds when other players are destroying blocks.
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1004 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-10-22 20:45:56 +00:00
madmaxoft@gmail.com
3f9e876d70 Added jukeboxes (patch contributed by Luksor)
git-svn-id: http://mc-server.googlecode.com/svn/trunk@994 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-10-21 07:46:28 +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
dc7f91c2a1 Fixed a vulnerability in cClientHandle::HandleRespawn()
Changed some hook locations:
Moved HOOK_PLAYER_JOIN to where HOOK_PLAYER_SPAWN was (before player is added to the world)
Added HOOK_PLAYER_SPAWN to after a player's initial spawn and after a player is re-spawned after death

git-svn-id: http://mc-server.googlecode.com/svn/trunk@972 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-10-17 12:19:20 +00:00
faketruth
ae5975e674 Added an option to disable/enable PVP on a per world basis
git-svn-id: http://mc-server.googlecode.com/svn/trunk@944 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-10-10 19:46:12 +00:00
madmaxoft@gmail.com
4f34704ce8 Fixed an invalid direction to AddDirection()
( http://forum.mc-server.org/showthread.php?tid=571&pid=4821#pid4821 )

git-svn-id: http://mc-server.googlecode.com/svn/trunk@939 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-10-06 20:53:08 +00:00
madmaxoft@gmail.com
28332c6567 Completely removed the old (buggy) redstone simulator.
git-svn-id: http://mc-server.googlecode.com/svn/trunk@937 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-10-06 20:04:58 +00:00
madmaxoft@gmail.com
85164fab8e Slight refactoring of BlockHandlers - dropping unneeded virtual functions
( http://forum.mc-server.org/showthread.php?tid=434&pid=4734#pid4734 )

git-svn-id: http://mc-server.googlecode.com/svn/trunk@917 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-10-01 21:08:15 +00:00
faketruth
ba2a9b6b2c Added falling block entities. Sand and gravel now properly fall down
Implemented the PACKET_SPAWN_OBJECT packet
Made some things use BLOCKTYPE instead of char

Android: Requests WebAdmin port when pressing the configure button


git-svn-id: http://mc-server.googlecode.com/svn/trunk@915 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-09-30 16:37:44 +00:00
madmaxoft@gmail.com
325904470c Removed a rogue cSleep from ClientHandle. Since sockets are owned by sockethreads, the client can safely Destroy() itself right after sending a packet.
git-svn-id: http://mc-server.googlecode.com/svn/trunk@912 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-09-29 21:03:38 +00:00
faketruth
17486c7853 Beds can be slept in now (it doesn't change the time though)
git-svn-id: http://mc-server.googlecode.com/svn/trunk@911 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-09-29 20:43:42 +00:00
madmaxoft@gmail.com
4df23d19b7 Unified folder name-casing
git-svn-id: http://mc-server.googlecode.com/svn/trunk@902 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-09-29 13:59:32 +00:00
madmaxoft@gmail.com
fb9a00a64e Added the block dig animation packet (patch contributed by l0udPL)
git-svn-id: http://mc-server.googlecode.com/svn/trunk@892 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-09-25 09:54:36 +00:00
madmaxoft@gmail.com
7a43f6be09 Sockets are now owned by SocketThreads instead of ClientHandle (FS #246 and FS #247)
git-svn-id: http://mc-server.googlecode.com/svn/trunk@891 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-09-25 08:23:19 +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