374 Commits

Author SHA1 Message Date
Aaron Suen
41ebd02286 Translation update 2020-09-25 09:34:17 -04:00
Aaron Suen
64462f7265 Revert "Simplify and tidy up rake hook"
This reverts commit 03f8d32967cc35e418d8ffb46b00f65eaf34e685.

Apparently this causes item destruction: when stack nodes are
secondarily dug by a rake, their items are not given to the
player.
2020-09-17 07:10:09 -04:00
Aaron Suen
077def305e Make rakes and drop-matching respect stack families 2020-09-17 07:03:07 -04:00
Aaron Suen
f4a9a62269 More Spanish translations 2020-09-16 20:40:32 -04:00
Aaron Suen
03f8d32967 Simplify and tidy up rake hook 2020-09-16 19:38:46 -04:00
Aaron Suen
24fd75d666 Translation update 2020-09-15 08:51:16 -04:00
Aaron Suen
b097396290 Fix unescaped @ in email 2020-09-14 23:10:35 -04:00
Aaron Suen
3ea043214c Show message when kicking outdated clients 2020-09-14 22:06:53 -04:00
Aaron Suen
d71f40b1ef Sort variants for translation inheritence
If there are multiple variants with conflicting
translations and no "generic" translation, then
sort the variants into an arbitrary but constistent
order so we always get the same results each
time we run this with the same input, and
translations don't fluctuate.
2020-09-14 21:38:53 -04:00
Aaron Suen
86d513d063 Language bidirectional filling
Share strings across variants for a common
langauge, if we don't have a string for that
specific variant.  This should help us get better
overall translation coverage.

This is done as a "filter" on converting the raw
weblate data to MT locale files, so we don't get
the purity of the original translations ruined.
2020-09-14 21:33:53 -04:00
Aaron Suen
621592bc41 Update translations
New translators: Elon_Satoshi and heshman,
working on the es_US translation
2020-09-14 20:37:56 -04:00
Aaron Suen
859a57c572 Partial translation update 2020-09-11 01:26:23 -04:00
Aaron Suen
90fbdabdf2 Redo pickup interceptor using base metatables
The new method of intercepting item addition into
player inventories hooks into the base metatables for
the userdata types only once per type, instead of
trying to substitute every inventory object with a
table (which crashed some things) and does a lookup
to find the player per inv.  This should hopefully be
more reliable, and avoid some of the leaks to
rearrangement we had before.

If we can finally stop hitting the player inv rearrange
safety net then it can be removed.
2020-09-08 09:24:45 -04:00
Aaron Suen
0440a0644e More pt translations by Terifo 2020-09-02 08:26:55 -04:00
Aaron Suen
dbae9ee71d Defer fall check during raking
This should fix "messy raking" issues where
the rake fails to pick up some things inside
its volume because they start falling due to
items below being dug first before the rake
hits them, making it more as if the rake is
actually simultaneously digging that volume.
2020-09-02 08:00:07 -04:00
Aaron Suen
ef4b320193 Multimodal Rake API
Based on what's being dug, rakes can have
different dig volumes and checks.

Lode rake now has 3 modes depending on
what's being dug:
- Loose things, same as wooden rake
- 3x3x3 exfoliating
- 3x1x1 soil tilling/digging
2020-09-02 07:53:05 -04:00
Aaron Suen
00779deaa8 Weblate updates 2020-09-02 00:14:36 -04:00
Aaron Suen
3a0fad0b99 Guard against a race condition 2020-09-01 22:36:52 -04:00
Aaron Suen
c57515a072 Rakes have gone metal too now 2020-09-01 21:42:18 -04:00
Aaron Suen
5556797e45 Genericize rake logic
This makes it possible to register additional
rakes with different capabilities.
2020-09-01 21:07:37 -04:00
Aaron Suen
f01be30a00 Tidy up registration reporting 2020-07-16 07:29:11 -04:00
Aaron Suen
84e5819753 Fix excess node obstruction
Objects that are not static-save luaents, such as
players, wieldview/bandolier, or visinvs, should not
obstruct node movement.
2020-07-15 22:18:01 -04:00
Aaron Suen
1e11f9d81e Remove compat hacks, bump min ver to 5.2+ 2020-07-14 08:20:46 -04:00
Aaron Suen
d000db43f6 Minor code cleanup 2020-07-14 08:08:16 -04:00
Aaron Suen
dc704a424a Include special_tiles in overlay.txt template 2020-07-12 10:58:17 -04:00
Aaron Suen
0246f03a7f Players no longer obstruct doors 2020-07-11 20:52:22 -04:00
Aaron Suen
a999356558 Clean up legacy ents from really old worlds 2020-07-06 21:23:02 -04:00
Aaron Suen
e234033789 Make tool wear warning visual too. 2020-07-05 17:49:09 -04:00
Aaron Suen
caac2968dc Inventory dump on built-in teleport cmd
Allow the built-in teleport command to be used
with standard NodeCore rules, i.e. players
can move freely, but items cannot.  Players
travelling by use of this command need a
special priv to keep inventory.
2020-07-05 10:13:26 -04:00
Aaron Suen
ea43981588 Condense startup log noise 2020-07-05 09:45:53 -04:00
Aaron Suen
77bb713b77 Raise minimum log level to "action"
Log entries of "info" don't end up in server log
trace output by default; it's hard-coded to
LL_ACTION in main.cpp.
2020-07-05 08:14:52 -04:00
Aaron Suen
78d321c24f Support explicit TP overrides for special_tiles
Hughes Ross has started to work on a PR for this
(https://github.com/minetest/minetest/pull/10140)
but it doesn't look like it will be ready until 5.4 at
least, and we will support pre-5.4 versions for
some time yet.  The ability for TP artists to
override special_tiles is necessary to allow things
like flowing liquid textures to be customized in
texture packs.

Add a hack for these, similar to how we did the
inventory/wield image hacks.

Note that we are also forcing overrides for special
tiles, since there may be cases where we reuse a
base image without modifiers but TP artists may
still want an independent override.
2020-07-04 19:25:37 -04:00
Aaron Suen
4ce7076708 Standardize and log players losing items
Item ejection due to injury or teleportation:
- Check for custom on_drop calls from items, e.g. admin tools
  that distintegrate instead of becoming items.
- Log players losing items so we can audit where things came from
  or went to.
- Make teleportation and injury APIs use the same methods.
2020-07-01 07:21:10 -04:00
Aaron Suen
94401942ee Protect doors, standardize protection 2020-07-01 00:30:40 -04:00
Aaron Suen
544b306660 Fix more protection mechanics
- Report violation on scaling
- Prevent optic rotation
2020-06-30 23:48:21 -04:00
Aaron Suen
b4c72c9b2c Default almost all node meta fields to private.
Trying to isolate server performance issues, it was pointed out
that clients are spending a LOT of time receiving and rebuilding
mapblock meshes, and that updating node meta triggers this, even
when that meta is not relevant to the rendering of nodes.

Rubenwardy added a suggestion to change this in the engine:
	https://github.com/minetest/minetest/issues/10127
This patch implements this suggestion at the game level, since
in NodeCore's case we already were making the assumption that
nearly all metadata fields were private.
2020-06-30 18:19:49 -04:00
Aaron Suen
e86545f5e7 Texture modifier helper library
Useful for more complex transformations like assembling
animations or tiling.

Use in a couple places to try it out, esp. the new living
sponge animation.
2020-06-30 07:10:48 -04:00
Aaron Suen
72839b1a74 Fix press and other late-registered recipes 2020-06-27 19:03:49 -04:00
Aaron Suen
8b96b96a29 Tidy up startup reports 2020-06-27 18:49:17 -04:00
Aaron Suen
085f700982 Fix ABM muxing, maybe?
Results so far are quite good: reduced ABM
total count from 82 to 36 (~60%) and got it
under the magic cache limit of 64.
2020-06-27 17:36:42 -04:00
Aaron Suen
7ae24bf7fa Further craft set reductions
- Merge the "legacy, could be anyting" sets
  into every other set so we can do only 2
  set lookups instead of 3.
- Make sure we don't do any duplicate
  recipe checks.

N.B. the craft priority order MAY be different
now, since primary node recipes are
checked before visinv stacks.
2020-06-27 13:00:34 -04:00
Aaron Suen
b2f78c0daa Indexing for craft checks
By restricting the recipes we check based
on the name of the central object being
checked, we can do many fewer craft
checks per item and avoid expensive
checks.
2020-06-27 12:20:35 -04:00
Aaron Suen
70c5dcf191 Efficient rebuild of item entity merge
- O(n) efficiency walk of item entities
- Honor stack family merging, e.g. differing lux levels combine

Since the new walk should be much more efficient, the need to
handle "extremal" cases specially, e.g. creation of a multi-stack
ent, is probably unnecessary.  Remove it from the task list,
barring any future evidence that it's still relevant.
2020-06-25 07:50:34 -04:00
Aaron Suen
0929d007ce Use nodecore.interval where appropriate
Fixes deprecated get_connected_players() at load time issue
2020-06-23 06:43:34 -04:00
Aaron Suen
5648331c9f Replace all perplayer with playerstep 2020-06-22 22:47:33 -04:00
Aaron Suen
be452b4d52 Finish base playerstep API
Now all that's needed is converting existing
mods for proof of concept.
2020-06-22 21:14:40 -04:00
Aaron Suen
7e5f70da9b Move visinv efficiency reforms
- Push early activation externally.
- Fix bug with ents fooling visinv checker into
  thinking pos is handled even when marked
  for removal
- Eliminate a redundant stack_get call
2020-06-21 09:38:54 -04:00
Aaron Suen
500ef347e1 Fully passivize visinvs
Now use an LBM to load ents, and skip the
ABM entirely.  I think we've finally found all
the "leakage" points.
2020-06-21 03:52:09 -04:00
Aaron Suen
9879a23680 Mapgen determinism
This should cause maps that have the same
seeds to have much more similar results
than before, e.g. sponge deposits will be in
the same places determined by seed and not
random each regeneration of the map.

- Mapgen shared now provides an RNG which
  will be deterministic when feasible, for
  repeatable mapgen results.
- Make existing rng-using mapgen hooks use
  the new deterministic RNG.
- Mapgen shared hooks are also run in
  deterministic order too.
- Tidy up mapgen_shared API a little more.
2020-06-20 23:48:29 -04:00
Aaron Suen
70efb016af Add auditing for player stack movement 2020-06-18 07:20:15 -04:00