1867 Commits

Author SHA1 Message Date
Aaron Suen
12f7419d84 Guard against crash on invalid ent state
Somehow an ent can get into a state where
it needs to set velocity but doesn't know what
velocity to set; velocities are transient
phenomena anyway, so just ignore this.
2020-10-04 08:20:05 -04:00
Aaron Suen
42d4cef19b Log splitting relaxations
- Allow splitting "upside down" logs.
- Allow splitting logs from the bottom using at least lode-tier
  tools (allowing automation options).
2020-09-30 06:38:46 -04:00
Aaron Suen
a83e2e9e25 New door automation hints 2020-09-29 23:27:41 -04:00
Aaron Suen
16641ff3e9 Fixed door pummel/dig handling
- Use catapult infrastructure instead
- Checks for storebox open sides
- All manual tests passed
2020-09-29 22:54:28 -04:00
Aaron Suen
15282c88a7 Initial working door digging/pummeling 2020-09-29 22:44:09 -04:00
Aaron Suen
6b3e5f21a1 Allow custom toolgroups for craft check 2020-09-29 22:39:55 -04:00
Aaron Suen
7cbd681d54 Fix issues with dig-by-mod
Crashes when a non-player digs a node, i.e.
having mod automation perform a dig_node()
2020-09-29 22:39:06 -04:00
Aaron Suen
8bb999f631 Make sure stack fits in target box 2020-09-29 22:27:05 -04:00
Aaron Suen
a78bf0ea2a "Lazy" crafting API
Instead of checking for and immediately
completing a craft, the API can be told to
search for a recipe and return a function that
can be used to commit it later.  This way,
we can search for a valid recipe during the
"check" phase of a craft check and then
commit it during the "after" phase.
2020-09-29 21:44:26 -04:00
Aaron Suen
a63b38f72a Press injecting into storeboxes 2020-09-29 21:28:34 -04:00
Aaron Suen
9a23e1f65f Separate press/catapult code 2020-09-29 21:13:31 -04:00
Aaron Suen
ed2cfc18a1 Register capabilities for tool heads
This allows tool heads to be used in crafting,
esp. presscraft.  Note that certain tiers do not
have tool heads, like stone and infused.
2020-09-29 21:10:26 -04:00
Aaron Suen
e776723a3f Code format 2020-09-29 20:52:31 -04:00
Aaron Suen
502192b6ab Presses can eject items out of shelves 2020-09-29 20:52:18 -04:00
Aaron Suen
bca338246c Tweak rad hud math again
Use an exponential scale for alpha intensity so
subtler shading gets narrower gradations
2020-09-28 23:07:43 -04:00
Aaron Suen
d1134a1e42 Quick "cheat" codes for fire management 2020-09-28 22:17:22 -04:00
Aaron Suen
56770891de Remove an issue from the wishlist
Setting the water sink rate to zero seems satisfactory
enough.  Players can now tread water without
sinking.  It DOES feel a little like you're just hovering
in water instead of bobbing, but I guess it's the best
we can expect from the engine right now.
2020-09-27 23:22:18 -04:00
Aaron Suen
a346b5457f Reduce lag from continuous rad hud redraw
Round alpha channel to 16 levels, so we will have
cached all possible alpha values after not too long.
2020-09-27 22:49:34 -04:00
Aaron Suen
a7fc1d401f Fewer, larger, less laggy tool breakage particles 2020-09-27 21:46:16 -04:00
Aaron Suen
d983673504 Reduce number of unique dig particle textures
16 total mask positions rather than like 150.  This
should (1) cut back on video memory leakage, and
(2) reduce the probability of client lag due to drawing
dynamic textures all the time, after it's had a little
time to "warm up".
2020-09-27 21:31:31 -04:00
Aaron Suen
b73e70d351 Fix some translate inform warnings. 2020-09-27 09:30:57 -04:00
Aaron Suen
caf1de7c56 Expand on_register_item API, add retroactivity
- Pass a def table instead of a function
- Retroactive defs will also scan over all existing
  definitions and have an opportunity to modify them
  at time of registration.
2020-09-27 09:28:49 -04:00
Aaron Suen
aa8d943ddb Warn about late translation informing
We want to start requiring translation informing to
happen at loadtime, so we can sort strings into
groups by mod, so we can (1) keep the base NC
locale data clean of optional mods, and (2) manage
translations for mods separately.
2020-09-27 09:27:37 -04:00
Aaron Suen
403fe073e7 Translation updates 2020-09-26 23:03:25 -04:00
Aaron Suen
17ca961ea7 Merge more Discord notes 2020-09-26 22:24:09 -04:00
Aaron Suen
3203ddc6a9 Fix door hints not saying "hinged panel" 2020-09-26 22:12:57 -04:00
Aaron Suen
82452c9cb6 Annealed lode cube hint
Stepping stone to reach tote handle hint
2020-09-26 22:09:22 -04:00
Aaron Suen
53850e792b Merge branch 'newwitness' into dev 2020-09-26 20:18:04 -04:00
Aaron Suen
fb6a4d7dd1 Hyrbid immediate/delayed witnessing
If we have line of sight to see the event happen
now, then discover it immediately, otherwise save
it for delayed witnessing on punch.
2020-09-26 20:17:31 -04:00
Aaron Suen
64e917fc95 New witnessing system
If a player is close enough to an event when it
happens (withing "likely hearing" distance) then if
they later punch the node then they can "collect"
the discovery.

The idea is that if a player hears the sound of
something happening, then they might go and
investigate and discover the thing they thought
they had left there isn't what's there anymore.

In retrospect I may want to combine this with a
limited form of the visual witnessing, just as there
may be events that a player is less likely to touch
in aftermath, or may not be practical to (e.g.
if what's left behind is air)
2020-09-26 17:52:09 -04:00
Aaron Suen
35186ec076 Hint for throwing an item really fast
Also expand player discover API to allow passing
multiple keys in a single call, saving db lookup/save
repetition.
2020-09-26 16:29:28 -04:00
Aaron Suen
7fc796bd93 Hints for dropping items
These may be especially valuable because some
players may be used to dropping items ONLY using
the formspec inventory and may have forgotten that
they even have key bindings for this; the hint should
motivate them to search for a way.
2020-09-26 16:17:11 -04:00
Aaron Suen
6752808a81 Expand tote hint prereqs 2020-09-26 16:10:39 -04:00
Aaron Suen
3b864e5330 Fix and cache hint key expansion 2020-09-26 15:33:23 -04:00
Aaron Suen
77464e725a Reduce witness log noise 2020-09-26 15:04:34 -04:00
Aaron Suen
d4fdf8c6e8 Fix items unplaceable due to stack/touch-hurt 2020-09-26 15:03:22 -04:00
Aaron Suen
723d30897d Fix a couple more hints 2020-09-26 14:55:15 -04:00
Aaron Suen
90e932bf9d Fix lode smelting hint 2020-09-26 14:19:12 -04:00
Aaron Suen
41ebd02286 Translation update 2020-09-25 09:34:17 -04:00
Aaron Suen
4f35782ecc Fix a few more old skinny selection boxes 2020-09-17 21:51:44 -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
2022371cff Finally retire old inventory rearrange logic
It seems as though the new intercept hooks are catching
everything, and since this logic was disabled hardly anyone
noticed.  The few rearrangements that were happening were
probably caused by inventory clear/restore mods unrelated to
NC operation.  This code was quite complex and removing it
will simplify the project.
2020-09-17 07:01:06 -04:00
Aaron Suen
f24230e924 Late-bind touchtip API
Allow mods to intercept/override
2020-09-16 20:53:22 -04:00
Aaron Suen
f4a9a62269 More Spanish translations 2020-09-16 20:40:32 -04:00
Aaron Suen
ad852b8782 "Wood" in names for stick tools
Now that we have non-wooden versions of
these, suffix material name for consistency.
2020-09-16 20:19:18 -04:00
Aaron Suen
aebc0c6124 Expand stickwork selection hulls 2020-09-16 20:18:15 -04:00
Aaron Suen
3d72999ef6 Log player push-out
It seems as though there might be something
weird happening with this on join.  Add extra
logging so we can see what's happening.
2020-09-16 19:59:07 -04:00
Aaron Suen
b03b047f0a Buff door catapult, esp higher level doors 2020-09-16 19:46:10 -04:00
Aaron Suen
904d6a2321 Change some default settings 2020-09-16 19:39:16 -04:00