880 Commits

Author SHA1 Message Date
Quentin Bazin
86125bf13e [furnace.lua] Won't use non-fuel items as fuel anymore. 2020-03-01 18:04:50 +01:00
Quentin Bazin
1c21f89caa [MouseItemWidget] Refactored a little bit. 2020-03-01 17:52:35 +01:00
Quentin Bazin
578b5271ac Lots of fixes related to drag-click. 2020-03-01 17:44:53 +01:00
Quentin Bazin
0c71255938 [MouseItemWidget] Now supports drag-click. 2020-03-01 15:45:09 +01:00
Quentin Bazin
908bb10b9b [AbstractInventoryWidget] Now supports multiple destinations. 2020-03-01 12:55:20 +01:00
Quentin Bazin
c092e53116 [Inventory] Now supports using 'addStack' on a subset. 2020-03-01 12:28:26 +01:00
Quentin Bazin
4d9a2fbe7e [LuaGUIState] Now handles Shift+Left click to move items quickly. 2020-03-01 00:15:49 +01:00
Quentin Bazin
7ce30d3e5b [SettingsMenuState] Added menu option to change creative window key. 2020-02-29 18:11:09 +01:00
Quentin Bazin
45c797cd5f Creative window added on key 'H'. 2020-02-29 18:07:01 +01:00
Nikola Schrodinger
5d7e5158e8 Added new items 2020-02-29 11:31:28 +01:00
Quentin Bazin
319101c94c [TerrainGenerator] Fixed single block holes. 2020-02-29 03:59:39 +01:00
Quentin Bazin
502a4b542d include and source folders merged. 2020-02-29 03:31:14 +01:00
Pedro Gimeno
3ad0b19de4 Add UVs and a texture for Boxy
Thanks to LyoliGamer for providing this texture (CC0)
http://minetest.fensta.bplaced.net/#name=Lyoligamer
2020-02-29 03:04:35 +01:00
Nikola Schrodinger
0263387e35 Added iron ore generation. 2020-02-29 02:01:07 +01:00
Pedro Gimeno
03732e7566 Add joke player "model"
Turns on backface culling too.
2020-02-28 16:54:58 +01:00
Pedro Gimeno
f39229fc30 Lock player when in an unloaded chunk 2020-02-28 16:34:31 +01:00
Pedro Gimeno
1af45d68c4 Use a local position variable for the camera
This makes it easier to change the camera position if necessary.
2020-02-28 16:34:31 +01:00
Pedro Gimeno
6483c5c846 Simplify updatePosition (remove duplicated code) 2020-02-28 16:34:31 +01:00
Pedro Gimeno
56c60d02f8 Make the player be a basic model, with the correct position
This fixes the visualization of other players mentioned in the last commit.
2020-02-28 16:22:00 +01:00
Pedro Gimeno
89a1520d7c Change player position to be at the feet, rather than the head
Note: This breaks the visualization of the other players (PlayerBox).
2020-02-26 22:17:37 +01:00
Quentin Bazin
101df11c14 [textures_mc] Replaced some textures added by #66 by original ones. 2020-02-26 15:20:45 +09:00
Quentin Bazin
a9426a9daa [textures] Fixed permissions for Faithful 32x textures. 2020-02-26 03:17:35 +09:00
Quentin Bazin
b0ab30c3c6 [Notes] Example for biome definition added. 2020-02-26 03:16:32 +09:00
Nikola Schrodinger
4f1a9e87d4 Added new blocks and fixed minor bug with LuaMods. 2020-02-26 03:14:48 +09:00
Quentin Bazin
e405173b7b [PlayerBox] Now using gk::Transformable again. 2020-02-25 23:27:44 +09:00
Quentin Bazin
14bfabee0d [GameState|InterfaceState] Now closing the game correctly on SDL_QUIT event. 2020-02-25 22:13:06 +09:00
Quentin Bazin
fabefd81b4 [PlayerBox] Position fixed. It was needed because of precision PR. 2020-02-25 18:51:00 +09:00
Quentin Bazin
27fb5e935a [InterfaceState] Now updates parent. This fixes a problem where client froze the game when in pause menu or chat. 2020-02-25 10:03:56 +09:00
Quentin Bazin
7a28b8bf49 [LuaGUIState] Small refactorization. 2020-02-25 09:51:38 +09:00
Quentin Bazin
1d4fe0a11e [TextureAtlas] Now displaying 'undefined' texture for blocks with wrong texture definition. 2020-02-25 09:38:06 +09:00
Quentin Bazin
bcc3f65147 Headers updated and CONTRIBUTORS file added. 2020-02-25 01:48:38 +09:00
Pedro Gimeno
ead6df00f6 Revert to negative angle, as it's causing issues
Look into that later.
2020-02-24 17:06:27 +01:00
Pedro Gimeno
4f37012931 Camera improvements
- Remove the degenerate case of vertical directions, by updating the viewup as the camera moves.
- Remove the consequent limitation to 89.9 degrees.
- Add (unused so far) camera roll angle, with setter.
- Add accessors for all angles. Lua will want to know that.
- Rename m_angleV/H to m_viewAngleV/H to distinguish them clearly from the orientation of the mesh. They will differ e.g. when the player is sitting somewhere.
- Rename vertical turn so it includes 'view' in the name, because this one does not affect the player's rotation as turnH does.
- Make player look north at start, like it originally did before the Z-up changes.
2020-02-24 17:06:27 +01:00
Quentin Bazin
4fc45e3d93 [GameState] The game will now be paused it the window lose the focus. 2020-02-24 23:23:27 +09:00
Quentin Bazin
7e38907854 [SettingsMenuState] It's now possible to disable VSync. 2020-02-24 23:16:51 +09:00
Quentin Bazin
7c9b72b137 [Config|SettingsMenuState] Added option to disable BlockInfoWidget. 2020-02-24 22:43:31 +09:00
Pedro Gimeno
6e506d8500 Precision improvements (Part 5)
Get rid of floats when calculating chunk position from block position. This can be done in integers. Since CHUNK_WIDTH etc. are guaranteed to be powers of two, using & -N is equivalent to doing & ~(N-1), or put differently, making it divisible by N. That makes the division exact, and allows the compiler to transform it into a plain shift (tested with both gcc and clang).

We did the same in Part 3 of this series.
2020-02-24 12:00:02 +01:00
Pedro Gimeno
d4daaa6355 Precision improvements (Part 4)
Fix world generator (to some extent).
2020-02-24 12:00:02 +01:00
Pedro Gimeno
33dca07ee0 Precision improvements (Part 3)
Fix debug overlay.
2020-02-24 12:00:02 +01:00
Pedro Gimeno
6e3c2e066f Precision improvements (Part 2)
Improve player precision, especially location, but also rotation.
2020-02-24 11:59:53 +01:00
Pedro Gimeno
4bb12c872f Precision improvements (Part 1)
Improve rendering precision by subtracting the camera position from the models' position, then temporarily setting the camera to (0, 0, 0) for rendering. This keeps GL coordinates in a low range.
2020-02-24 11:16:19 +01:00
Pedro Gimeno
af1a641a25 Fix calculation of centre position relative to the camera
While this fixes the calculation, it introduces visibility determination problems, because the method was not correct. The centre may be out of the area of the camera, with nodes still visible inside. To fix this, the eight corners of the chunk need to be considered.
2020-02-24 11:16:19 +01:00
Quentin Bazin
75f9bc6dbd [ClientWorld] Teleportation and fast movement won't stop the world from loading. Fixes #50. 2020-02-24 18:53:21 +09:00
Pedro Gimeno
040c8d5d07 Fix waving vertex shader
It's everything commented out so it technically works, but this way it's ready for the time when it's enabled again.
2020-02-24 10:38:08 +01:00
Pedro Gimeno
22ecc2fa8d Fix 'escape from inside node' after Y/Z swap
Missed the case of getting rid of the box at the southwest.

We take the chance for making it more robust by checking all four corners, just in case there's a platform with trouble in an edge case.
2020-02-24 10:38:08 +01:00
Pedro Gimeno
8c5ab63061 Change server-side player position to match the client-side one 2020-02-24 10:38:08 +01:00
Quentin Bazin
47d57f7fc3 [ServerCommandHandler] Now deletes ServerPlayer instance on disconnection. 2020-02-24 17:20:49 +09:00
Quentin Bazin
879dc28eb2 [FurnaceWidget] Removed. Now completely implemented in Lua. 2020-02-23 22:38:51 +09:00
Quentin Bazin
4eb3e3738f [ProgressBarWidget] Added. 2020-02-23 20:42:32 +09:00
Quentin Bazin
47b7e3d849 [PlayerCraftingWidget] Removed, implemented completely using Lua. 2020-02-23 18:24:19 +09:00