Commit Graph

13 Commits

Author SHA1 Message Date
Camotoy dbfdae63f1
Add precautions to prevent stack traces on incomplete/unknown place sounds (#1717) 2020-12-20 20:42:14 -05:00
RednedEpic 8e8bc2817a Return if sound is null and update mappings 2020-06-28 12:35:17 -05:00
RednedEpic 6b68bbb413 Large refactoring to item translator and registry/util classes
- Merged ItemTranslator and ItemStackTranslator together.
- Split ItemTranslator into two classes: ItemTranslator and ItemRegistry. The registry is where items are registered, and the translator class is where item translation takes place.
- Made most of ItemTranslator's methods static and removed the initialization in Toolbox.
- Moved a handful of registry classes previously ending with 'Utils' to a 'Registry' class to be more fitting for the term.
- Moved inventory and block entity registration out of Translators.
- Renamed Translators to PacketTranslatorRegistry.
- Yeeted Toolbox.
- Minor cleanups and small refactors.
2020-05-24 20:07:05 -05:00
Camotoy 22a1073e54
Debugging improvements (#585)
* Debugging improvements

- Added an ObjectArrayList of packets we don't anticipate ever translating. Currently only holds ServerUpdateLightPacket which we don't use and probably don't need.
- Only print debugging logs from sounds if they failed to play.

* Add space
2020-05-23 16:11:54 -05:00
Luke 7195d20fae
Implement helper methods for sending packets (#487)
* Implement helper methods for sending packets, fixes an NPE when chatting before connecting to the remote server

* Change method names

* Add a space between doc comment lines

* Add debug messages
2020-05-05 10:51:43 -05:00
RednedEpic 25d3e0708f Map most all missing sounds 2020-05-03 23:56:07 -05:00
RednedEpic 7f7d89e517 Add tnt sounds/particles and support for level event sounds 2020-05-03 01:48:38 -05:00
RednedEpic d7592d8216 Add back in explosion translator, add identifier support for sounds
Some sounds require an identifier be added, otherwise they don't properly play.
2020-05-02 01:56:08 -05:00
RednedEpic 497825dd96 Fix NPE in console when a sound was missing and clean up nesting 2020-04-25 18:23:01 -05:00
RednedEpic 987edbb217 Nitpicks and add serverbound sound packet translator 2020-04-22 18:17:34 -05:00
DoctorMacc 7993f38437 Prepare for PR 2020-04-08 15:30:36 -04:00
Jason Ho 9e03c9b93a Annotate sound translator classes 2020-04-07 18:11:27 -07:00
Jason Ho 3721cc084e Add packet translators for Play, Stop, and Builtin sounds 2020-03-28 16:50:50 -07:00