5915 Commits

Author SHA1 Message Date
Ner'zhul
c8fb80f660 PlayerSAO saving fix (#4734)
PlayerSAO::disconnected() function was historical and remove the link between SAO and RemotePlayer session. With previous attributes linked to RemotePlayer saving was working. But now attributes are read from SAO not RemotePlayer and the current serialize function verify SAO exists to save the player attributes.

Because PlayerSAO::disconnected marks playersao for removal, only mark playerSAO for removal and let PlayerSAO::removingFromEnvironment do the correct saving behaviour and all the disconnection process instead of doing a partial removal and let the server loop doing the RemotePlayer cleanup and remove some saved attributes...
2016-11-05 10:25:30 +01:00
Zeno-
d23d3fcff5 Fix memory leak in ::safeLoadFile (#4730) 2016-11-05 15:10:49 +10:00
lhofhansl
fec859fe92 Remove unused shader matrices. (#4723) 2016-11-04 18:12:45 +01:00
lhofhansl
39fca7b510 Cycle directly to nothing shown instead of showing the profiler graph again
Fix for previous commit.
2016-11-04 05:08:23 +01:00
lhofhansl
9447a9b575 Add debug priv, and allow player to display the scene as wire-frame. (#4709) 2016-11-04 03:14:32 +01:00
Brandon
7e703858b8 Add minetest.get_server_uptime() function to Lua API (#4702)
Add minetest.get_server_uptime() function to Lua API
2016-11-02 09:36:58 -07:00
ShadowNinja
c9100740e4 Add version API 2016-10-31 21:53:00 -07:00
paramat
9037505da6 Lua voxelmanip: Add optional buffer param for 'get param2 data'
Update lua_api.txt.
2016-10-31 10:59:38 +00:00
Auke Kok
5d6adaebb7 Core.rotate_and_place: Remove unused call to get_look_pitch() 2016-10-31 10:55:36 +00:00
lhofhansl
0fc4eb72d1 Optionally disable optimization that causes underwater and cave rendering glitches. (#4686) 2016-10-30 23:35:55 -04:00
Loic Blot
4abc944397 Fix overloading problems mentioned by clang 2016-10-30 16:30:55 +01:00
Ner'zhul
4d9f4685ff PlayerSAO/LocalPlayer refactor: (#4612)
* Create UnitSAO, a common part between PlayerSAO & LuaEntitySAO
* Move breath to PlayerSAO & LocalPlayer
* Migrate m_yaw from (Remote)Player & LuaEntitySAO to UnitSAO
* Migrate m_yaw from Player to LocalPlayer for client
* Move some functions outside of player class to PlayerSAO/RemotePlayer or LocalPlayer depending on which class needs it
* Move pitch to LocalPlayer & PlayerSAO
* Move m_position from Player to LocalPlayer
* Move camera_barely_in_ceiling to LocalPlayer as it's used only there
* use PlayerSAO::m_base_position for Server side positions
* remove a unused variable
* ServerActiveObject::setPos now uses const ref
* use ServerEnv::loadPlayer unconditionnaly as it creates RemotePlayer only if it's not already loaded
* Move hp from Player to LocalPlayer
* Move m_hp from LuaEntitySAO to UnitSAO
* Use m_hp from PlayerSAO/UnitSAO instead of RemotePlayer
2016-10-30 14:53:26 +01:00
Hugo Locurcio
074cfa436d Rename testsounds/ directory to sounds/ (#1984) 2016-10-30 14:36:57 +10:00
sfan5
42b217515d Add missing keyname_to_keycode function (needed on Android)
When rewriting keycode.cpp I overlooked this function, fixes #4683 completely
2016-10-28 15:50:23 +02:00
Ner'zhul
19805c12e4 Add missing remoteplayer.cpp to Android build
this should fix #4683
2016-10-28 15:37:19 +02:00
Ner'zhul
efea8e8cce Add unittests to test player saving/loading (#4679) 2016-10-27 09:45:01 +02:00
Dániel Juhász
93e067c39e Cleanup 2016-10-27 08:04:42 +02:00
Dániel Juhász
703c121576 Use node lighting for liquid spreading
This commit modifies the liquid transforming procedure to light and
unlight nodes instead of whole map blocks.
2016-10-27 08:04:42 +02:00
Dániel Juhász
7f8545d2d7 Improved lighting
This commit rewrites the procedure that is responsible for light
updating.

this commit
-provides iterative solutions for unlighting and light spreading
-introduces a new priority queue-like container for the iteration
-creates per-node MapBlock caching to reduce retrieving MapBlocks from
the map
-calculates with map block positions and in-block relative node
coordinates
-skips light updating if it is not necessary since the node's new light
will be the same as its old light was
2016-10-27 08:04:42 +02:00
raymoo
48aead7d1e Document item use callbacks (#4668) 2016-10-27 13:24:34 +10:00
lhofhansl
ab2315af66 Shaders: Remove special handling for liquids. (#4670) 2016-10-26 16:24:45 +02:00
Foghrye4
94eeb7ff8a Adding LuaError on attempt to assign vectors with values out of range 2016-10-25 21:10:51 +02:00
Gael-de-Sailly
df8f958a12 ParticleSpawner: fix offset being added twice 2016-10-25 20:39:39 +02:00
adrido
d4d26da258 Windows: dont link to libraries that are already linked by cmake
This solves the problem whith building where build fails if the libaries have different names.
2016-10-25 13:54:24 +02:00
Lars Hofhansl
a1458f75a4 Shaders: Apply tone mapping before fog calculation. 2016-10-25 07:49:19 +02:00
Lars Hofhansl
b1a5c9fe3a Shaders: Harmonize Irrlicht and shader fog calculations 2016-10-24 07:41:00 +01:00
paramat
00a733ac21 Lua_api.txt: Clarify 'override_meta' bool in 'set mapgen setting' 2016-10-21 05:49:06 +01:00
paramat
d92cbb2fed Damage flash: Reduce maximum alpha. Avoid fade overload
Flash alpha maximum is reduced from 180 to 127 to avoid player blindness
in combat. Flash alpha minimum is unchanged.
The 'damage_flash' value is now limited to max alpha, to avoid multiple
hits creating a huge value that causes flash to stay at maximum alpha
for a long period. Now alpha always starts to fade immediately after
taking damage.
Both problems can be seen in Minetest let's play videos.
Simplify and optimise some code.
2016-10-21 05:48:53 +01:00
paramat
000a472226 Changes to static object storage limit and error message
Move static object storage force-delete message from errorstream to
warningstream.
Increase 'max objects per block' setting to 64.
Add missing spaces in warning code.
2016-10-20 03:40:47 +01:00
red-001
aec348315e Chat commands: Trim whitespaces from input of /privs command 2016-10-20 03:39:03 +01:00
Foghrye4
e2b3b4ba07 Fix crash on attaching player to entity
Rename "refresh" to "processInitData"
2016-10-19 08:40:43 +02:00
rubenwardy
bb94e62525 Builtin: Add vector.floor helper function 2016-10-17 22:03:49 +02:00
Lars Hofhansl
52d84098e8 Revert changes to toggleNoClip and toggleFreeMove 2016-10-17 20:26:48 +02:00
Lars Hofhansl
7a7cc16e2a Don't use day light sky unless noclip and free_move are enabled 2016-10-17 20:26:48 +02:00
ShadowNinja
94b39ce44f Enable mod security by default 2016-10-16 01:14:54 +01:00
red-001
d4b87e9607 Builtin/../chatcommands: Add /grantme command 2016-10-16 01:13:50 +01:00
Rogier
afaa228dbf Emergeblocks: Fix occasional crash
Modification of the emergeblocks internal state was not protected
by a lock, causing a race condition.
This can be reproduced by repeatedly running emergeblocks for an
already-generated section of the map (with multiple emerge threads).
2016-10-16 01:13:16 +01:00
Tim
eb00be3703 Travis: Only trigger a compile, when C/C++ related files were touched (#4284) 2016-10-15 17:59:23 +02:00
sfan5
8b98a7dee9 Make documentation about ItemStack:set_{name,count,wear} clearer
These methods do not actually fail but instead clear the item stack
	and return false if a value like e.g. "" is passed.
2016-10-15 12:42:59 +02:00
tenplus1
a3a7538a92 Builtin/../falling.lua: Code optimisation 2016-10-14 02:12:32 +01:00
Lars Hofhansl
921e88f1c3 Use range-based fog instead of z-plane based. 2016-10-13 23:30:15 +02:00
raymoo
6e0388ece4 Attached particle spawners 2016-10-13 17:33:16 +02:00
sfan5
49e0ab9493 Don't use unordered maps for ProfilerGraph (fixes flickering) 2016-10-12 18:42:18 +02:00
red-001
25426f9156 Add a button for disabling all mods to world config. (#3900) 2016-10-12 03:11:38 +10:00
SmallJoker
d4fc6c3dc7 Add missing languages to the settings 2016-10-11 07:32:47 +02:00
Rogier
1c0df840f7 Disable cmake message concerning WIN32 on non-windows systems 2016-10-11 07:29:04 +02:00
Loic Blot
ef7735ab3a A little cleanup since previous commit 2016-10-09 16:31:43 +02:00
Loic Blot
94cfb9ae7c Environment cleanup
* Move client list to ServerEnvironment and use RemotePlayer members instead of Player
* ClientEnvironment only use setLocalPlayer to specify the current player
* Remove ClientEnvironment dead code on player list (in fact other players are CAO not Player objects)
* Drop LocalPlayer::getPlayer(xxx) functions which aren't used.
* Improve a little bit performance by using const ref list for ClientEnvironment::getPlayerNames() & Client::getConnectedPlayerNames()
* Drop isLocal() function from (Local)Player which is not needed anymore because of previous changes

This change permits to cleanup shared client list which is very old code.
ClientEnvironment doesn't use player list anymore, it only contains the local player, as addPlayer is only called from Client constructor client side.
Clients are only CAO on client side, this cleanup permit to remove confusion about player list.
2016-10-09 15:17:10 +02:00
Rui
af0b729abf Remove unused parameter of GUIVolumeChange 2016-10-09 10:35:51 +02:00
Loic Blot
d014961e52 Move RemotePlayer code to its own cpp/header 2016-10-08 22:27:44 +02:00