介绍
介绍由机器翻译自 CurseForge 原页面,仅供参考。
Recipes for All 是一个小型模组,当玩家加入世界时会解锁原版配方书中的所有配方。连接到装有此模组的服务器的客户端不需要安装此模组。不过,如果你希望在单人世界中也能使用此功能,建议在客户端安装。
没有材料或没有产出的配方不会被解锁,这可以防止那些你实际上无法合成的损坏配方显示出来。
这是一个极其微小的模组,因此我没有为它托管 GitHub 仓库,而是将源代码附在下方
package com.mr208.rfa;
import com.google.common.collect.Lists;
import net.minecraft.entity.player.EntityPlayerMP;
import net.minecraft.item.crafting.CraftingManager;
import net.minecraft.item.crafting.IRecipe;
import net.minecraftforge.fml.common.Mod;
import net.minecraftforge.fml.common.Mod.EventBusSubscriber;
import net.minecraftforge.fml.common.eventhandler.SubscribeEvent;
import net.minecraftforge.fml.common.gameevent.PlayerEvent.PlayerLoggedInEvent;
import java.util.ArrayList;
@EventBusSubscriber
@Mod(modid = "rfa", name = "Recipes For All", version = "1.0.0", acceptableRemoteVersions = "*")
public class RecipesForAll
{
@SubscribeEvent
public static void onPlayerLoggin(PlayerLoggedInEvent event)
{
if(event.player instanceof EntityPlayerMP)
{
ArrayList<IRecipe> recipes = Lists.newArrayList(CraftingManager.REGISTRY);
recipes.removeIf((recipe)-> recipe.getRecipeOutput().isEmpty());
recipes.removeIf((recipe)-> recipe.getIngredients().isEmpty());
event.player.unlockRecipes(recipes);
}
}
}
常见问题
Recipes for All 支持哪些 Minecraft 版本?
Recipes for All 支持 Minecraft Java 版 1.12.2,可用的加载器:Forge。下载时注意选择和你游戏版本一致的文件。
Recipes for All 怎么安装?
先用 PCL2 或 HMCL 启动器安装对应版本的 Forge,再把下载的 .jar 文件放进游戏目录的 mods 文件夹,重新启动游戏即可。开启了版本隔离的,mods 文件夹在 versions/版本名 下面。
mallrat208 的其他作品
查看全部 →Dirt2Path [FORGE]
by mallrat208
使用铲子时,Dirt2Path 可以将泥土方块转换为土径方块。
1118万
7 年前
CurseForge
WIRED: More Augs
by mallrat208
赛博义体附属模组。
78.8万
9 年前
CurseForge
UBC Ore Registrar
by mallrat208
使用 Underground Biomes Construct 注册矿石
75.9万
8 年前
CurseForge
Equivalent Storage
by mallrat208
打通 Refined Storage 1.6 与 Project E 1.3.1B
72.1万
7 年前
CurseForge
评论
登录后评论和评分