26 Commits

Author SHA1 Message Date
Pedro Gimeno
ae9b47e018 Allow the player to dig the node the camera is into
That allows them to escape from being unable to move due to being trapped with the camera inside a node (assuming the node is diggable).

Note: The implementation is a bit of a hack. It doesn't consider the lookAt direction.
2020-02-18 14:57:27 +09:00
Quentin Bazin
d47d5d39e4 [BlockCursor] 'selectedBlock' now uses 'glm::ivec4' instead of 'glm::vec4'. 2020-02-17 19:03:36 +09:00
Quentin Bazin
2c5f289ef1 [Block|Item] 'name' property renamed to 'stringID' for more coherency. 2020-02-17 15:54:19 +09:00
Quentin Bazin
bb5819e5ee [BlockCursor] No longer possible to replace blocks. 2020-02-17 15:22:12 +09:00
Quentin Bazin
494f56fae9 [BlockCursorRaycast] Added for raycast functions. 2020-02-17 15:02:01 +09:00
Quentin Bazin
a02c493fcf [BlockCursor] Minor style fix. Depth buffer-based algorithm removed. 2020-02-17 14:44:59 +09:00
Pedro Gimeno
b0d29988ec Replace the ray tracer with a more precise and complete one
Bounding boxes that are smaller than the node (e.g. flowers) are handled. In future it shouldn't be hard to add handling of multiple selection boxes per node.

Fixes #33.
2020-02-16 20:39:46 +01:00
Quentin Bazin
93cd68ffe9 [Config] Moved to client. SCREEN_WIDTH, SCREEN_HEIGHT and GUI_SCALE renamed. [EngineConfig] Added for common config. 2020-02-15 22:48:56 +09:00
Quentin Bazin
56338f1f79 [BlockCursor] Small fix. 2020-02-15 21:47:35 +09:00
Quentin Bazin
b7bb8f1d52 Replaced my custom headers by LGPL license headers. 2020-02-08 18:34:26 +09:00
Quentin Bazin
4cae1b9c50 [BlockCursor] It is now required to press Sneak key to place a block on a workbench/furnace without activating their GUI. 2020-02-08 01:30:39 +09:00
Quentin Bazin
3a5c315f9a [Block|BlockCursor] No longer dependent on BlockType. 2020-02-07 23:17:21 +09:00
Quentin Bazin
7c05f319ba [LuaMod] Added support for bounding box definition. 2020-02-03 11:13:23 +09:00
Quentin Bazin
54493e3d58 [BlockCursor] Now reset breaking timer when switching item or activating a block. Thanks to obiwac who found these issues. 2020-01-27 12:43:16 +09:00
Quentin Bazin
f56002f85a [ClientCommandHandler] Now used to send commands to the server. 2019-04-08 12:59:02 +02:00
Quentin Bazin
633233e57e [BlockCursor] Fixed inventory update packet. [Client] Small optimization. 2019-04-07 16:09:14 +02:00
Quentin Bazin
da5f042354 [OpenGL] Now using glCheck() from GameKit. 2019-02-27 02:18:14 +01:00
Quentin Bazin
6b986b7de5 [Registry] Small fix. 2019-01-26 12:37:34 +01:00
Quentin Bazin
44c1f6251d [BlockCursor] Now sending updated inventory to server after placing a block. 2019-01-23 21:45:19 +01:00
Quentin Bazin
2035f9123f [Block] onTick and onBlockActivated re-enabled. 2019-01-23 00:38:08 +01:00
Quentin Bazin
e2816324a8 [Player] Server now keep track of the inventory. 2019-01-23 00:04:03 +01:00
Quentin Bazin
29c518631b [.travis.yml] Added. 2019-01-20 15:07:45 +01:00
Quentin Bazin
ec2a27b587 [BlockCursor] Now implements PlayerDigBlock network event. 2019-01-20 15:07:45 +01:00
Quentin Bazin
03bffbb666 [Network] Server is now aware of placed blocks and can forward the info to other clients. 2019-01-20 15:07:45 +01:00
Quentin Bazin
f374c7ba80 [HUD] All the widgets works now. 2019-01-20 15:07:45 +01:00
Quentin Bazin
ca90070905 [graphics|hud] Moved to client. 2019-01-20 15:07:45 +01:00