Jump to content
Search In
  • More options...
Find results that contain...
Find results in...


  • Posts

  • Joined

  • Last visited


  • Gender
  • Personal Text
    I am new!

Recent Profile Visitors

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

ciroreed's Achievements

Tree Puncher

Tree Puncher (2/8)



  1. Hello im using the latest version of forge and im trying to give an effect to the player that sort of emulates elytra flight. Kind of gliding. Is there a way to do this? Im pretty new at modding but I kinda think it would be something like subscribing to onPlayerEntityUpdate, then checking if that player has that effect, next reduce falling speed? ... Thanks!
  2. sorry but the word "tick" isn't found in the whole document. No clues for delaying events or something.
  3. world.spawnEntity(new Entity() { @Override onUpdate() { } }); i don't have any idea what im doing xd
  4. with my "threadish" approach the explosion occurs, damages blocks, etc, but when harms any entity the game crashes. Im not pushing this solution forward, it just seems more obvious to me bcoz im a rockie at modding
  5. sounds good but i don't know how to do it. Is there a way to subscribe to ticks, so i can count
  6. I don't have any idea. Im pretty new at modding. I just learned how to post events. I understand that all operations should be performed on the main thread but I don't know where I can "count ticks"
  7. Im able to make it work unless the explosion interacts with an entity lmao: as diesieben said: by running stuff outside the main thread I get concurrentModificationException. Now, rather than performing the action at the moment the runnable triggered im doing this: Timeout.run(() -> MinecraftForge.EVENT_BUS.post(new DelayedSpellEvent(player, world, spell, vec)), 1000); So im emiting an event from outside the main thread and it works!!! unless the explosion harms any entity XD Yup, casting and then, after a second, an explosion raises where u just casted
  8. how do i do that? is there any meaningful guide thanks
  9. static void setTimeout(Runnable runnable, int delay){ new Thread(() -> { try { Thread.sleep(delay); runnable.run(); } catch (Exception e){ System.err.println(e); } }).start(); } @Override protected void castSpell(World world, EntityPlayer player, BasicWand wand) { double x = player.posX; double y = player.posY; double z = player.posZ; setTimeout(() -> world.newExplosion(player, x, y, z, 10.0F, true, true), 1000); } by executing this piece of code I get an error:java.util.ConcurrentModificationException: null Im just looking for triggering an explosion where the player was standing a second ago. thanks
  10. thanks for the reply I need to render specific item variant having item's internal data, as you said NBT. I guess I found the answer here: https://github.com/TheGreyGhost/MinecraftByExample/blob/1-12-2-final/src/main/java/minecraftbyexample/mbe11_item_variants/ItemVariants.java great resource tbh
  11. I have a vague knowledge regarding item rendering. I need to render an item by layers. 0 - basic layer 1 - basic + one layer 2 - basic + one + layers and so forth. I recall metadata was meant to do so, im I right? is there any resources regarding how metadata is used? Thanks!
  12. Okay, thanks! im not asking about 1.12 specifically. My questions are mostly about forge concepts. I have both documentations opened and I can make my way. 1.16 answers will help me anyways
  13. I ask here expecting to receive some advice, like the name of the interfaces involved on this process. Thanks. DyeUtils? or rather.. EnumDyeColor?
  14. context: It is posible to create new color instances in order to dye armor? So im looking for creating new dyes (harder to achieve) which cannot be emulated by mixing vanilla dyes. Like exclusive ones. And give some effects for the armor. This is the concept: - u get a drop from a mob or elsewhere - that item is a dye, that can dye armor (and whool?) - that color applies a color code which isn't found here https://minecraft.gamepedia.com/File:DyeGraph2.png - that dyed leather armor has several effects which apply when the wearer gets attacked (by checking if dyed color matches)
  15. My use case is the following. In order to use an item I have to check that the player is wearing a (dyed) blue leather armor ok, this can be closed. Just to share it: @Override public ActionResult<ItemStack> onItemRightClick(World world, EntityPlayer player, EnumHand hand){ if(world.isRemote) return super.onItemRightClick(world, player, hand); ItemStack itemStackBoots = player.getItemStackFromSlot(EntityEquipmentSlot.FEET); if(itemStackBoots.isEmpty()) return super.onItemRightClick(world, player, hand); int colorValue = itemStackBoots.getTagCompound().getCompoundTag("display").getInteger("color"); for (EnumDyeColor color : EnumDyeColor.values()) { if(colorValue == color.getColorValue()) { out.println(color.getName()); } } return super.onItemRightClick(world, player, hand); }
  • Create New...

Important Information

By using this site, you agree to our Privacy Policy.