1
0
mirror of https://github.com/SquidDev-CC/CC-Tweaked synced 2025-08-26 15:32:17 +00:00

2326 Commits

Author SHA1 Message Date
Toad-Dev
330ab058d3 Bump version for next release (1.100.0-rc.1). v1.18.x-1.100.0-rc.1-ccr 2021-12-26 13:56:53 -08:00
Toad-Dev
654c7571c1 Separate custom client and server events. 2021-12-26 13:53:46 -08:00
Toad-Dev
7a50bf3979 Merge branch 'mc-1.18.x/stable' into mc-1.18.x/dev 2021-12-26 12:42:34 -08:00
Toad-Dev
1153910dc0 Merge remote-tracking branch 'CC-Tweaked/mc-1.18.x' into mc-1.18.x/dev 2021-12-26 12:39:51 -08:00
Toad-Dev
af6a240c09 Fix two bugs with monitors on dedicated server (#45).
- ClientMonitors were being created on the server. This caused a crash
when TileMonitors unload and attempt to clean up their client side
buffers because the method to do that only exists on the client. We
don't have the split semantics of load and handleUpdateTag that forge
has, so our TileMonitor#load method has to do double duty and check if
the level is client side before doing client side stuff.
- Monitor contents were never sent to clients connected to a dedicated
server because MonitorWatcher was never initialized on the dedicated
server! (My bad...) To fix, I moved its initialization to the common
setup.
2021-12-25 22:30:51 -08:00
Jonathan Coates
2b901f2d5e
Merge branch 'mc-1.17.x' into mc-1.18.x v1.18.1-1.100.0 2021-12-25 08:05:25 +00:00
Jonathan Coates
62f2cd5cb2
Merge branch 'mc-1.16.x' into mc-1.17.x v1.17.1-1.100.0 2021-12-25 08:05:25 +00:00
Jonathan Coates
e558b31b2b
Fix some typos in a dfpwm example v1.16.5-1.100.0 2021-12-21 22:25:16 +00:00
Jonathan Coates
afd82fbf1f
Add speaker support to the documentation website
Happy to pick a different piece of audio, but this seemed like a fun one
to me.
2021-12-21 22:20:57 +00:00
Jonathan Coates
901d8d4c3b
Merge branch 'mc-1.17.x' into mc-1.18.x 2021-12-21 15:15:53 +00:00
Jonathan Coates
f794ce42ab
Merge branch 'mc-1.16.x' into mc-1.17.x 2021-12-21 15:10:19 +00:00
Jonathan Coates
f470478a0f
Bump CC:T version to 1.100
We're still a few days away from release, but don't think anything else
is going to change. And I /really/ don't want to have to write this
changelog (and then merge into later versions) on the 25th.
2021-12-21 14:55:01 +00:00
Jonathan Coates
aa009df740
Improve fs API introduction
Again, not perfect, but better than a single sentence.
2021-12-21 14:39:08 +00:00
Jonathan Coates
0c6c0badde
Move turtle docs into the Java code instead
Yeah, should have seen that coming
2021-12-21 12:00:13 +00:00
Jonathan Coates
bed2e0b658
Write an introduction to the turtle API
It's better at least, I just don't know if it's good.
2021-12-21 11:53:46 +00:00
Jonathan Coates
0f9ddac83c
Copy and paste the wiki guide on require
I wrote the original, so I don't need to feel guilty :)

Closes #565.
2021-12-21 00:55:16 +00:00
Jonathan Coates
932b77d7ee
Rewrite several doc introductions
Mostly focussing on rednet and modem here. Not sure if I made them any
better, we'll see!
2021-12-21 00:27:07 +00:00
Jonathan Coates
5eedea1bbb
Don't push non-pushable entities
Fixes #949
2021-12-20 17:58:39 +00:00
Jonathan Coates
114261944a
Tick pocket computers in item entity form
See #995. And no, just because I'm adding this doesn't mean it's not a
terrible issue.
2021-12-20 17:37:42 +00:00
Jonathan Coates
4d10639efb
Use correct Java annotations package 2021-12-20 12:19:52 +00:00
Jonathan Coates
cc08eced48
Fix some problems with pocket computer model properties
- We were setting state twice, rather than state and coloured.
 - Fabric forces us to use the clamped item property getter, which
   doesn't work with our computer state, as it takes a value [0, 2].
 - Fixup new pocket computer textures to match original ones.

Co-authored-by: Jummit <jummit@web.de>
2021-12-19 21:40:44 +00:00
Jonathan Coates
aa36b49c50
Enqueue audio when receiving it
While Minecraft will automatically push a new buffer when one is
exhausted, this doesn't help if there's only a single buffer in the
queue, and you end up with stutter.

By enquing a buffer when receiving sound we ensure there's always
something queued. I'm not 100% happy with this solution, but it does
alleviate some of the concerns in #993.

Also reduce the size of the client buffer to 0.5s from 1.5s. This is
still enough to ensure seamless audio when the server is running slow (I
tested at 13 tps, but should be able to go much worse).
2021-12-19 19:50:43 +00:00
Jonathan Coates
8a1067940d
Account for the game being paused when tracking sound progress
When the game is paused in SSP world, speakers are not ticked. However,
System.nanoTime() continues to increase, which means the next tick
speakers believe there has been a big jump and so schedule a bunch of
extra audio.

To avoid this, we keep track of how long the game has been paused offset
nanoTime by that amount.

Fixes #994
2021-12-19 16:29:06 +00:00
Toad-Dev
57cfcd8709 Don't hard depend on 1.18.1
It looks like other big mods are not fussed about forcing users over to
1.18.1. Since fabric loader 0.12.9 addresses the log4j issue we will
depend on that instead to help push users to safe configurations.

Everyone should be able to update their loader version, right?
2021-12-18 08:50:15 -08:00
Toad-Dev
190a110296 Update classic resource pack.mcmeta.
Gets rid of "pack made for old version of MC" warning.
2021-12-18 08:19:30 -08:00
Jonathan Coates
2562642664
Re-add JEI integration 2021-12-18 11:42:22 +00:00
Jonathan Coates
632db1cfa5
Merge branch 'mc-1.17.x' into mc-1.18.x 2021-12-18 11:38:48 +00:00
Jonathan Coates
aa0d544bba
Remove MoreRed integration
It's not been updated to 1.17/1.18, nor touched since July. Can easily
be added back in if this changes.
2021-12-18 11:35:52 +00:00
Jonathan Coates
2f6ad00764
Use Java 16 ByteBuffer methods where possible 2021-12-18 11:34:44 +00:00
Jonathan Coates
05da4dd362
Merge branch 'mc-1.16.x' into mc-1.17.x 2021-12-18 11:25:28 +00:00
Jonathan Coates
0477b2742c
Use duplicate() instead of rewind()
It's just more confusing having to keep track of where the ByteBuffer is
at. In this case, I think we were forgetting to rewind after computing
the digest.

Hopefully we'll be able to drop some of these in 1.17 as Java 16 has
a few more ByteBuffer methods

Fixes #992
2021-12-18 11:23:12 +00:00
Toad-Dev
5ee2dba7da Fix merge error.
I should try building before I push a merge, probably.
2021-12-17 18:50:47 -08:00
Toad-Dev
7f368727f4 Merge branch 'mc-1.18.x/stable' into mc-1.18.x/dev 2021-12-17 18:40:46 -08:00
Toad-Dev
4850d4346d Fix typos, tighten up README. 2021-12-17 18:01:22 -08:00
Toad-Dev
9f337c2d1c Use inner/nested classes to shield ModelResourceLocation from server.
Just cleaner then the old apoach. Thanks @SquidDev for the suggestion.
2021-12-17 16:01:21 -08:00
Toad-Dev
d9777a8d2f Bump version for next alpha. v1.18.1-1.99.2-alpha1-ccr 2021-12-17 10:49:29 -08:00
Toad-Dev
ca37dbb591 Stamp out restiched 2021-12-17 10:49:09 -08:00
Toad-Dev
93b45bffed Don't use apache commons-codec to encode NBT Hex.
Causes NoClassDefFoundError on dedicated server.

I did test this to make sure it output the same format as old
implementation (hex with lowercase alphas).
2021-12-17 10:39:16 -08:00
Toad-Dev
482ed6f6b5 Add key collision resolution strategy to MixinLanguage
Clawing this code back from an ill-thought-out Fabric PR. Now our mixin
will load all mod's en_us lang files into the default language instance
and not crash if mods provide different values for the same key. I
don't know if this resolution strategy is good, but it is *something*.
2021-12-17 10:12:53 -08:00
Jonathan Coates
fe3c42ce22
Mark 1.17 (and 1.18) as stable 2021-12-17 16:44:29 +00:00
Jonathan Coates
cbe3cb8b3e
Fix several deprecation warnings
- Switch to the new networking API, just doing sneaky things to make it
   the same as the old networking API.
 - Use new FabricLoader API
 - Don't use the static final game version, as this may change if people
   run the mod on newer versions.
2021-12-17 11:57:07 +00:00
Toad-Dev
7b3537761b Fix finding inventories below y=0.
Thankfully, the surface level of redstone ready flat worlds is now below
y=0 or, I wouldn't have noticed.

I reformatted some things to keep the diffs down against CC-Tweaked.
It might be nicer to make this return an ItemStorage as most
places we grab the Container and immediately wrap it.
v1.18.1-1.99.1-alpha-ccr
2021-12-16 18:52:22 -08:00
Toad-Dev
6ad2cdaf62 Remove MixinLevel
This mixin isn't needed since 1.17 changes to BlockEntities, and doesn't
do anything in its current state.
2021-12-16 17:40:51 -08:00
ToadDev
e6edee4c58 Make SoundEngine#play mixin cancellable.
No reason to call channel.play() twice.
2021-12-16 01:56:36 -08:00
ToadDev
6754c7bb69 Merge remote-tracking branch 'CC-Tweaked/mc-1.18.x' into mc-1.18.x/dev 2021-12-16 00:49:53 -08:00
Toad-Dev
4914ad0040 Fix NPE when pistons extend. 2021-12-15 19:49:35 -08:00
Toad-Dev
27102e6381 Remove a todo I left in after fixing the problem :) 2021-12-15 19:45:19 -08:00
Toad-Dev
9083e4f97b Ensure that static inits in Registry happen at a defined time.
There must be a better way to do this, but at least I understand why
this code existed before.
2021-12-15 19:42:11 -08:00
Toad-Dev
f74a386312 Change how we access tags to be compatible with dedicated server.
Another oversight in the merge.
2021-12-15 19:42:11 -08:00
Toad-Dev
ad0080ef32 Don't use ModelResourceLocation class on dedicated server.
Missed this during the merge.
2021-12-15 19:42:11 -08:00