Krishna Roy
📎 1 file 5,205 chars
📄
pasted-code-1793319624654.txt
txt 124 lines
▶
# REWIND STUDIO — COMPLETE MINECRAFT MOD DEVELOPMENT

Build a fully functional Minecraft Java Edition 1.21.11 Fabric client-side mod named **Rewind Studio**, inspired by Lunar Client Rewind.

The main purpose is to record actual live Minecraft gameplay and edit it inside Minecraft, similar to OBS + Adobe Premiere Pro combined into one mod.

IMPORTANT: Do not create a cinematic replay-only mod, timelapse generator, or fake UI prototype.

## 1. LIVE GAMEPLAY RECORDING
- Record actual Minecraft gameplay in real time.
- Start, pause, resume and stop recording.
- Add START RECORDING and STOP RECORDING buttons to Minecraft's ESC menu.
- Display recording status, elapsed time and FPS.
- Support 720p, 1080p and higher resolutions when hardware permits.
- Support configurable 30, 60 and 120 FPS.
- Capture actual game visuals, shaders, resource packs and audio.
- Save recordings locally as MP4.
- Minimise game performance impact.

## 2. RECORDING LIBRARY
Create a modern main menu displaying all recorded videos.
- Show thumbnails, filenames, duration, resolution and FPS.
- Include search, rename, delete and sorting.
- Clicking a recording must open a separate editing page.
- Allow importing external video, audio and image files.

## 3. CUSTOM UI THEMES
- Allow custom background colours and UI colours.
- Include Purple, Blue, Red, Green, Black and Dark themes.
- Allow custom accent colours and button styles.
- Save theme preferences permanently.
- Add smooth animations and a professional interface.

## 4. BUILT-IN VIDEO EDITOR
Create a Premiere Pro-inspired multitrack editor inside Minecraft.

Include:
- Multiple video and audio tracks.
- Timeline with drag-and-drop editing.
- Cut, trim, split, merge and rearrange clips.
- Text, titles, subtitles and image overlays.
- Background music and sound effects.
- Transitions, zoom, crop and rotation.
- Slow motion and speed control.
- Colour grading, brightness and contrast.
- Undo, redo and autosave.
- Real-time video preview.
- MP4 export with configurable resolution and FPS.

## 5. RESOURCE PACK AND SHADER MANAGER
Inside Rewind Studio:
- Show installed resource packs and shader packs.
- Enable, disable, add and remove packs.
- Allow switching packs before recording.
- Record the actual rendered appearance of the game.
- Support compatible shader systems such as Iris and compatible resource-pack systems.
- Do not falsely claim support for incompatible renderers.

## 6. FREE LOOK
- Add an independent Free Look camera.
- Customisable mouse sensitivity and keyboard controls.
- Allow camera movement without changing actual player movement.
- Support additional camera editing only where recording data permits it.

## 7. RECORDING PERFORMANCE
This is a critical feature.

- Use efficient screen/frame capture.
- Use hardware encoding such as NVENC, AMF or Quick Sync when available.
- Use asynchronous encoding and buffering.
- Avoid blocking Minecraft's render thread.
- Separate recording FPS from game FPS as far as technically possible.
- Display actual recording FPS, dropped frames and encoding performance.
- Optimise for low-end PCs with 4–8 GB RAM.
- Maintain stable video FPS even with demanding shaders where hardware permits.
- Never promise impossible zero-frame-drop performance.
- Use frame pacing or duplication when necessary and clearly report it.

## 8. TECHNICAL REQUIREMENTS
Target environment:
- Minecraft Java 1.21.11
- Fabric Loader 0.18.2
- Fabric API compatible with 1.21.11
- Java 21
- Sodium compatibility
- Client-side only
- No server plugin required.

STRICT COMPATIBILITY:
- Do not use dependencies requiring Fabric Loader 0.19.2 or newer.
- Do not include libraries requiring Java 22 or newer.
- Verify every dependency version.
- Use compatible mappings and APIs.
- Avoid incompatible native libraries.
- Correctly configure fabric.mod.json and mixin configurations.
- Do not introduce unnecessary dependencies.

## 9. BUILD AND TESTING
Before delivering:
- Compile the complete mod using Gradle.
- Test using Minecraft 1.21.11, Fabric Loader 0.18.2 and Java 21.
- Test with Sodium installed.
- Check all dependencies and native libraries.
- Fix compilation errors, crashes and missing dependencies.
- Test actual recording and video export.
- Do not provide fake buttons or unfinished placeholder features.
- Do not claim a feature works unless it has actually been implemented and tested.

## 10. FINAL DELIVERY
Provide:
1. A working compiled JAR.
2. Complete source code.
3. Installation instructions.
4. Dependency list.
5. Compatibility report.
6. Instructions for FFmpeg or other required libraries.

Build the project in stages if necessary, but prioritise a genuinely working implementation over a large incomplete project.

FINAL GOAL:

One complete Minecraft Fabric mod that combines actual live gameplay recording, a professional in-game video editor, custom UI themes, resource pack and shader management, Free Look, and ESC-menu recording controls.

The user should not need OBS, ReplayMod, Premiere Pro, or another external video editor for the core workflow.
Kodari AI
KodariOct 30 at 12:33 am 4
RewindStudio
A comprehensive Minecraft Fabric client-side mod that records live gameplay in real time, featuring an in-game video editor with multitrack timeline, custom UI themes, resource pack and shader management, and Free Look camera controls. Includes ESC menu recording controls, recording library with search and sorting, hardware-accelerated encoding, and MP4 export. Built for Minecraft 1.21.11 with Fabric Loader 0.18.2 and Java 21, optimized for low-end PCs with minimal performance impact.
  1. Create the Fabric client mod scaffold and compatibility metadata.

  2. Implement live rendered-frame capture to MP4 through an external FFmpeg executable, with start/stop controls, status, and ESC-menu buttons.

  3. Add only the library/settings UI that can be delivered without claiming the unimplemented full editor, audio capture, or pack management works.

Created a working recorder foundation, not the complete Rewind Studio spec.

  • Captures the rendered game framebuffer and sends frames asynchronously to FFmpeg for local MP4 encoding. The pause menu has recording controls; F9 toggles recording, F10 pauses/resumes, and an in-game overlay shows status, elapsed time, output FPS, and dropped frames.

  • Saves videos under run/rewind-recordings/. Configure fps (30, 60, or 120), resolution (source, 720p, or 1080p), and the FFmpeg executable in run/config/rewind-studio.properties.

  • FFmpeg is required and must be available on PATH, or set its executable path in that properties file. This implementation records video only—no audio—and uses CPU-based H.264 encoding.

  • The video editor, recording browser/import, themes, shader/resource-pack manager, and Free Look are not implemented. I have not verified runtime behavior with Minecraft or Sodium, so compatibility and recording performance are not confirmed.

To get the JAR, click Compile in Kodari, then Compile in the window that opens; after it succeeds, click Download for that build.

Kodari can make mistakes. Review important code before using.
Files
src
build.gradle
gradle.properties
settings.gradle
Code
11 708
src/client/java/com/kodari/rewindstudio/RewindStudioClient.java
package com.kodari.rewindstudio;

import net.fabricmc.api.ClientModInitializer;
import net.fabricmc.fabric.api.client.event.lifecycle.v1.ClientTickEvents;
import net.fabricmc.fabric.api.client.keybinding.v1.KeyBindingHelper;
import net.fabricmc.fabric.api.client.rendering.v1.hud.HudElementRegistry;
import net.minecraft.client.MinecraftClient;
import net.minecraft.client.option.KeyBinding;
import net.minecraft.text.Text;
import net.minecraft.util.Identifier;
import org.lwjgl.glfw.GLFW;

public final class RewindStudioClient implements ClientModInitializer {
    private static final KeyBinding.Category CATEGORY = KeyBinding.Category.create(Identifier.of("rewindstudio", "controls"));
    private static KeyBinding toggleRecording;
    private static KeyBinding togglePause;

    @Override
    public void onInitializeClient() {
        MinecraftClient client = MinecraftClient.getInstance();
        RewindRecorder.initialize(client);

        toggleRecording = KeyBindingHelper.registerKeyBinding(new KeyBinding(
                "key.rewindstudio.toggle_recording", GLFW.GLFW_KEY_F9, CATEGORY));
        togglePause = KeyBindingHelper.registerKeyBinding(new KeyBinding(
                "key.rewindstudio.toggle_pause", GLFW.GLFW_KEY_F10, CATEGORY));

        ClientTickEvents.END_CLIENT_TICK.register(tickClient -> {
            while (toggleRecording.wasPressed()) {
                RewindRecorder.toggleRecording(tickClient);
            }
            while (togglePause.wasPressed()) {
                RewindRecorder.togglePause();
            }
        });

        HudElementRegistry.addLast(Identifier.of("rewindstudio", "recorder_status"), (context, tickCounter) -> {
            String status = RewindRecorder.getHudText();
            if (!status.isEmpty()) {
                context.drawTextWithShadow(client.textRenderer, Text.literal(status), 8, 8, 0xFFFFFF);
            }
        });
    }
}