【侍ジャパン級
】プロ野球選手の「侍ジャパン級」3人が文春砲Loot Survival
Loot Survival is a mod for Minecraft designed to add new gameplay mechanics that focus on survival and scavenging resources. The mod introduces new threats, rewards, and systems that aim to make the vanilla Minecraft survival game more engaging and challenging.
The major features of the mod include:
- A new hostile mob called the Looter, which spawns in villages and scavenges for loot.
- Loot caches that can be found in the world, which contain randomized loot.
- Traps that can be placed around loot caches to protect them from Looters.
- Cooking stations that allow players to cook items in new ways to obtain more resources.
- New crafting recipes and items focused on survival and resource scarcity.
The mod is currently in active development, and new features are being added on a regular basis. The goal is to create a mod that enhances the vanilla Minecraft survival experience while introducing new gameplay challenges and rewards.
Installation
To install Loot Survival, follow these steps:
- Download the latest version of the mod from the Releases page.
- Install Forge for the appropriate Minecraft version.
- Place the Loot Survival mod file in your Minecraft mods folder.
- Launch Minecraft and select the modded profile.
Usage
Once the mod is installed, you can start a new Minecraft world or load an existing one. The new Loot Survival features will be present in the game, including Looters, loot caches, traps, and cooking stations.
Explore the world, scavenge for resources, and defend your loot from Looters. Experiment with the new crafting recipes and cooking mechanics to get the most out of your resources.
Development
If you’re interested in contributing to the development of Loot Survival, please feel free to submit issues, bug reports, or pull requests on the GitHub repository.
The mod is currently being developed using the Forge modding framework for Minecraft. The codebase is written in Java and follows Forge’s modding conventions.
License
Loot Survival is licensed under the MIT License. See the LICENSE file for more information.
Credits
Loot Survival is developed by JasonMcRay.
Special thanks to the Minecraft modding community for their support and contributions.
package com.jasonmcray.lootsurvival;
import com.jasonmcray.lootsurvival.common.CommonProxy;
import com.jasonmcray.lootsurvival.common.config.ConfigManager;
import com.jasonmcray.lootsurvival.common.init.ModBlocks;
import com.jasonmcray.lootsurvival.common.init.ModCookingRecipes;
import com.jasonmcray.lootsurvival.common.init.ModEntities;
import com.jasonmcray.lootsurvival.common.init.ModItems;
import com.jasonmcray.lootsurvival.common.init.ModPotions;
import com.jasonmcray.lootsurvival.common.init.ModWorldGen;
import com.jasonmcray.lootsurvival.common.network.NetworkHandler;
import net.minecraftforge.fml.common.Mod;
import net.minecraftforge.fml.common.Mod.EventHandler;
import net.minecraftforge.fml.common.SidedProxy;
import net.minecraftforge.fml.common.event.FMLInitializationEvent;
import net.minecraftforge.fml.common.event.FMLPostInitializationEvent;
import net.minecraftforge.fml.common.event.FMLPreInitializationEvent;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
@Mod(
modid = LootSurvival.MODID,
name = LootSurvival.NAME,
version = LootSurvival.VERSION,
acceptedMinecraftVersions = LootSurvival.ACCEPTED_MINECRAFT_VERSIONS
)
public class LootSurvival {
public static final String MODID = "lootsurvival";
public static final String NAME = "Loot Survival";
public static final String VERSION = "1.0.0";
public static final String ACCEPTED_MINECRAFT_VERSIONS = "[1.12.2]";
public static final Logger logger = LogManager.getLogger(MODID);
@SidedProxy(
clientSide = "com.jasonmcray.lootsurvival.client.ClientProxy",
serverSide = "com.jasonmcray.lootsurvival.common.CommonProxy"
)
public static CommonProxy proxy;
@EventHandler
public void preInit(FMLPreInitializationEvent event) {
ConfigManager.load(event.getSuggestedConfigurationFile());
ModBlocks.init();
ModItems.init();
ModEntities.init();
ModPotions.init();
ModWorldGen.init();
NetworkHandler.init();
proxy.preInit(event);
}
@EventHandler
public void init(FMLInitializationEvent event) {
ModCookingRecipes.init();
proxy.init(event);
}
@EventHandler
public void postInit(FMLPostInitializationEvent event) {
proxy.postInit(event);
}
}
package com.jasonmcray.lootsurvival.client;
import com.jasonmcray.lootsurvival.client.render.entity.RenderLooter;
import com.jasonmcray.lootsurvival.client.render.entity.RenderLootCache;
import com.jasonmcray.lootsurvival.client.render.entity.RenderTrap;
import com.jasonmcray.lootsurvival.client.screen.CookingStationScreen;
import com.jasonmcray.lootsurvival.common.CommonProxy;
import com.jasonmcray.lootsurvival.common.entity.EntityLooter;
import com.jasonmcray.lootsurvival.common.entity.EntityLootCache;
import com.jasonmcray.lootsurvival.common.entity.EntityTrap;
import com.jasonmcray.lootsurvival.common.init.ModBlocks;
import com.jasonmcray.lootsurvival.common.init.ModEntities;
import com.jasonmcray.lootsurvival.common.init.ModItems;
import com.jasonmcray.lootsurvival.common.init.ModPotions;
import com.jasonmcray.lootsurvival.common.network.NetworkHandler;
import net.minecraft.block.Block;
import net.minecraft.client.Minecraft;
import net.minecraft.client.renderer.ItemModelMesher;
import net.minecraft.client.renderer.RenderItem;
import net.minecraft.client.renderer.block.model.ModelResourceLocation;
import net.minecraft.client.renderer.color.IBlockColor;
import net.minecraft.client.renderer.color.IItemColor;
import net.minecraft.item.Item;
import net.minecraft.potion.Potion;
import net.minecraftforge.client.event.ColorHandlerEvent;
import net.minecraftforge.client.event.ModelRegistryEvent;
import net.minecraftforge.client.model.ModelLoader;
import net.minecraftforge.client.model.obj.OBJLoader;
import net.minecraftforge.fml.client.registry.ClientRegistry;
import net.minecraftforge.fml.client.registry.RenderingRegistry;
import net.minecraftforge.fml.common.Mod;
import net.minecraftforge.fml.common.event.FMLInitializationEvent;
import net.minecraftforge.fml.common.event.FMLPreInitializationEvent;
import net.minecraftforge.fml.common.eventhandler.SubscribeEvent;
import net.minecraftforge.fml.relauncher.Side;
import net.minecraftforge.fml.relauncher.SideOnly;
@Mod.EventBusSubscriber(modid = "lootsurvival", value = Side.CLIENT)
public class ClientProxy extends CommonProxy {
@Override
public void preInit(FMLPreInitializationEvent event) {
super.preInit(event);
OBJLoader.INSTANCE.addDomain("lootsurvival");
}
@Override
public void init(FMLInitializationEvent event) {
super.init(event);
registerBlockRenders();
registerItemRenders();
registerEntityRenders();
registerGuiScreens();
registerPotionColor();
}
private void registerBlockRenders() {
for (Block block : ModBlocks.blocks) {
registerBlockRender(block);
}
}
private void registerItemRenders() {
for (Item item : ModItems.items) {
registerItemRender(item);
}
}
private void registerEntityRenders() {
RenderingRegistry.registerEntityRenderingHandler(EntityLooter.class, RenderLooter::new);
RenderingRegistry.registerEntityRenderingHandler(EntityLootCache.class, RenderLootCache::new);
RenderingRegistry.registerEntityRenderingHandler(EntityTrap.class, RenderTrap::new);
}
private void registerGuiScreens() {
ClientRegistry.bindTileEntitySpecialRenderer(ModBlocks.cookingStation, new CookingStationScreen());
}
private void registerPotionColor() {
Minecraft.getMinecraft().getItemColors().registerItemColorHandler(ModPotions::getPotionColor, ModPotions.POISONED_POTION);
}
private void registerBlockRender(Block block) {
ModelLoader.setCustomModelResourceLocation(Item.getItemFromBlock(block), 0, new ModelResourceLocation(block.getRegistryName(), "inventory"));
}
private void registerItemRender(Item item) {
ModelLoader.setCustomModelResourceLocation(item, 0, new ModelResourceLocation(item.getRegistryName(), "inventory"));
}
@SubscribeEvent
public static void registerModels(ModelRegistryEvent event) {
NetworkHandler.registerMessages();
}
@SubscribeEvent
public static void registerBlockColors(ColorHandlerEvent.Block event) {
IBlockColor blockColorHandler = (state, worldIn, pos, tintIndex) -> {
Block block = state.getBlock();
if (block == ModBlocks.cookingStation) {
return 0xFFFFFF;
}
return 0xFFFFFF;
};
event.getBlockColors().registerBlockColorHandler(blockColorHandler, ModBlocks.cookingStation);
}
@SubscribeEvent
public static void registerItemColors(ColorHandlerEvent.Item event) {
IItemColor itemColorHandler = (stack, tintIndex) -> {
Item item = stack.getItem();
if (item == ModItems.POISONED_POTION) {
return ModPotions.getPotionColor(stack);
}
return 0xFFFFFF;
};
event.getItemColors().registerItemColorHandler(itemColorHandler, ModItems.POISONED_POTION);
}
}
JasonMcRay/Loot-Survival
package com.jasonmcray.lootsurvival.client.model.entity;
import com.jasonmcray.lootsurvival.common.entity.EntityLooter;
import net.minecraft.client.model.ModelBiped;
import net.minecraft.client.model.ModelRenderer;
import net.minecraft.entity.Entity;
import net.minecraft.entity.EntityLivingBase;
import net.minecraft.util.math.MathHelper;
public class ModelLooter extends ModelBiped {
public ModelRenderer rightArm;
public ModelRenderer leftArm;
public ModelRenderer rightLeg;
public ModelRenderer leftLeg;
public ModelRenderer head;
public ModelRenderer body;
public ModelLooter() {
this.textureWidth = 64;
this.textureHeight = 64;
this.head = new ModelRenderer(this, 0, 0);
this.head.addBox(-4.0F, -8.0F, -4.0F, 8, 8, 8);
this.head.setRotationPoint(0.0F, 0.0F, 0.0F);
this.body = new ModelRenderer(this, 16, 16);
this.body.addBox(-4.0F, 0.0F, -2.0F, 8, 12, 4);
this.body.setRotationPoint(0.0F, 0.0F, 0.0F);
this.rightArm = new ModelRenderer(this, 40, 16);
this.rightArm.addBox(-3.0F, -2.0F, -2.0F, 4, 12, 4);
this.rightArm.setRotationPoint(-5.0F, 2.0F, 0.0F);
this.leftArm = new ModelRenderer(this, 40, 16);
this.leftArm.mirror = true;
this.leftArm.addBox(-1.0F, -2.0F, -2.0F, 4, 12, 4);
this.leftArm.setRotationPoint(5.0F, 2.0F, 0.0F);
this.rightLeg = new ModelRenderer(this, 0, 16);
this.rightLeg.addBox(-2.0F, 0.0F, -2.0F, 4, 12, 4);
this.rightLeg.setRotationPoint(-1.9F, 12.0F, 0.0F);
this.leftLeg = new ModelRenderer(this, 0, 16);
this.leftLeg.mirror = true;
this.leftLeg.addBox(-2.0F, 0.0F, -2.0F, 4, 12, 4);
this.leftLeg.setRotationPoint(1.9F, 12.0F, 0.0F);
}
@Override
public void render(Entity entityIn, float limbSwing, float limbSwingAmount, float ageInTicks, float netHeadYaw, float headPitch, float scale) {
this.setRotationAngles(limbSwing, limbSwingAmount, ageInTicks, netHeadYaw, headPitch, scale, entityIn);
this.head.render(scale);
this.body.render(scale);
this.rightArm.render(scale);
this.leftArm.render(scale);
this.rightLeg.render(scale);
this.leftLeg.render(scale);
}
@Override
public void setRotationAngles(float limbSwing, float limbSwingAmount, float ageInTicks, float netHeadYaw, float headPitch, float scaleFactor, Entity entityIn) {
super.setRotationAngles(limbSwing, limbSwingAmount, ageInTicks, netHeadYaw, headPitch, scaleFactor, entityIn);
EntityLooter looter = (EntityLooter) entityIn;
this.rightArm.rotateAngleX = MathHelper.cos(limbSwing * 0.6662F + (float) Math.PI) * 2.0F * limbSwingAmount * 0.5F;
this.leftArm.rotateAngleX = MathHelper.cos(limbSwing * 0.6662F) * 2.0F * limbSwingAmount * 0.5F;