Jump to content

darthvader45

Members
  • Posts

    121
  • Joined

  • Last visited

Everything posted by darthvader45

  1. Hmm, that would be good. Is there a tutorial for this? First off, the initial waking up. Thanks to your response, I could do a check to see if the player is 10 blocks away from it, then the blue overlay comes up and it is aggro-d. Movement speed is simple enough. Then I check if the player is 6 blocks away, increases its speed, then it moves towards the player at this speed until it either hits a wall (check for collision or check if it traveled 10 blocks). This would be accompanied by a special method that translates the jaw cube downward 1 pixel to show the mouth open. The laser attack would be the hard part. How would I get it to do a sweep from left to right, centered on the player? I could have it spawn redstone particles from its mouth for 4-5 blocks, with a check to see if the player is touching the particles and have them take 2 hearts of damage plus igniting them.
  2. I'm working on making a miniboss mob based on the Minecraft Forums Temple Guardian suggestion by DINGO_WINTERWOLF. It is a golden golem that spawns in desert temples, and works as follows: It stays in place and inert until a player walks within its line of sight(within 10 blocks of it), then it activates and attacks. It will also activate if any chests within 20 blocks are opened (it will not use an overlay until it attacks, then its eyes will become blue and its inscriptions will light up). It has three main attacks: It moves towards the player very slowly, attempts to melee hit them 3 times, each time raising its arms for a moment, then slamming them down, giving the player about a half second to get away. -After that, Its jaw will drop, the Eyes Glow Red (it uses the red overlay texture for this) and it will charge the player, making a low Roar as it attacks. This sprint can only be stopped by a wall (of at LEAST 2m tall) OR if the golem has charged for a distance of 10 blocks, causing a sort of bull fighter effect. (Anything weaker than blast resistance 30 EXCEPT for sandstone/sandstone variants will be broken on impact. stones/sandstone will show damage cracks but never break from impact.) -Finally, After it has come to a stop, It will look at the player, after a few seconds will shoot a beam from its mouth in a horizontal line with the player in the midpoint, causing a sort of sweep attack from left to right. (This laser will be able to break the same blockset as the charge attack, igniting any Mob/Player in its path as well as any blocks it comes in contact with. The point of this is to clear out possible barricades the player has built around it, or used to hide.)
  3. Got it, he's not implementing the rest of his power system til the main mod features are all ironed out. So yeah, hopefully soon.
  4. So there's not a single place where one could get help with 1.7.10 modding? Sucks.
  5. Well, that kinda ruins the mood, because if 1.7.10 ain't supported here, then there's no way Ri5ux can effectively add blocks that convert from his power system to RF and back.
  6. Thing is, vanilla TE does not have solar panels.
  7. The AVP mod currently uses two different power generators, a repulsion generator that outputs 219 volts, and a solar panel that outputs 119 volts. The power lines themselves have a .1 volt per block dropoff. This mod does not have an API atm. That may be why it hasn't progressed far enough to have an energy conversion system.
  8. What methods would be necessary to convert RF into his mod's power unit? I'm not exactly sure, as this is a new area for me, so a couple examples would be nice. From what I've seen in his mod, it registers the power as V, which I assume stands for volts.
  9. Ok, then. The first two I know. I'll just ask him if he can create an API for his power system. Though that does seem like a TL:DR response.
  10. I've been looking at Ri5ux's AVP mod for some time, and noticed he is working on R2P (Redstone to Powerline) and P2R (Powerline to Redstone) converters for some time now. He intends to make it possible to convert power from his mod to RF, and I would like to help in that regard. How would I go about making a block that converts power from his mod's power system to Redstone Flux?
  11. Nvm, had a bunch of junk in the assets folder. Must've eaten all the memory trying to add stuff in that wasn't supposed to be there. Damn. Gotta remember where I download stuff.
  12. Can you give me an example of a gradle.properties file with the jvmargs line on it? I'm kinda new to creating these, because I've never created one before. Nvm, figured it out, but it still fails with the same error. Ok, now it stalls and won't continue for a few minutes unless I press enter, the resulting file is over 1GB instead of just 20 or so megs. Why?
  13. I gave it 4096M in the gradlew file as there is no gradle.properties file (I'm using Forge 1.7.10 - 10.13.4.1558).
  14. I've been recompiling my mod for a while now, but recently, have had this error upon running gradlew build: C:\Users\joshl\Downloads\Rapad Mod>gradlew build **************************** Powered By MCP: http://modcoderpack.com/ Searge, ProfMobius, Fesh0r, R4wk, ZeuX, IngisKahn, bspkrs MCP Data version : unknown **************************** :compileApiJava UP-TO-DATE :processApiResources UP-TO-DATE :apiClasses UP-TO-DATE :sourceMainJava UP-TO-DATE :compileJava UP-TO-DATE :processResources UP-TO-DATE :classes UP-TO-DATE :jar UP-TO-DATE :compileTestJava UP-TO-DATE :processTestResources UP-TO-DATE :testClasses UP-TO-DATE :test UP-TO-DATE :extractMcpData UP-TO-DATE :getVersionJson :extractUserDev UP-TO-DATE :genSrgs SKIPPED :reobf FAILED FAILURE: Build failed with an exception. * What went wrong: Execution failed for task ':reobf'. > Java heap space * Try: Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. BUILD FAILED Total time: 58.038 secs
  15. One other problem: I checked all my files for System.out.println, none have it, so it cannot be my mod files. Here's my code if you want to check it out (can't paste all my code into a spoiler, as it won't fit): Here
  16. I have a rather annoying problem. Whenever a player right-clicks with any item while my mod is installed, the console prints player right click event text, like this: [server thread/INFO] [rapadmod]: Player right click: 1xitem.netherStalkSeeds@0 - RIGHT_CLICK_AIR - false How can I prevent that from happening?
  17. Okay, so I have added an edible sugar item and it can be used to brew a swiftness potion just like vanilla sugar. However, I want to make it so that vanilla sugar cannot be used as a brewing ingredient. Is this even possible, or will I need ASM or coremodding?
  18. I recently had a major screw-up with my Forge 1.7.10 src folder, and as such had to delete it. However, no matter how many times I delete the folder and the zip it came from and redownload, re-extract, etc. it will not download the minecraft source. I know it only does it once and then doesn't need to anymore, but what happens if I delete the whole folder and want to start again?
  19. You need to add a second parameter to the if statement. Code should be like this: package mods.DennisMod.COMMON; import net.minecraft.entity.monster.EntitySkeleton; import net.minecraft.entity.passive.EntitySheep; import net.minecraft.item.Item; import net.minecraftforge.event.ForgeSubscribe; import net.minecraftforge.event.entity.living.LivingDeathEvent; import net.minecraftforge.event.entity.living.LivingDropsEvent; public class EventDropDarkBone { @ForgeSubscribe public void playerKilledWitherSkeleton(LivingDropsEvent event) { if(event.entityLiving instanceof EntitySkeleton) { if (((EntitySkeleton)event.entityLiving).getSkeletonType() == 1) { event.entityLiving.dropItem(MoGems.DarkBone.itemID, 1); } } } }
  20. Okay, some of the drops work, yet some lead to crashes; horse, ocelot and skeleton drops being the three that broke as I have found. My current CustomDropEvents code: package net.sargeant.rapad.eventhandler; import java.util.Random; import net.minecraft.entity.boss.EntityWither; import net.minecraft.entity.monster.EntityCaveSpider; import net.minecraft.entity.monster.EntityEnderman; import net.minecraft.entity.monster.EntityIronGolem; import net.minecraft.entity.monster.EntityPigZombie; import net.minecraft.entity.monster.EntitySkeleton; import net.minecraft.entity.monster.EntitySnowman; import net.minecraft.entity.monster.EntitySpider; import net.minecraft.entity.monster.EntityZombie; import net.minecraft.entity.passive.EntityBat; import net.minecraft.entity.passive.EntityCow; import net.minecraft.entity.passive.EntityHorse; import net.minecraft.entity.passive.EntityOcelot; import net.minecraft.entity.passive.EntityPig; import net.minecraft.entity.passive.EntitySheep; import net.minecraft.entity.passive.EntitySquid; import net.minecraft.entity.passive.EntityVillager; import net.minecraft.entity.passive.EntityWolf; import net.minecraft.init.Blocks; import net.minecraft.init.Items; import net.minecraft.item.ItemStack; import net.minecraftforge.event.entity.living.LivingDropsEvent; import net.sargeant.rapad.items.ModItems; import cpw.mods.fml.common.eventhandler.SubscribeEvent; public class CustomDropEvent { public static Random random; public static int dropped; public EntitySkeleton skeleton; public EntityHorse horse; public EntityOcelot cat; @SubscribeEvent public void onEntityDrop(LivingDropsEvent event) { random = new Random(); dropped = random.nextInt(2) + 1; //DO NOT CHANGE THIS if(event.entityLiving instanceof EntityHorse) { event.entityLiving.entityDropItem(new ItemStack(ModItems.horsemeatraw), dropped); if(horse.getHorseType() == 0) { event.entityLiving.entityDropItem(new ItemStack(ModItems.horsehide), dropped); } else if(horse.getHorseType() == 1) { event.entityLiving.entityDropItem(new ItemStack(ModItems.donkeyhide), dropped); } else if(horse.getHorseType() == 2) { event.entityLiving.entityDropItem(new ItemStack(ModItems.mulehide), dropped); } if (event.entityLiving.isBurning()) { event.entityLiving.entityDropItem(new ItemStack(ModItems.horsemeatcooked), dropped); } } else if(event.entityLiving instanceof EntityWolf) { event.entityLiving.entityDropItem(new ItemStack(ModItems.wolfmeatraw), dropped); if (event.entityLiving.isBurning()) { event.entityLiving.entityDropItem(new ItemStack(ModItems.wolfmeatcooked), dropped); } } else if(event.entityLiving instanceof EntityOcelot) { event.entityLiving.entityDropItem(new ItemStack(ModItems.catmeatraw), dropped); if (cat.isTamed() == false){ event.entityLiving.entityDropItem(new ItemStack(ModItems.ocelotpelt), dropped); } else if(cat.isTamed() == true){ event.entityLiving.entityDropItem(new ItemStack(ModItems.catpelt), dropped); } } if (event.entityLiving.isBurning()) { event.entityLiving.entityDropItem(new ItemStack(ModItems.catmeatcooked), dropped); } else if(event.entityLiving instanceof EntitySpider) { event.entityLiving.entityDropItem(new ItemStack(ModItems.venomsac), dropped); } else if(event.entityLiving instanceof EntitySquid) { event.entityLiving.entityDropItem(new ItemStack(ModItems.squidraw), dropped); } else if(event.entityLiving instanceof EntityBat) { event.entityLiving.entityDropItem(new ItemStack(ModItems.batraw), dropped); if (event.entityLiving.isBurning()) { event.entityLiving.entityDropItem(new ItemStack(ModItems.batcooked), dropped); } } else if(event.entityLiving instanceof EntityPig) { event.entityLiving.entityDropItem(new ItemStack(ModItems.animalfat), dropped); event.entityLiving.entityDropItem(new ItemStack(Items.bone), dropped); } else if(event.entityLiving instanceof EntitySheep) { event.entityLiving.entityDropItem(new ItemStack(ModItems.animalfat), dropped); event.entityLiving.entityDropItem(new ItemStack(Items.bone), dropped); event.entityLiving.entityDropItem(new ItemStack(ModItems.muttonraw), dropped); if (event.entity.isBurning()) { event.entityLiving.entityDropItem(new ItemStack(ModItems.muttoncooked), dropped); } } else if(event.entityLiving instanceof EntityCow) { event.entityLiving.entityDropItem(new ItemStack(ModItems.animalfat), dropped); event.entityLiving.entityDropItem(new ItemStack(Items.bone), dropped); } else if(event.entityLiving instanceof EntityVillager) { event.entityLiving.entityDropItem(new ItemStack(Items.emerald), dropped); event.entityLiving.entityDropItem(new ItemStack(Items.bread), dropped); event.entityLiving.entityDropItem(new ItemStack(Items.apple), dropped); event.entityLiving.entityDropItem(new ItemStack(Items.cooked_porkchop), dropped); event.entityLiving.entityDropItem(new ItemStack(Items.wheat), dropped); event.entityLiving.entityDropItem(new ItemStack(Items.wheat_seeds), dropped); event.entityLiving.entityDropItem(new ItemStack(Items.potato), dropped); event.entityLiving.entityDropItem(new ItemStack(Items.carrot), dropped); } else if(event.entityLiving instanceof EntityIronGolem) { event.entityLiving.entityDropItem(new ItemStack(Blocks.iron_block), dropped); event.entityLiving.entityDropItem(new ItemStack(Items.iron_ingot), dropped); event.entityLiving.entityDropItem(new ItemStack(Blocks.vine), dropped); event.entityLiving.entityDropItem(new ItemStack(Blocks.red_flower), dropped); } else if(event.entityLiving instanceof EntitySnowman) { event.entityLiving.entityDropItem(new ItemStack(Blocks.pumpkin), dropped); event.entityLiving.entityDropItem(new ItemStack(Items.snowball), dropped); } else if(event.entityLiving instanceof EntityZombie) { event.entityLiving.entityDropItem(new ItemStack(Items.bone), dropped); } else if(event.entityLiving instanceof EntitySpider | event.entityLiving instanceof EntityCaveSpider) { event.entityLiving.entityDropItem(new ItemStack(ModItems.venomsac), dropped); } else if(event.entityLiving instanceof EntityWither) { event.entityLiving.entityDropItem(new ItemStack(ModItems.witherbone), dropped); } else if(event.entityLiving instanceof EntityPigZombie) { event.entityLiving.entityDropItem(new ItemStack(ModItems.animalfat), dropped); event.entityLiving.entityDropItem(new ItemStack(ModItems.pighide), dropped); } else if(event.entityLiving instanceof EntityEnderman) { event.entityLiving.entityDropItem(new ItemStack(Items.bone), dropped); } else if(event.entityLiving instanceof EntitySkeleton && skeleton.getSkeletonType() == 1) { if (skeleton.getSkeletonType() == 1){ event.entityLiving.entityDropItem(new ItemStack(ModItems.witherbone), dropped); } else if (skeleton.getSkeletonType() != 1) { event.entityLiving.entityDropItem(new ItemStack(Items.bone), dropped); event.entityLiving.entityDropItem(new ItemStack(Items.arrow), dropped); } } } } Edit: Nvm, Draco's code worked. I was so stupid, checking a separate entity instead of casting. Sorry for being a total idiot. I'm kinda new to modifying vanilla mob drops(but NOT to coding). I do occasionally make a few noobish mistakes, but that happens to even the most experienced coders.
  21. Yeah, his explanation perfectly describes what's happening. I tried his code, and it does the same on my end. It does remove the item if it is a single item, but does the replacing when there's more than one of the item.
  22. I am currently the coder for the Realistic Animal Products and Drops Mod(http://www.minecraftforum.net/forums/mapping-and-modding/minecraft-mods/wip-mods/2389704-realistic-animal-products-and-drops-mod). I fixed my problem with the horses, but I am now having a separate small problem. How do I change sugar to be edible? I've tried overriding it, but none of the code from other problems' solutions has helped.
  23. Okay, so I type EntityHorse in, plus a period. I don't see anything in the autocomplete even mentioning said variable of getHorseType(). I'd have to type in "this" to get anywhere, and even then it says "cannot convert from int to boolean". I then try putting = 1 at the end, and the error changes to "the left-hand side of an assignment must be a variable". Edit: Found my answer in a separate topic talking about adding drops after detecting Skeleton type. Tried it with horses, and it worked. Gonna remember this from now on.
  24. Ok, ok, no need to get all wound up. I only needed confirmation. I'm only using this variable as a separate condition in an if statement. For this to work, the left hand side must be a variable, therefore the getter will not work. My code: package net.sargeant.rapad.eventhandler; import java.util.Random; import net.minecraft.entity.passive.EntityHorse; import net.minecraft.init.Items; import net.minecraft.item.ItemStack; import net.minecraftforge.event.entity.living.LivingDropsEvent; import net.sargeant.rapad.items.ModItems; import cpw.mods.fml.common.eventhandler.SubscribeEvent; public class HorseDropEvent { public static Random random; public static int dropped; @SubscribeEvent public void onEntityDrop(LivingDropsEvent event) { random = new Random(); dropped = random.nextInt(2) + 1; //DO NOT CHANGE THIS if(event.entityLiving instanceof EntityHorse ) { if (EntityHorse#getHorseType() = 1){ } } } }
×
×
  • Create New...

Important Information

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