Jump to content

___ is not a valid mod file.


Dark_what

Recommended Posts

So i wanted to edit a mod file and i did. let me walk you through everything i did.

 

1. Downloaded the mod

2. us a decompile for java

3. Extracted the zipped decompiled folder

4. made copies of a custom recipe file and edited to make my own custom recipe 

5. Saved it

6. made it a zip file

7. renamed it so it was a .jar file

 

Then it had the same look as all the other mods, the icon was a coffee looking thing.

when i loaded up forge because the mod was originally a forge mod it says its not a valid mod. 

Now keep in mind that originally the mod worked and all i did was add a extra piece and then remake it into a .jar.

before when it wasn't a .jar and it was the extracted it just crashed my Minecraft. The new .jar looked let me load up forge Minecraft but just now says its not a valid mod file. please help.

image_2021-03-23_173832.png

Edited by Dark_what
Needed to add picture
Link to comment
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now

Announcements



  • Recently Browsing

    • No registered users viewing this page.
  • Posts

    • I've been having trouble launching forge 1.19.4, i watched YouTube videos but i still don't have a solution.
    • This is my code: private void addCreative(Register<Block> event) { if (event.getTab() == CreativeModeTabs.BUILDING_BLOCKS) event.register(EXAMPLE_BLOCK); } Cannot resolve symbol 'Register'   How do I fix? I have tried the import import net.minecraftforge.registries.Register; but it doesn't work.   I also have these problems on that same code: Cannot resolve method 'getTab()' Cannot resolve method 'register(RegistryObject<Block>)'
    • my arrow wont move at all it would stay mid air and show no collision   my Entity class: package net.jeezedboi.epicraft.entity.custom; import net.jeezedboi.epicraft.init.ModItems; import net.minecraft.entity.EntityType; import net.minecraft.entity.LivingEntity; import net.minecraft.entity.projectile.AbstractArrowEntity; import net.minecraft.item.ItemStack; import net.minecraft.network.IPacket; import net.minecraft.util.math.EntityRayTraceResult; import net.minecraft.world.Explosion; import net.minecraft.world.World; import net.minecraftforge.fml.network.NetworkHooks; public class ExplosiveArrowEntity extends AbstractArrowEntity { // default constructor, required to register the entity public ExplosiveArrowEntity(EntityType<ExplosiveArrowEntity> entityType, World world) { super(entityType, world); } public ExplosiveArrowEntity(EntityType<ExplosiveArrowEntity> entityType, double x, double y, double z, World world) { super(entityType, x, y, z, world); } // the constructor used by the ArrowItem public ExplosiveArrowEntity(EntityType<ExplosiveArrowEntity> entityType, LivingEntity shooter, World world) { super(entityType, shooter, world); } // the item stack to give the player when they walk over your arrow stuck in the ground @Override protected ItemStack getArrowStack() { return new ItemStack(ModItems.EXPLOSIVE_ARROW.get()); } @Override protected void onEntityHit(EntityRayTraceResult result) { super.onEntityHit(result); // this, x, y, z, explosionStrength, setsFires, breakMode (NONE, BREAK, DESTROY) this.world.createExplosion(this, this.getPosX(), this.getPosY(), this.getPosZ(), 4.0f, true, Explosion.Mode.BREAK); } // called each tick while in the ground @Override public void tick() { if (this.timeInGround > 60){ this.world.createExplosion(this, this.getPosX(), this.getPosY(), this.getPosZ(), 4.0f, true, Explosion.Mode.BREAK); this.remove(); } } // syncs to the client @Override public IPacket<?> createSpawnPacket() { return NetworkHooks.getEntitySpawningPacket(this); } } my item class :   package net.jeezedboi.epicraft.item.custom; import net.jeezedboi.epicraft.entity.custom.ExplosiveArrowEntity; import net.jeezedboi.epicraft.init.ModEntityTypes; import net.minecraft.entity.LivingEntity; import net.minecraft.entity.projectile.AbstractArrowEntity; import net.minecraft.item.ArrowItem; import net.minecraft.item.ItemStack; import net.minecraft.world.World; public class ExplosiveArrowItem extends ArrowItem { public ExplosiveArrowItem(Properties props) { super(props); } @Override public AbstractArrowEntity createArrow(World world, ItemStack ammoStack, LivingEntity shooter) { ExplosiveArrowEntity explosiveArrowEntity = new ExplosiveArrowEntity(ModEntityTypes.EXPLOSIVE_ARROW.get(), shooter, world); return explosiveArrowEntity; } } other stuffs: public static final RegistryObject<Item> EXPLOSIVE_ARROW = ITEMS.register("explosive_arrow", () -> new ExplosiveArrowItem(new Item.Properties().group(ModItemGroup.Epic_Items))); public static final RegistryObject<EntityType<ExplosiveArrowEntity>> EXPLOSIVE_ARROW = ENTITY_TYPES.register("explosive_arrow", () -> EntityType.Builder.create((EntityType.IFactory<ExplosiveArrowEntity>) ExplosiveArrowEntity::new, EntityClassification.MISC) .size(0.5F, 0.5F).build("explosive_arrow")); mappings channel: 'snapshot', version: '20210309-1.16.5'
    • may i ask what it was that fixed it, I'm having the same problem and its frustrating because I'm making an origin.
    • I need to accesses byPath field of net.minecraft.client.renderer.texture.TextureManager. As I found out I need to use accesstransformer.cfg file and make the field public via it. In this file field names look like f_<numbers>. And I was unable to figure out, how to get those. It seems like it is connected to something called mappings (thing left after Minecraft decompile process). How can I get such a name for a class field?
  • Topics

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.