Commit Graph

6529 Commits

Author SHA1 Message Date
Loïc Blot
c1b3ed4180 Player attrs: permits to remove an attribute by setting value to nil (#5716)
* Player attrs: permits to remove an attribute by setting value to nil

When doing player:set_attribute("attr", nil) remove attribute

Also remove a useless check on C++ API part (already done by checkplayer)

Fix #5709
2017-05-07 12:13:15 +02:00
Loic Blot
0d7c37943b
LINT fix since d0678948165768472fc940c03e78cba787f49ea5 2017-05-07 11:07:17 +02:00
paramat
2d5bd7f414 Player properties: Set correct default collisionbox
Recent commit b6f4a9c7e1a4f0bac66fd6f6ff844425ac775975 removed a hardcoded
player collisionbox which resulted on falling back to an incorrect default.
This stopped players walking through 2-node high spaces and made the player
slightly wider.

Improve docs for custom player collisionbox feature and reformat nearby lines.
2017-05-07 06:10:13 +01:00
T0ny2
d067894816 Replace occurrence of luaL_reg in l_camera.cpp
Related to commit 41c5483. Replace an occurrence of luaL_reg in
src/script/lua_api/l_camera.cpp (added by commit de028fc).
2017-05-07 06:09:30 +01:00
ShadowNinja
c6e96c645b Fix myfloor(0.0) 2017-05-06 16:10:03 -04:00
ShadowNinja
77597c4ff3 Clean up numeric.h and split FacePositionCache from it
I also optiized FacePositionCache a bit: I removed a map
lookup and vector copy from both branches of getFacePosition.
2017-05-06 16:09:45 -04:00
TeTpaAka
b6f4a9c7e1 Make the player collisionbox settable 2017-05-06 15:41:05 -04:00
ShadowNinja
43d1f375d1 Use a settings object for the main settings
This unifies the settings APIs.

This also unifies the sync and async registration APIs, since the async
registration API did not support adding non-functions to the API table.
2017-05-06 15:33:19 -04:00
Loic Blot
a024042bf5
Fix codestyle since CSM Camera API 2017-05-06 21:30:27 +02:00
Wuzzy
07c17db114 Add configurable key bindings for hotbar scrolling, and for changing volume. 2017-05-06 21:21:59 +02:00
Sapier
45ab62d6a3 Use stepheight from CAO instead of hardcoded value 2017-05-06 21:18:17 +02:00
red-001
5ebf8f9450 [CSM] add on_item_use (#5544) 2017-05-06 21:12:44 +02:00
TeTpaAka
6658ad3d94 Make players respect makes_footstep_sound in the object properties 2017-05-06 20:16:16 +02:00
bigfoot547
de028fc056 [CSM] Add camera API (#5609)
* [CSM] Add camera API
roper rebase & squash

* Address nerzhul's review
2017-05-05 22:07:36 +02:00
Paramat
e8b00fdf98 Clouds API: Fix yellow clouds at dawn and dusk (#5707) 2017-05-05 22:07:25 +02:00
Loic Blot
7c82f1e5dd
Add missing server sending rule for bd921a7916f0fafc493b1c4d0eeb5e2bb1d6a7c2 2017-05-05 20:21:04 +02:00
Wayward One
fe247f38f7 Fix Android build (#5706)
* Fix Android build
2017-05-05 17:27:50 +02:00
Loïc Blot
21e0a049f8 Save minetest screen width/height options when modified (#5683)
* Save minetest screen width/height options when modified

* Add autosave_screensize setting (default true)

* Fix @SmallJoker comments
2017-05-05 13:47:11 +02:00
red-001
d6cf5450a8 Add option to also check the center to find_node_near (#5255)
* Add option to also check the center to `find_node_near`
2017-05-04 22:52:58 +02:00
yellowcrash10
6fb27d3b2e Translated using Weblate (Esperanto)
Currently translated at 31.9% (293 of 918 strings)
2017-05-04 17:14:24 +02:00
Michele Mainardi
e2199874a4 Translated using Weblate (Italian)
Currently translated at 96.0% (882 of 918 strings)
2017-05-04 17:14:02 +02:00
Mário
b71ed1a957 Translated using Weblate (Portuguese)
Currently translated at 66.9% (615 of 918 strings)
2017-05-04 17:13:50 +02:00
Viktar Vauchkevich
87b6458abc Translated using Weblate (Belarusian)
Currently translated at 100.0% (918 of 918 strings)
2017-05-04 17:13:30 +02:00
David Capello
f441e0d76e Translated using Weblate (Spanish)
Currently translated at 58.0% (533 of 918 strings)
2017-05-04 17:11:37 +02:00
Laura Arjona Reina
4cf0bf8ff4 Translated using Weblate (Spanish)
Currently translated at 57.9% (532 of 918 strings)
2017-05-04 17:11:25 +02:00
metarmask
733b49b17f Added translation using Weblate (Swedish) 2017-05-04 17:09:47 +02:00
BreadW
41e9074c7d Translated using Weblate (Japanese)
Currently translated at 49.6% (456 of 918 strings)
2017-05-04 17:08:49 +02:00
monolifed
1b3ea47e99 Translated using Weblate (Japanese)
Currently translated at 49.4% (454 of 918 strings)
2017-05-04 17:08:32 +02:00
Andrey K
b8993ee5ac Translated using Weblate (Russian)
Currently translated at 60.1% (552 of 918 strings)
2017-05-04 17:07:57 +02:00
monolifed
194df438c2 Translated using Weblate (Turkish)
Currently translated at 93.6% (860 of 918 strings)
2017-05-04 17:07:36 +02:00
Muhammad Nur Hidayat Yasuyoshi
1a9cd99056 Translated using Weblate (Malay)
Currently translated at 54.9% (504 of 918 strings)
2017-05-04 17:07:36 +02:00
Vaughan Lapsley
c874bfa5c3 Remove CMAKE -ffast-math flag from OSX/FreeBSD
Fixes issue: #4274

I have tested on MacOS 10.12.4

Requires testing on:
FreeBSD, Windows and Linux which I do not have access to.
2017-05-04 13:24:36 +02:00
Loic Blot
9a9ae7d65c
LINT fix since cloud API merge 2017-05-04 07:52:31 +02:00
paramat
dd591119a3 Directional coloured fog: Fix order of SColor components
'video::SColor pointcolor' was initialised with order RGBA instead of ARGB.
No change in behaviour as 'm_bgcolor' has alpha 255.
2017-05-04 04:26:06 +01:00
paramat
76ec6b8313 Clouds: Fix reddish clouds. Add missing alpha update
Fix accidental swap of red and blue components that caused reddish clouds
Add missing update of alpha in remoteplayer.cpp
2017-05-04 04:26:06 +01:00
red-001
ae0d8f74d7 Add function to get server info. 2017-05-04 04:25:45 +01:00
SmallJoker
468eeb618e Fading soungs: Fix client crash on older servers 2017-05-03 13:48:46 +02:00
paramat
ad9fcf859e Set sky API: Add bool for clouds in front of custom skybox
Default true.
Add 'm_clouds_enabled' bool to sky.h, set from new bool in 'set sky' API.
Make 'getCloudsVisible()' depend on 'm_clouds_enabled' instead of
'm_visible' (whether normal sky is visible).
2017-05-02 20:42:35 -07:00
SmallJoker
f9fdb48dc8 Sneak: Improve and fix various things
Remove useless `got_teleported`.
Fix jitter when walking against the sneak limits.
Fix damage evading on sneak ladders.
2017-05-03 03:16:20 +01:00
Brandon
bd921a7916 Sound API: Add fading sounds 2017-05-03 03:12:45 +01:00
Ben Deutsch
f1d7a26b7c Add clouds API 2017-04-30 00:06:13 +01:00
Loïc Blot
95409da87d Optimize updateFastFaceRow processing by removing some TileSpec copy (#5678)
* Optimize updateFastFaceRow processing by removing some TileSpec copy

It permit to decrease this function from 54% runtime to 45% and reduce copy from 14% runtime to 12.5%
getTileInfo also reduced from 27% to 23%

* makeFastFace should use a const ref too

this trigger a const pointer need in the underlying function

Also fix some code style and prevent calculating 4 times the same position at a point

* Reduce a comparison cost for lights in updateFastFaceRow
2017-04-29 20:36:09 +02:00
shivajiva101
c729543ec4 Fix visual slide issue with set_detach, fixes #5620 2017-04-29 18:18:46 +02:00
Loïc Blot
3251e44938 content_cao: fix getPlayerControl structure copy on each step (#5677)
Also fix some codestyle issues around it.
2017-04-29 18:16:58 +02:00
Loïc Blot
3db66b4531 Client & ClientEnvirnment: don't create fake events (#5676)
Instead of create fake events on the stack on each loop call (Game::run), verify is queue is empty or not and handle event directly if there is.

This prevents fake ClientEvent creation & memory allocations

Same fix is also applied on ClientEnvironment, & rename getClientEvent to getClientEnvEvent to match ClientEnvEvent object
2017-04-29 17:25:25 +02:00
SmallJoker
f727f54192 Fix Travis/unittest broken since b662a45 2017-04-29 16:40:56 +02:00
Loic Blot
9762650f97
Remove legacy unused define DIGGING_PARTICLES_AMOUNT 2017-04-29 12:18:58 +02:00
Vincent Glize
dc5bc6cac7 [CSM] Add event on_place_node API lua (#5548)
* [CSM] Add event on_place_node API lua
2017-04-29 12:08:16 +02:00
Loic Blot
ecf08255b0
Fix Lint broken by b662a4577d692329b9ca83525e6039f2ddcd1ac1 2017-04-29 09:47:22 +02:00
Auke Kok
1ecc8756bc Reorder TileLayer. (#5638)
Despite the split of TileSpec into TileDef and TileLayer, the
TileLayer struct is still 66 bytes large, and doesn't fit in
a single cacheline.

I'm moving the color member to cacheline 2, in the hope that it
is less used and the compiler loads all the hot members in a single
cacheline instead. Only color sits now in cacheline 2, all the
other members are in cacheline 1.

Note: is_color is probably rarely set, most nodes will likely
not use hardware coloring, but this may change in the future.
Ideally, this class is shrunk to 64 bytes.
2017-04-29 09:16:32 +02:00