Commit Graph

48 Commits

Author SHA1 Message Date
Jonas Herzig
e6db9daf80 Update key and mouse handling in preparation for 1.21.9 2025-10-12 20:21:03 +02:00
Jonas Herzig
454e990849 Replace InputReplayTimer with Mixin 2024-06-23 20:24:57 +02:00
Jonas Herzig
31817bcf11 Split replay folder and file management into their own classes 2021-11-29 17:42:44 +01:00
Jonas Herzig
537795f9ca Backport contextual key bindings to 1.12.2 and below (closes #478) 2021-03-14 12:12:53 +01:00
Jonas Herzig
cfb9e15b8a Make use of new @Pattern feature to centralize version-aware code
That is, most of the business code should not be aware that it is being compiled
to multiple versions even when it heavily interacts with MC, preprocessor
statements should be an escape hatch, not the norm.
Similarly, code should not be forced to do `MCVer.getWindow(mc)` instead of the
much more intuitive `mc.getWindow()`, and a new preprocessor (technically remap)
feature makes this possible by defining "search and replace"-like patterns (but
smarter in that they are type-aware) in one or more central places (the
"Patterns.java" files) which then are applied all over the code base.

In a way, this is another step in the automatic back-porting process where
preprocessor statements are used when we cannot yet do something automatically.
Previously we "merely" automatically converted between different mapping, this
new feature now also allows us to automatically perform simple refactoring
tasks like changing field access to a getter+setter (e.g. `mc.getWindow()`), or
changing how a method is called (e.g. `BufferBuilder.begin`), or changing a
method call chain (e.g. `dispatcher.camera.getYaw()`), or most other
search-and-replace-like changes and any combination of those.
The only major limitation is that the replacement itself is not smart, so
arguments must be kept in same order (or be temporarily assigned to local
variables which then can be used in any order).
2021-03-14 12:12:51 +01:00
Jonas Herzig
76bec31cd8 Move cache folders into central (hidden) location (closes #343) 2020-11-06 18:54:54 +01:00
Jonas Herzig
83690f4024 Refactor key binding registrations to be more easily expandable 2020-09-06 11:45:37 +02:00
Jonas Herzig
fcd1224fa0 Allow replay to be started in sync mode (required for #349) 2020-09-06 11:45:37 +02:00
Jonas Herzig
739d5b2807 Add key hints to buttons which have corresponding keybindings 2020-08-28 15:58:02 +02:00
Jonas Herzig
2a8c802d43 Merge pull request #257 from LindaJuffermans:develop 2020-08-22 13:33:18 +02:00
Jonas Herzig
fd7b6030f9 Fix keybinding conflicts on 1.14+ (fixes #268)
This fixes both, replay-exclusive keybindings blocking vanilla ones as well as
vanilla keybindings blocking replay-exclusive ones.

The magic happens in Mixin_ContextualKeyBindings.
2020-07-25 21:40:02 +02:00
LindaJuffermans
b79848936b Implemented review changes 2020-07-17 16:32:12 +02:00
Jonas Herzig
af8803d6b5 WIP 1.15 and ReplayStudio v2 update 2020-03-13 14:18:19 +01:00
Jonas Herzig
7241036e61 AWT is forbidden on 1.13+ (this includes BufferedImage)
Instead use NativeImage on 1.13+ via newly introduced Image class.
See Image docs for details.

Also fixes an issue with thumbnail taking on 1.13+: The original
ScreenshotHelper method is now async, luckily there's a sync
variant and as a bonus it directly returns a NativeImage so we can
skip having to read the screenshot from disk.
2019-06-30 12:12:13 +02:00
Jonas Herzig
7cbf7f7c94 Switch core to 1.14 (generated via ./gradlew :1.14:setCoreVersion) 2019-05-10 14:09:22 +02:00
Jonas Herzig
17fe5b345f Replace all ATs with Mixin on 1.13+ in preparation for Fabric 2019-04-26 12:04:33 +02:00
Jonas Herzig
2ee91515f7 Make use of the source remapping feature of The Preprocessor plugin 2019-04-24 15:38:34 +02:00
Jonas Herzig
51c073012e Re-work Replay Editor UI 2019-03-12 19:44:34 +01:00
Jonas Herzig
f8fc3462e8 Get recording and replay working 2019-03-10 14:15:14 +01:00
Jonas Herzig
8705bbad9a Re-enable and fix building for older MC versions 2019-03-09 13:08:47 +01:00
Jonas Herzig
c1fefdeb3c Get core, recording and replay modules compiling on 1.13.2 2019-03-01 17:22:50 +01:00
Jonas Herzig
1470123ec9 Get replay module compiling on 1.13 2019-03-01 17:22:50 +01:00
Jonas Herzig
1670ed4e80 Fix dead lock when switching from async to quick mode 2018-12-18 10:44:42 +01:00
Jonas Herzig
12605f51de Add GUI popup for initializing quick mode and signaling failures 2018-07-27 19:50:40 +02:00
Jonas Herzig
edc54ce6d4 Add quick replay mode
Allows very quick forwards and backwards jumping at the cost of only
replaying entity positions and block updates.

Still needs to be backported from 1.12.2 and contains FIXMEs
2018-07-18 21:55:03 +02:00
Jonas Herzig
eb04eb47dc Add 1.7.10 version 2018-03-16 13:01:33 +01:00
Jonas Herzig
22e4ce4584 Make sure the replay is stopped if the main menu is opened (fixes #95) 2018-01-16 16:14:03 +01:00
Jonas Herzig
23c5df5aaa Allow the mod to be loaded in a dedicated server environment 2018-01-16 16:01:59 +01:00
Jonas Herzig
00e999ffd2 Fix replay not being closed when opened via URI scheme handler (fixes #92) 2017-08-25 15:13:27 +02:00
Jonas Herzig
1a1e96c375 Fix server with RM installed refusing clients without RM (fixes #76) 2017-07-14 13:08:16 +02:00
Jonas Herzig
35eb9cad33 Replace usage of FMLLog with the mod logger 2017-07-14 13:08:12 +02:00
Jonas Herzig
8a6ec5191b Add missing tooltips to player overview and various missing chat messages 2017-04-21 16:36:47 +02:00
johni0702
7ad19aa025 Add mod version and accepted MC version directly to the @Mod annotation 2016-12-30 12:10:43 +01:00
johni0702
655bea0b2d Replace @Mod.Instance with direct static references 2016-12-30 12:10:13 +01:00
johni0702
a6bee7c223 Store networking mods in replay file and compare installed versions on replay 2016-09-04 19:20:37 +02:00
johni0702
39834ce6b4 Allow marker removal using the DELETE key 2016-09-03 20:59:30 +02:00
johni0702
31eed8801a Add rotation key bindings 2016-09-02 22:40:03 +02:00
johni0702
e8df61aeb2 Fix replay not being closed properly 2016-08-14 17:23:44 +02:00
johni0702
372521f319 Add ReplayStudio as subproject
Move large parts of pathing to ReplayStudio
Upgrade to Java 8
2016-07-28 15:45:01 +02:00
johni0702
393a08e2da Save modifications of downloaded replays to separate file 2015-11-14 17:48:24 +01:00
johni0702
dfd133d84f Allow creating markers during replay 2015-11-08 09:54:16 +01:00
johni0702
fb5cf01b7f Allow changing of camera controller 2015-11-07 22:18:47 +01:00
johni0702
593a518fab Rewrite GuiReplayViewer
Move rename replay gui as popup into replay viewer
2015-10-12 22:07:31 +02:00
johni0702
fd4ec8e2f9 Deprecate most static fields in ReplayMod class
Fix replay restarting
2015-10-04 20:09:57 +02:00
johni0702
4d27875955 Fix mouse/keys not working when replay is paused 2015-10-04 19:02:11 +02:00
johni0702
526ee76d4a Add Play/Pause hotkey 2015-10-04 15:44:27 +02:00
johni0702
213c16c81d Rewrite thumbnail creation 2015-10-04 15:43:19 +02:00
johni0702
f925d56ca2 Split mod into core, recording, replay, render[todo], paths[todo] and extras[wip] modules
Move everything to com.replaymod package
Add KeyBindingRegistry and SettingsRegistry
Recreate settings GUI with new GUI API and dynamically from SettingsRegistry
Use ReplayFile from ReplayStudio
ReplayHandler is now object oriented
Add GuiOverlay, GuiSlider and GuiTexturedButton to GUI API
Rewrite both overlays to use new GUI API
Fix size capping in vertical and horizontal layout
Allow CustomLayouts to have parents
Fix tooltip rendering when close to screen border
Allow changing of columns in GridLayout
2015-10-03 17:36:04 +02:00