2806 Commits

Author SHA1 Message Date
Aaron Suen
e3aef49a11 Make crafting work with non-node items
For example, making torches, assembling tools.
2022-03-29 08:28:18 -04:00
Aaron Suen
03d81b873a Translation updates 2022-03-29 08:11:28 -04:00
Giuseppe Bilotta
44a537e705 Fix placement of eggcorns on top of shelves
Right-clicking on the top of a shelf would place a legacy plantlike
eggcorn. This was due to the storebox right-click override
unconditionally calling `item_place_node` when placing an item against an
inaccessible side of a storebox.

The solution would be to call `item_place` instead, since that function
has the logic to handle `place_as_item` correctly. However, this cannot
be called from the storebox right-click override directly because
`item_place` calls the `pointed_thing` `on_rightclick`, which would
cause an infinite recursion.

Solve this by refactoring the placement logic into a new
`minetest.item_place_node_or_stack` which is called by `item_place`,
as well as by the storebox right-click override when placing items.
2022-03-25 19:15:02 +01:00
Giuseppe Bilotta
eee5ee27aa Typos 2022-03-23 22:30:36 +01:00
Giuseppe Bilotta
8d6d8237c8 Fix form contents not falling on stack below
If an item stack is present in the node below a form,
the stack in the form will not fall into it even if it could add to it
(e.g. a 16-sand stack in the form will not fall into a 2-sand stack
below).
This is due to the item stack node being non-buildable-to and missing a
can_item_fall_in method, causing the stack_can_fall_in checks in
storebox_check_item_fall_out from failing when the shouldn't.

Fix by implementing the can_item_fall_in method for item stack nodes.
The implementation follows the storebox one, without any “geometric”
checks on accessible sides.
2022-03-23 22:29:07 +01:00
Aaron Suen
96b4947c13 Simplify node/stack change optic notification
Instead of adding a special hook for storeboxes, just treat all
stack changes as node changes and notify all update listeners.
2022-03-14 07:13:43 -04:00
Aaron Suen
00c98d868d Merge branch 'dev' into shelfoptics 2022-03-14 09:56:23 -04:00
Aaron Suen
c433b36f2b Formatting, add contributor to license 2022-03-14 07:03:44 -04:00
Giuseppe Bilotta
31223ddb00 Typo fix in group name 2022-03-13 23:24:17 +01:00
Giuseppe Bilotta
512c6b05cd Properly check for param2 in optic_commit 2022-03-13 23:24:17 +01:00
Giuseppe Bilotta
bdc27cf304 Fix typo 2022-03-13 23:24:17 +01:00
Giuseppe Bilotta
26ca863b68 Check dependent optics on storebox content change
Changes to the stack stored in a storebox do not trigger a node update,
which meant that affected optics to not get updated until the next ABM.

Use the newly introduced storebox_register_on_stack_change to trigger
a check on dependent optics just like node updates.
2022-03-13 23:24:17 +01:00
Giuseppe Bilotta
925de33418 Make storebox_on_stack_change extensible 2022-03-13 23:24:17 +01:00
Giuseppe Bilotta
0cc6604207 Storeboxes should let light through their open sides
Storeboxes such as shelves do not let sunshine propagate because some of
the sides are opaque, but some sides are still open, and these should
still let light through.

During the optic scan phase, handle opaque nodes with visible inventory
by checking if the light travel direction also allows storebox access,
(from both the front and back face) and consider the node transparent in
such a case (unless, of course, the contained items are opaque).
2022-03-13 23:24:17 +01:00
Aaron Suen
82e9c3d50c Add "recent breaking changes" to CDB 2022-03-13 10:10:28 -04:00
Aaron Suen
834b13e6ad Fix sedges not stacking in containers
Placing a sedge into a container via right-click would
randomly transform the sedge to one of the 5 different
random stages of growth, same as placing on the
ground would, causing non-sedge_1 sedge items to
exist which don't stack with normal sedge_1 anymore.

Instead, simplify the growth feature to apply the
change to the sedge in node form after it's been
placed, instead of manipulating items.
2022-02-27 21:25:40 -05:00
Aaron Suen
14895caee5 Update issues
Move unconfirmed/unreproducible issues to a separate
"rumors" file, move issues back to main lists only once
we've found a way to confirm or otherwise understand
them (or really just go ahead and fix them immediately
if possible).
2022-02-27 19:54:41 -05:00
Aaron Suen
e54ca43c5c Translation updates 2022-02-27 19:29:49 -05:00
Aaron Suen
b6232f4f99 Fix freeze due to door infinite loop
A certain arrangement of door-gears with a couple of
pieces of sand next to it can get in a situation that
causes an infinite loop, e.g. as if the sand nodes are
trying to switch places with one another and form a
circular dependency.

The simplest patch for it is just to limit recursion
for now.  Randomness in the depth reduces the risk
that machines themselves can get stuck in some
pathological state.
2022-02-26 15:16:32 -05:00
Aaron Suen
6ea71897ad Fix min delay calc 2022-02-13 20:51:02 -05:00
Aaron Suen
f7e43026e4 Ensure deferred door DNT doesn't loop 2022-02-13 20:35:19 -05:00
Aaron Suen
05a28322a3 Add an issue 2022-02-10 22:36:47 -05:00
Aaron Suen
57ea4270cf Don't drop one item when dropping many
Aux+sneak+drop is supposed to drop all stacks
that match, but it was dropping one item from the
selected stack first before dropping the rest.  This
caused (1) dropping a stack of 1 might cause the
rest of the matching items not to drop, and (2)
dropping leaves or sticks or other stack-as-node
items would place a node.

Instead, suppress immediately dropping any
items at all when using aux+drop or
aux+sneak+drop and handle all drops in the
delayed stage.
2022-02-10 22:36:26 -05:00
Aaron Suen
194063d1ac Support new count_meta
https://github.com/minetest/minetest/pull/8448
2022-02-10 22:27:36 -05:00
Aaron Suen
19a7d982d6 Update setting types 2022-02-10 22:13:46 -05:00
Aaron Suen
dd5127c6c4 Upper limit for "saved" soaking tickle time 2022-02-10 22:13:39 -05:00
Aaron Suen
a2f81d9ee1 DNT auto-start refinements
- Regen with LBM too.
- Allow different delay time for "just loaded" case.
- Use DNT auto-start for more things, replacing
  regen ABM/LBM where possible.

Also tried to improve door ablation reliabiity:
- Use DNT autostart for door ablation.
- Faster DNT check so we don't need the ABM
  neighbor scan anymore.
- On early ablation trigger, set DNT for right after
  cooldown ends instead of letting DNT loop die,
  removing one scenario that could cause
  sponge squeezer stalls.
2022-02-10 22:08:58 -05:00
Aaron Suen
0ba60c624a Translation sync 2022-02-10 06:55:54 -05:00
Aaron Suen
c5bcb15a60 End-of-support 5.3 2022-02-10 06:52:29 -05:00
Aaron Suen
74cc93dea1 Notes merge 2022-02-06 10:48:35 -05:00
Aaron Suen
766aafa72b Fix crash on stack meta field reordering
Reconstructing a stack by transferring items from another
stack into an empty one, and then re-serializing, can cause
the fields to end up in a different order in serialization, which
causes a false positive detecting stack changes, which cause
another recheck, leading to a stack overflow.

Compare objects structurally, i.e. their key/value pairs,
rather than relying on stable serialization.  The old method
only worked reliably in the case of objects having only one
meta field, which accidentally had worked out most of the
time, but doesn't work well with some mods, e.g. cats that
have both a name and furball metadata.
2022-02-04 20:48:22 -05:00
Aaron Suen
2e6e1dde34 Fix crash on nil dnt_get 2022-01-30 09:56:39 -05:00
Aaron Suen
a8c521caea Add missing dnt_get API 2022-01-30 09:39:43 -05:00
Aaron Suen
8b8460476e Fix embedded screenshot aspect ratio
MT uses the weird aspect ratio of 3:2 for thumbs
2022-01-28 09:42:47 -05:00
Aaron Suen
7abb5369db Merge branch 'master' into dev 2022-01-28 09:06:03 -05:00
Aaron Suen
41c7c948c6 Don't track "featured" tag in CDB 2022-01-28 09:05:46 -05:00
Aaron Suen
b14a6fd272 Add an (almost) blank file for weblate 2022-01-25 01:00:34 -05:00
Aaron Suen
144f45e13b Update to hosted weblate 2022-01-24 23:48:45 -05:00
Aaron Suen
600f1380a7 Add a blank template for weblate 2022-01-24 23:07:14 -05:00
Aaron Suen
b64432fc46 Add thatch and wicker to screenshot 2022-01-24 20:55:11 -05:00
Aaron Suen
fe347b9612 Some more issues 2022-01-23 20:58:24 -05:00
Aaron Suen
4d05be735d Make fire ambiance a bit more audible 2022-01-23 17:41:00 -05:00
Aaron Suen
9555a1ecba Optimize ABM delay
Only register a single job with after() per tick.
Store actual node processing to do in a much
simpler linear array.
2022-01-23 17:28:48 -05:00
Aaron Suen
1da5ebcc7f Soaking tickle recipes require placed nodes 2022-01-23 16:51:39 -05:00
Aaron Suen
9022332cc6 Merge branch 'master' into dev 2022-01-23 15:52:57 -05:00
Aaron Suen
66a338b680 Fix lode rake recycling/wearout recipes 2022-01-23 15:52:46 -05:00
Aaron Suen
d9d33d1a4f Fix rad damage blocking
Instead of trying to skip everything (and not
updating stats), just set rate to 0.
2022-01-22 22:17:35 -05:00
Aaron Suen
10a447799b Merge branch 'master' into dev 2022-01-22 22:14:40 -05:00
Aaron Suen
c4f41348e0 Fix skybox being sent every step 2022-01-22 22:11:55 -05:00
Aaron Suen
034ecef2a9 Reuse envsound fx ents from a pool
This seems to reduce steady-state bandwidth
usage when standing still significantly, at least
according to rudimentary tests.

Try to reuse the entity that is already physically
closest to the target position, so to maximize
the chance that nearby player(s) already have
the entity transferred and only need the new
pos data, in case MT is intelligent enough to send
only the needed changes.
2022-01-22 21:49:11 -05:00