| Commit message (Collapse) | Author | Age |
| |
|
|
|
|
| |
color (#8996)
|
| |
|
|
|
|
|
| |
Notably it tries to receive all queued packets
between server steps, not just one.
|
| |
|
| |
|
|
|
| |
The variable name changed but this didn't cause merge conflicts, so it wasn't caught before.
|
| |
|
|
|
| |
Makes 'get_wield_item' to return the "main" ItemStack
|
| |
|
|
|
|
|
| |
The line declared a variable "m_con" instead of locking m_con.
getClient() doesn't need this anyway, so remove it.
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
| |
Safety-guards for CSM callbacks to abort on a bad implementation
Only run callbacks when the mods are loaded (and with it: builtin)
Duplication checks inside constructors
|
|
|
|
| |
Applies to player and detached inventories
|
|
|
|
|
| |
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.
|
| |
|
| |
|
|
|
|
| |
It's not required and, worse, can lead to bugs.
|
| |
|
|
|
|
|
| |
In the error condition the exception would be thrown before m_list_size
is decremented, causing a nullptr dereference in e.g. popFirst().
|
|
|
|
|
|
|
| |
Update the profiler names to make more sense of what they actually represent
Move the profiler code from header to its source file
Use monospace font to align lines
Format the statistics line to align better with surrounding values
Refresh the profiler each 3 seconds (roughly)
|
|
|
| |
Finish getNode cleanup
|
|
|
|
| |
The intended usecase is knockback, but there's potential for more.
|
|
|
|
| |
This replaces the magic numbers used as interaction modes both client-side and server-side, primarily for the sake of ease-of-readability.
|
|
|
|
| |
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
|
| |
|
|
|
|
| |
Add isImmortal server-side for proper enable_damage handling
Rework log messages
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* Optimize packet construction functions
Some of the functions that construct packets in
connection.cpp are using a const reference to get the raw
packet data to package and others use a value passed
parameter to do that. The ones that use the value passed
parameter suffer from performance hit as the rather bulky
packet data gets a temporary copy when the parameter is
passed before it lands at its final destination inside the
newly constructed packet. The unnecessary temporary copy
hurts quite badly as the underlying class (SharedBuffer)
actually allocates the space for the data in the heap.
Fix the performance hit by converting all of these value
passed parameters to const references. I believe that this
is what the author of the relevant code actually intended
to do as there is a couple of packet construction helper
functions that already use a const reference to get the
raw data.
* Optimize packet sender thread class
Most of the data sending methods of the packet sender thread
class use a value passed parameter for the packet data to be
sent. This causes the rather bulky data to be allocated on
the heap and copied, slowing the packet sending down. Convert
these parameters to const references to avoid the performance
hit.
* Optimize packet receiver thread class
The packet receiver and processor thread class has many
methods (mostly packet handlers) that receive the packed data
by value. This causes a performance hit that is actually
worse than the one caused by the packet sender methods
because the packet is first handed to the processPacket
method which looks at the packet type stored in the header
and then delegates the actual handling to one of the
handlers. Both, processPacket and all the handlers get the
packet data by value, leading to at least two unnecessary
copies of the data (with malloc and all the slow bells and
whistles of bulky classes).
As there already is a few methods that use a const reference
parameter for the packet data, convert all this value passed
packets to const references.
|
| |
|
|
|
| |
Fixes #8332
|
|
|
|
|
| |
The "what" parameter is being passed by value, most likely by
accident as the type is "const std::string". Convert it to a
reference by adding the missing "&".
|
| |
|
| |
|
|
|
|
|
| |
* Drop the ID mapper, use a big u64 instead. This will permit to resync server ids properly with the manager code
* Modernize some code parts (std::unordered_map, auto)
* generate id on client part on U32_MAX + 1 ids, lower are for server ids
|
|
|
|
|
|
| |
(#8288)"
This reverts commit 01cd63bd3bca0192dab2834faf414b022706a77e.
|
|
|
|
| |
Reverts 5dab7426451842793b183fbd961ad2ae83c8acbd
"[CSM] Add functions to create particles and particlespawners."
|
| |
|
|
|
|
|
| |
The reverted commit 968ce9af598024ec71e9ffb2d15c3997a13ad754
is suspected (through the use of bisection) of causing network slowdowns.
Revert for now as we are close to release.
|
| |
|
|
|
|
|
| |
Remove deprecated HUDs and chat message handling.
Remove unused m_damage variable (compat break).
HP: s32 for setter/calculations, u16 for getter.
|
| |
|
| |
|
|
|
|
|
| |
Store the rotation in the node as a 4x4 transformation matrix internally (through IDummyTransformationSceneNode), which allows more manipulations without losing precision or having gimbal lock issues.
Network rotation is still transmitted as Eulers, though, not as matrix. But it will stay this way in 5.0.
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
* Fix various bugs (Anticheat, Lua helpers)
Anticheat: Use camera position instead of player position for shoot line calculations
Lua helpers: Increase 'i' to not overwrite earlier added table values
* Remove lag compensation
* * 1.5 for larger selection boxes
|
|
|
|
|
| |
* Proselytize the network. Use IEEE F32
* Remove unused V2F1000 functions
|
|
|
|
|
|
|
|
|
|
|
|
| |
Previously, when the CSM restriction 'LOAD_CLIENT_MODS' was used a
client was still able to add CSM code to 'builtin' to bypass that
restriction, because 'builtin' is not yet verified.
Until server-sent CSM and verifying of 'builtin' are complete, make
'LOAD_CLIENT_MODS' disable the loading of builtin.
Clarify code comments and messages to distinguish between client-side
modding and client-side scripting. 'Scripting' includes 'builtin',
'modding' does not.
|
|
|
|
|
|
|
|
| |
* CSM: add requested CSM_RF_READ_PLAYERINFO
This new CSM limit permit to limit PLAYERINFO read from server.
It affects get_player_names call
|