| Commit message (Collapse) | Author | Age |
| |
|
|
|
| |
* Also Disable shadows when sun/moon is hidden. Fixes #11972.
|
| |
|
| |
|
| |
|
| |
|
|
|
| |
This moves relevant code into the PlayerControl class and gets rid of separate keyPressed variable.
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This commit deprecates the forward, backward, left, and right binary
inputs currently used for player movement in the PlayerControl struct.
In their place, it adds the movement_speed and movement_direction
values, which represents the player movement is a polar coordinate
system.
movement_speed is a scalar from 0.0 to 1.0. movement_direction is
an angle from 0 to +-Pi:
FWD
0
_
LFT / \ RGT
-Pi/2 | | +Pi/2
\_/
+-Pi
BCK
Boolean movement bits will still be set for server telegrams and
Lua script invocations to provide full backward compatibility.
When generating these values from an analog input, a direction is
considered active when it is 22.5 degrees away from either
orthogonal axis.
Co-authored-by: Markus Koch <markus@notsyncing.net>
Co-authored-by: sfan5 <sfan5@live.de>
|
|
|
|
| |
This comes into play on older servers which do not know the "stat" type.
Warnings are only logged once to avoid spam within globalstep callbacks
|
|
|
|
|
|
| |
Some games provide users with enough freedom to create items
with metadata longer than 64KB, preventing this from causing
issues is on them but we'll still do the minimum not to abort
the server if this happens.
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
| |
These arguments are used at least by MTG beds and homedecor_common. A deprecation warning is shown to safely remove it in a future release.
|
|
|
| |
Treat 'none' values as 'nil'
|
| |
|
|
|
| |
Co-authored-by: Zughy <4279489-marco_a@users.noreply.gitlab.com>
|
|
|
| |
Co-authored-by: Zughy <4279489-marco_a@users.noreply.gitlab.com>
|
|
|
|
|
|
|
| |
Features:
* Define Minimap available modes (surface/radar, scale) from Lua, using player:set_minimap_modes()
* New HUD elements for displaying minimap with custom size and placing
* New minimap mode for displaying a texture instead of the map
|
|
|
|
|
|
| |
Fixes some other third person camera specific attachments.
Implements a single new flag for entities to be forced visible in first person mode.
Old mods do not need to be updated to use the new flag and are fully backwards compatible.
|
| |
|
| |
|
|
|
|
| |
Co-authored-by: Sam Caulfield <sam@samcaulfield.com>
|
|
|
| |
Co-authored-by: Raul Ferriz <raul.ferriz@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* Server::overrideDayNightRatio doesn't require to return bool
There is no sense to sending null player, the caller should send a valid object
* Server::init: make private & cleanup
This function is always called before start() and loads some variables which can be loaded in constructor directly.
Make it private and call it directly in start
* Split Server inventory responsibility to a dedicated object
This splits permit to found various historical issues:
* duplicate lookups on player connection
* sending inventory to non related player when a player connects
* non friendly lookups on detached inventories ownership
This reduce the detached inventory complexity and also increased the
lookup performance in a quite interesting way for servers with thousands
of inventories.
|
| |
|
| |
|
|
|
| |
Fixes #9761
|
|
|
| |
see also 91eef646a59575bd9ae792e257bb6ad12fafc0b1
|
| |
|
|
|
|
|
|
|
| |
Move LuaEntitySAO to a new dedicated file
Drop TestSAO (useless object)
Drop the old static startup initialized SAO factory, which was pretty useless.
This factory was using a std::map for 2 elements, now just use a simple condition owned by ServerEnvironment, which will be lightweight, that will also drop a one time useful test on each LuaEntitySAO creation. This should reduce server load on massive SAO creation
|
| |
|
|
|
|
|
| |
Move serverobject.{cpp,h} to server/serveractiveobject.{cpp,h}
Move UnitSAO class to dedicated files
|
|
|
|
|
|
| |
The API implementation is shared between CSM and SSM.
Functions should retrieve a plain env when they do not
need any server-specific functions.
|
|
|
|
|
|
|
| |
Fix memory leak (unused allocation)
Fix star rendering
Rename sky color struct
Fix stars on android
Remove extraneous .data() from android star draw
|
| |
|
|
|
|
|
| |
Keeping the ObjectRefs around in a table isn't ideal and this allows
removing the somewhat nonsensical is_player_connected() added in 86ef7147.
|
| |
|
| |
|
|
|
| |
Makes 'get_wield_item' to return the "main" ItemStack
|
| |
|
|
|
|
|
| |
This change reduces the amount of sent data towards clients. Inventory lists that are already known to the player are skipped, saving quite some data over time.
Raises protocol version to 38 to ensure correct backwards-compatible code.
|
|
|
|
| |
The intended usecase is knockback, but there's potential for more.
|
|
|
|
| |
This moves the wield item functions to Player and the tool utils for range calculation
Also 'local_inventory' was removed due to redundancy in Client
|
|
|
|
|
| |
read_object_properties(). (#8689)
This prevents set_properties() calls that have nothing to do with hp_max or breath_max overriding the saved hp before another mod has the chance to set a player's intended hp_max (such as in on_joinplayer).
|