Skip to content

Instantly share code, notes, and snippets.

01: One Way: The Elevator

📝 One Way: The Elevator is a creative point-and-click game developed by CottonGame.
You need to find a blue sphere in each scene to power an elevator to travel upward.

Mirrors Platform
Google Play Android
App Store iOS
Steam Store Windows & Mac
@Densamisten
Densamisten / PlayerIsTyping.java
Last active March 24, 2024 20:20 — forked from Ensamisten/PlayerIsTyping.java
A Mixin in Java for Fabric (Minecraft 1.20.1) which prints "Player is typing: <output>" each time a letter is written manually in the chat box.
package io.github.densamisten.mixin.client;
import net.minecraft.client.MinecraftClient;
import net.minecraft.client.gui.widget.TextFieldWidget;
import net.minecraft.text.Text;
import org.spongepowered.asm.mixin.Mixin;
import org.spongepowered.asm.mixin.Unique;
import org.spongepowered.asm.mixin.injection.At;
import org.spongepowered.asm.mixin.injection.Inject;
import org.spongepowered.asm.mixin.injection.callback.CallbackInfo;
@Densamisten
Densamisten / FmlCommand.java
Last active May 2, 2024 14:45 — forked from Ensamisten/FMLCommand.java
FMLCommand. Downloads mdk, installer, or changelog from MinecraftForge's official maven repository. /fml <mcVersion> <mdkVersion> <mdk|installer|changelog> e.g /fml 1.20.1 47.2.0 installer. Default directory is at .minecraft/downloads
package io.github.densamisten.bookutility.command;
import com.mojang.brigadier.CommandDispatcher;
import com.mojang.brigadier.arguments.StringArgumentType;
import com.mojang.brigadier.context.CommandContext;
import com.mojang.brigadier.suggestion.Suggestions;
import com.mojang.brigadier.suggestion.SuggestionsBuilder;
import net.minecraft.commands.CommandSourceStack;
import net.minecraft.commands.Commands;
import net.minecraft.network.chat.Component;
@Densamisten
Densamisten / FireworkCommand.java
Last active March 17, 2024 20:23 — forked from Ensamisten/FireworkCommand.java
FireworkCommand. (Tested for Forge in Minecraft: 1,18-1.20.4). The mixin allows for firework to pass through blocks sometimes. Usage: /firework
package io.github.ensamisten.fireworkmod;
import com.mojang.brigadier.Command;
import com.mojang.brigadier.CommandDispatcher;
import com.mojang.brigadier.arguments.IntegerArgumentType;
import com.mojang.brigadier.context.CommandContext;
import io.github.ensamisten.forgient.mixin.FireworkRocketEntityMixin;
import net.minecraft.commands.CommandSourceStack;
import net.minecraft.commands.Commands;
import net.minecraft.commands.arguments.EntityArgument;
@Densamisten
Densamisten / AurCommand.java
Last active February 18, 2024 05:04 — forked from Ensamisten/AurCommand.java
AurCommand. Usage: /aur search <package> <value>
package io.github.ensamisten.forgient.client.command;
import com.google.gson.Gson;
import com.mojang.brigadier.CommandDispatcher;
import com.mojang.brigadier.arguments.StringArgumentType;
import com.mojang.brigadier.context.CommandContext;
import com.mojang.brigadier.exceptions.CommandSyntaxException;
import net.minecraft.commands.CommandSourceStack;
import net.minecraft.commands.Commands;
import net.minecraft.nbt.CompoundTag;
@Densamisten
Densamisten / FabrientBookCommand.java
Last active March 23, 2024 11:18 — forked from Ensamisten/WriteBookCommand.java
Usage: Get a Book and Quill and send the command to the chat: /book write, or /book read. Works in Fabric and Forge 1.20.4
package io.github.densamisten.command;
import com.mojang.brigadier.CommandDispatcher;
import com.mojang.brigadier.context.CommandContext;
import net.minecraft.client.util.Clipboard;
import net.minecraft.entity.player.PlayerEntity;
import net.minecraft.item.ItemStack;
import net.minecraft.item.Items;
import net.minecraft.nbt.NbtCompound;
import net.minecraft.nbt.NbtList;
@Densamisten
Densamisten / PingCommand1.java
Last active February 3, 2024 04:22 — forked from Ensamisten/PingCommand1.java
PingCommand. Usage: /ping <ip>
@Override
public void onInitializeClient() {
FabrientRegistries.registerModStuffs();
DebugArmorSetup.registerFabrientItems();
CommandRegistrationCallback.EVENT.register((dispatcher, registryAccess, environment) -> {
dispatcher.register(
CommandManager.literal("ping")
.then(CommandManager.argument("ip", StringArgumentType.word())
.executes(context -> {
String ipAddress = StringArgumentType.getString(context, "ip");