Jump to content

Rosy162

Members
  • Posts

    8
  • Joined

  • Last visited

Converted

  • Gender
    Female
  • Personal Text
    have no idea what im doing .___.

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

Rosy162's Achievements

Tree Puncher

Tree Puncher (2/8)

0

Reputation

  1. im running gradlew eclipse in the gradle tasks section of run configurations in eclipse
  2. Oh right sorry, left a part out. heres the full thing. > Task :eclipseJdtApt FAILED FAILURE: Build failed with an exception *What went wrong: A problem was found with the configuration of task 'eclipseJdtApt' (type 'MixinEclipse.EclipseJdtAptTask). >File 'C:\Code\Minecraft\nm\build\createMcpToSrg\output.tsrg' specified for property 'mappingsIn' does not exist *Try: Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights. *Get more help at httpls://help.gradle.org Deprecated Gradle features were used in this build, making it incompatable with Gradle 7.0. Use 'warning-mode all' to show the individual deprecation warnings. See https://docs.gradle.org/6.8.3/userguide/command_line_interface.html#sec:command_line_warnings BUILD FAILED in 40s 11 actionable tasks: 6 executed, 5 up-to-date
  3. *What went wrong: A problem was found with the configuration of task 'eclipseJdtApt' (type 'MixinEclipse.EclipseJdtAptTask). >File 'C:\Code\Minecraft\nm\build\createMcpToSrg\output.tsrg' specified for property 'mappingsIn' does not exist
  4. when trying to run "gradlew eclipse" I get the error "specified for property 'mappingsIn' does not exist". idk if you help with this kind of stuff but help would be appreciated here is my build.gradle buildscript { repositories { maven { url = "https://files.minecraftforge.net/maven" } maven { url = "https://repo.spongepowered.org/repository/maven-public/" } mavenCentral() } dependencies { classpath group: "net.minecraftforge.gradle", name: "ForgeGradle", version: "4.1.+", changing: true classpath group: "org.spongepowered", name: "mixingradle", version: "0.7-SNAPSHOT" } } apply plugin: 'net.minecraftforge.gradle' apply plugin: 'eclipse' apply plugin: 'maven-publish' apply plugin: "org.spongepowered.mixin" mixin { add sourceSets.main, project.modId + ".refmap.json" } version = "${project.minecraftVersion}-${project.modVersion}" group = 'com.bunchofroses.' + project.modId archivesBaseName = project.modId sourceCompatibility = targetCompatibility = compileJava.sourceCompatibility = compileJava.targetCompatibility = "1.8" minecraft { mappings channel: project.mappingsChannel, version: project.mappingsVersion accessTransformer = file('src/main/resources/META-INF/accesstransformer.cfg') runs { client { workingDirectory project.file('run') property 'forge.logging.markers', 'SCAN,REGISTRIES,REGISTRYDUMP' property 'forge.logging.console.level', 'debug' property "mixin.env.disableRefMap", "true" arg "-mixin.config=" + project.modId + ".mixins.json" mods { natures_mobs { source sourceSets.main } } } server { workingDirectory project.file("run") property "forge.logging.markers", "SCAN,REGISTRIES,REGISTRYDUMP" property "forge.logging.console.level", "debug" property "mixin.env.disableRefMap", "true" arg "-mixin.config=" + project.modId + ".mixins.json" mods { natures_mobs { source sourceSets.main } } } data { workingDirectory project.file('run') property "forge.logging.markers", "SCAN,REGISTRIES,REGISTRYDUMP" property "forge.logging.console.level", "debug" property "mixin.env.disableRefMap", "true" args "--mod", project.modId, "--all", "--output", file("src/generated/resources/"), "--existing", file("src/main/resources") mods { natures_mobs { source sourceSets.main } } } } } dependencies { minecraft "net.minecraftforge:forge:${project.minecraftVersion}-${project.forgeVersion}" implementation fg.deobf("com.minecraftabnormals:abnormals-core:${project.minecraftVersion}-${project.abnormalsCore}") compileOnly fg.deobf("mezz.jei:jei-${project.minecraft}:${project.jei}:api") runtimeOnly fg.deobf("mezz.jei:jei-${project.minecraft}:${project.jei}") } repositories { maven { url "https://maven.jaackson.me" } maven { url "https://dvs1.progwml6.com/files/maven/" } maven { url "https://modmaven.k-4u.nl" } } jar { manifest { attributes([ "Specification-Title" : project.modName, "Specification-Vendor" : "Bunch of Roses", "Specification-Version" : "1", "Implementation-Title" : project.modName, "Implementation-Version" : project.modVersion, "Implementation-Vendor" : "Bunch of Roses", "Implementation-Timestamp" : new Date().format("yyyy-MM-dd'T'HH:mm:ssZ"), "MixinConfigs" : project.modId + ".mixins.json" ]) } } and my gradle.proprties : org.gradle.jvmargs=-Xmx4G org.gradle.daemon=false org.gradle.caching=true org.gradle.parallel=true gradle.cache.push=false modId=natures_mobs modName=Nature's Mobs modVersion=1.0.0 minecraftVersion=1.16.5 forgeVersion=36.1.0 abnormalsCore=3.1.1 jei=7.6.1.75 mappingsVersion=20201028-1.16.3 mappingsChannel=snapshot
  5. i got it working thank u :^))
  6. how do i get the entity that a player is looking at? idk how to do it .-.
  7. ok so i have a very specific issue that i dont know how to solve. im trying to make a mod which uses the baubles api that allows you to place the elytra in the baubles (body) slot. ive got pretty much everything to work but in EntityLivingBase, the method updateElytra() is checking if the chestplate slot has the elytra and if it doesnt it sets the player.isElytraFlying() method to false, regardless of if you are actually flying with the elytra. this is causing issues minecraft uses this method to decide when to calculate the elytra damage and so on... when im flying with the elytra in the baubles slot, player.isElytraFlying() is returning true and false repeatedly because of this method. i need it to always return true when you are flying but idk how to do that. hopefully someone smarter than me can help .-. sorry if im being stupid. here is the code for my custom elytra item: @Mod.EventBusSubscriber public class BaubleItemElytra extends ItemElytra implements IBauble { private static boolean render = true; public Method setFlagMethod; public BaubleItemElytra() { super(); this.setUnlocalizedName("elytra"); try { // this method is what is used to make the player fly, it is private so i get it here ._. try { setFlagMethod = Entity.class.getDeclaredMethod("setFlag", int.class, boolean.class); } catch (Exception e) { setFlagMethod = Entity.class.getDeclaredMethod("func_70052_a", int.class, boolean.class); } setFlagMethod.setAccessible(true); } catch (NoSuchMethodException e) {} } @Override public BaubleType getBaubleType(ItemStack stack) { return BaubleType.BODY; } //register item @SubscribeEvent public static void register(RegistryEvent.Register<Item> event) { event.getRegistry().register((new BaubleItemElytra().setRegistryName("minecraft", "elytra"))); } //registers the elytra render once, //BaubleLayerElytra is just the same as the vanilla LayerElytra but it checks for the bauble slot @SubscribeEvent public static void onPlayerRender(RenderPlayerEvent.Pre event) { if (render) { event.getRenderer().addLayer(new BaubleLayerElytra(event.getRenderer())); render = false; } } //cant equip if you have elytra equipped already @Override public boolean canEquip(ItemStack itemstack, EntityLivingBase player) { return !slotHasElytra((EntityPlayer)player); } @Override public void onEquipped(ItemStack itemstack, EntityLivingBase player) { player.playSound(SoundEvents.ITEM_ARMOR_EQIIP_ELYTRA, .75F, 1.9f); //chatMessage(player, "equipped"); } @Override public void onUnequipped(ItemStack itemstack, EntityLivingBase player) { //chatMessage(player, "unequipped"); setFlying(player, false); player.playSound(SoundEvents.ITEM_ARMOR_EQIIP_ELYTRA, .75F, 1.8f); } public static boolean slotHasElytra(EntityPlayer player) { return player.getItemStackFromSlot(EntityEquipmentSlot.CHEST).getItem() instanceof ItemElytra; } @Override public void onWornTick(ItemStack itemstack, EntityLivingBase player) { //unequips elytra in bauble if elytra is in chestplate slot if (slotHasElytra((EntityPlayer)player)) { ((EntityPlayer)player).addItemStackToInventory(itemstack.copy()); BaublesApi.getBaublesHandler((EntityPlayer)player).setStackInSlot(5, ItemStack.EMPTY);; } boolean flag = player.isElytraFlying(); //chatMessage(player, "check flying:" + player.isElytraFlying()); if (flag && !player.onGround && !player.isRiding() && isUsable(itemstack)) { flag = true; if ((player.getTicksElytraFlying() + 1) % 20 == 0) { //itemstack.damageItem(1, player); } } else { flag = false; //if you press jump in the right conditions you fly if (Minecraft.getMinecraft().gameSettings.keyBindJump.isPressed() && !player.isElytraFlying() && isUsable(itemstack) && player.motionY < 0.0D && !player.isInLava() && !player.isInWater() && !player.onGround) { flag = true; } } if (flag != player.isElytraFlying()) { setFlying(player, flag); //chatMessage(player, "flying set to: " + flag); } } //sets the player to the flying state public void setFlying(EntityLivingBase player, boolean fly) { try { setFlagMethod.invoke(player, 7, fly); } catch (Exception e) {} } private void chatMessage(EntityLivingBase player, String text) { ((EntityPlayer)player).sendMessage(new TextComponentString(text)); } //right clicking puts it in the bauble body slot if its empty, if its full it puts it in the chestplate @Override public ActionResult<ItemStack> onItemRightClick(World world, EntityPlayer player, EnumHand hand) { player.playSound(SoundEvents.ITEM_ARMOR_EQIIP_ELYTRA, .75F, 1.9f); if (!world.isRemote) { IBaublesItemHandler baubles = BaublesApi.getBaublesHandler(player); ItemStack stack = baubles.getStackInSlot(5); if ((stack == null || stack.isEmpty()) && baubles.isItemValidForSlot(5, player.getHeldItem(hand), player)) { baubles.setStackInSlot(5, player.getHeldItem(hand).copy()); if (!player.capabilities.isCreativeMode) { player.inventory.setInventorySlotContents(player.inventory.currentItem, ItemStack.EMPTY); } //onEquipped(player.getHeldItem(hand), player); } else { super.onItemRightClick(world, player, hand); } } return new ActionResult<ItemStack>(EnumActionResult.SUCCESS, player.getHeldItem(hand)); } }
×
×
  • Create New...

Important Information

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