1
0
mirror of https://github.com/minetest/minetest.git synced 2024-09-21 20:10:17 +02:00
Commit Graph

4225 Commits

Author SHA1 Message Date
paramat
6c9f10e132 Mgv7 floatlands: Various improvements
Floatland base terrain underside was too thin, causing excessive water
leakage through tunnels under lakes, now make it thicker.
Floatland mountain terrain had a rim 1 node thick which made it bare
stone, now make it 2 nodes thick to merge with the floatland base
terrain rim and to have a layer of biome material.
Make mountain terrain more exponentially shaped by altering the
exponent.
Remove unnecessary and potentially ugly MYMAX() applied to
n_base_height.
2016-12-01 05:08:51 +00:00
lhofhansl
5dc6198878 Optimize/adjust blocks/ActiveObjects sent at the server based on client settings. (#4811)
Optimize/adjust blocks and active blocks sent at the server based on client settings.
2016-11-30 18:13:14 +10:00
sfan5
c38985825f Allow restricting detached inventories to one player
This combats the problem of sending the hundreds of
"creative" / "armor" or whatever detached invs that
exist on popular servers to each and every player
on join or on change of said invs.
2016-11-28 13:41:19 +01:00
juhdanad
2fe3bf5a18 Limit light_source in the engine (#4814)
Since light_source>15 causes crash, it must be limited.
2016-11-28 18:43:33 +10:00
sfan5
bb06d377a1 Fix filepath > RemoveRelativePathComponent unittest
(was broken by e4ee6548af)
2016-11-27 18:39:00 +01:00
TeTpaAka
785a9a6c1a Wieldhand: Allow overriding the hand 2016-11-26 03:49:30 +00:00
ShadowNinja
e4ee6548af Fix fs::RemoveRelativePathComponents for paths with a leading dot component
Previously, paths like ./worlds would be resolved to /worlds since the
leading dot was considered just as irrelevant as a dot in the middle of
the path.
2016-11-24 10:38:23 -05:00
ShadowNinja
3af5eef964 Fix secure io.lines
It used to drop all of the return values from the
insecure version of the function.
2016-11-24 10:10:20 -05:00
ShadowNinja
9e10f9f49a Fix secure io.open without mode 2016-11-24 09:58:21 -05:00
orwell96
0d1c9598a0 Make supplying empty formspec strings close the formspec (#4737)
This will only happen if the formname matches or if formname is "".
2016-11-23 02:15:22 +10:00
Zeno-
dbeb322f62 No functional changes. Credit gcu
This merge doesn't make any functional changes. It's a trivial style fix so that @gregorycu can be dual credited along with shadowninja for PR #4800
2016-11-23 01:23:34 +10:00
ShadowNinja
4bf4154cad Fix superflous shader setting updates (#4800)
This improves rendering performance by ~40%
2016-11-23 00:05:39 +10:00
orwell96
681d127ff1 Particles: Make attached particle spawners respect the parent's yaw
Position, velocity and acceleration vectors of particles are rotated
by the yaw of the parent object so that they are truly relative to it.
Clarify new attached particle spawner behavior in lua_api.txt.
2016-11-18 06:18:54 +00:00
paramat
bc3980e1d6 Mgv7: Add optional floatlands, disabled by default 2016-11-15 23:07:06 +00:00
sfan5
5fd1ef9b58 Revert "Adding particle blend, glow and animation (#4705)"
This reverts commit 93e3555eae.
2016-11-14 15:28:06 +01:00
Foghrye4
93e3555eae Adding particle blend, glow and animation (#4705) 2016-11-15 00:09:59 +10:00
Rogier
1980d9ea31 Fix crash when attached object no longer exists
Active objects that are attached to other objects are not safe
from deletion. As a result, the parent object may have a reference
to an id of a child's that no longer exists.

If at some point an attempt is made to manipulate the child,
enviromment->getActiveObject(child-id) returns NULL. Using the
NULL pointer causes the crash...
2016-11-13 10:10:28 +01:00
raymoo
e4031156f1 Add control information to player interacts (#4685) 2016-11-12 17:22:39 +10:00
RealBadAngel
68f5b877c7 Halo: Highlight selected face
This is a slightly modified and cleaned up version of #3774 by RealBadAngel.
By sofar: Remove color change (just make it lighter) and some minor cleanups.
2016-11-12 06:41:04 +00:00
lisacvuk
8a1a9fdc24 Fixed tooltips not resizing with \n (#4766)
* Fixed tooltips not resizing with \n

* Fixed it for 1.8.4 too.

* Fixed not working with Freetype disabled.

* Modified it to use Zeno-'s solution.
2016-11-11 21:16:34 +10:00
Rogier-5
b98f98b367 Fix incorrect distance computation for visible blocks (#4765)
The client would not compute the distance from the camera to
to a mapblock correctly. The result was that blocks that were in
view (i.e. not beyond the fog limit) would not be rendered.

With the improved distance computation, a range adjustment that
existed in clientiface.cpp is no longer required.
2016-11-11 18:30:37 +10:00
Rogier-5
7e17eaedb2 Fix mob deserialization errors in the client (#4743)
The problem was seen while using the mobf mod package.

The problem happens when the server serializes entity attachments.
Sometimes, such attachments no longer exist. The serialization code
skips those. However, the total number of attachments was serialized
earlier.  Therefore the client expects more than it gets, and logs a
serialization error.
2016-11-10 13:42:49 +01:00
paramat
c05aac3766 Occlusion culling: Add comments, minor code improvements
Remove unnecessary code.
Use '/ 2.0f' because endoff is a float.
2016-11-09 00:09:35 +00:00
Lars Hofhansl
739ef175aa Sky: Draw bottom of the sky box in 'cloudy fog color'
To be identical to the lower half of the skybox sides.
Now needed as the skybox base is often seen due to increasingly vertical
mapgens.
2016-11-08 15:20:01 +00:00
Lars Hofhansl
e7c62edec9 Retrieve mapblocks from the server in a sphere, not a cube
Use unused range argument in 'isBlockInSight()' to limit mapblock sends
to a sphere of radius 'max block send distance'.
2016-11-08 15:15:27 +00:00
Lars Hofhansl
2b21cac1d8 Occlusion culling: Fix 'end offset' distance, half this for centre point
'endoff', the maximum diagonal of a mapblock, was incorrectly calculated.
Half this value for the centre point of the mapblock.
2016-11-08 15:12:08 +00:00
Lars Hofhansl
45eab340b9 Don't use reduced vertical limits for mapblock send and generation 2016-11-07 21:55:17 +00:00
adrido
295232667e Windows: Add manifest file and set "High DPI Aware" true
This resolves washy font and incorrect mouse handling on Windows if
a screen with high DPI is used.
2016-11-07 21:55:01 +00:00
SmallJoker
ad4bf2ccf9 MSVC: Generate debug information for release builds (#4674)
Replace parameters with the equivalent /Ox
2016-11-06 11:14:36 -05:00
Ner'zhul
66bb295436 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-
b5c84c34ce Fix memory leak in ::safeLoadFile (#4730) 2016-11-05 15:10:49 +10:00
lhofhansl
6bb4347208 Remove unused shader matrices. (#4723) 2016-11-04 18:12:45 +01:00
lhofhansl
dde66a82ed 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
f8fd432dca Add debug priv, and allow player to display the scene as wire-frame. (#4709) 2016-11-04 03:14:32 +01:00
Brandon
bf315c05f1 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
7607b0ac20 Add version API 2016-10-31 21:53:00 -07:00
paramat
70e2df4f86 Lua voxelmanip: Add optional buffer param for 'get param2 data'
Update lua_api.txt.
2016-10-31 10:59:38 +00:00
lhofhansl
e1842ed370 Optionally disable optimization that causes underwater and cave rendering glitches. (#4686) 2016-10-30 23:35:55 -04:00
Loic Blot
595932a860 Fix overloading problems mentioned by clang 2016-10-30 16:30:55 +01:00
Ner'zhul
9d25242c5c 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
d43326021a Rename testsounds/ directory to sounds/ (#1984) 2016-10-30 14:36:57 +10:00
sfan5
6d7b95d763 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
361e687f3a Add unittests to test player saving/loading (#4679) 2016-10-27 09:45:01 +02:00
Dániel Juhász
bcb06aeb85 Cleanup 2016-10-27 08:04:42 +02:00
Dániel Juhász
be39f61359 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
c071efaa43 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
Foghrye4
6eb6e75fff Adding LuaError on attempt to assign vectors with values out of range 2016-10-25 21:10:51 +02:00
Gael-de-Sailly
3db2f08ff9 ParticleSpawner: fix offset being added twice 2016-10-25 20:39:39 +02:00
adrido
a1e1323d6e 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
paramat
0c76303186 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