Jump to content

Differentiation

Members
  • Posts

    606
  • Joined

  • Last visited

  • Days Won

    1

Everything posted by Differentiation

  1. Hello! I have this player capability class with boolean, int, and float values which are unique to the player. Now, when the player dies, these values reset to their default state. Is there a way to keep the state of the values when the player dies? Any suggestions are welcome. Thanks!
  2. in the addInformation method?
  3. No such method. Not what I'm looking for. Ways to move a player forward. Thanks, I'll try that!
  4. Ah! I knew it, it's about time for me to switch to a more professional software... thanks for the help!
  5. aw, that's a bummer, is there any other way to format it this way other than doing it manually? It's a pain
  6. Hey! I keep taking glances at the Referenced Libraries and the code in them and they have a style that I personally adapted, but I just space everything out myself when coding. I was wondering if there is any way to have line breaks between the beginning and end of block codes. For instance: /* Event fired when an entity dies */ @SubscribeEvent(priority = EventPriority.HIGHEST) public void onLivingDeath(LivingDeathEvent event) { if (event.getEntityLiving() instanceof EntityLiving) { EntityLiving entity = (EntityLiving) event.getEntityLiving(); entity.playSound(SoundEvents.BLOCK_METAL_BREAK, 1.0F, 1.0F); for (int i = 0; i < 50; ++i) //line break above { entity.worldObj.spawnParticle(EnumParticleTypes.BLOCK_CRACK, entity.posX, entity.posY + (entity.height - 0.25D), entity.posZ, Math.random() * 0.2D - 0.1D, Math.random() * 0.25D, Math.random() * 0.2D - 0.1D, Block.getIdFromBlock(Blocks.REDSTONE_BLOCK) ); }//line break below if (...) { ... } try { } catch(...) { ... } } } I've been trying to accomplish this for a lot of time, yet no success. Any ideas? Thanks!
  7. Thanks! I'll give it a try.
  8. Hey! So I have tried moving the player to a direction, ex. sides, forward, backward, etc. but I just couldn't find a way to make it work. Any suggestions? Thanks!
  9. A very silly mistake indeed I'm glad you figured it out. Happy modding!
  10. Show your mods folder and what Forge 1.8.9 version are you using?
  11. Cool stuff, however this Forum may soon abandon 1.8.9 so I suggest you update
  12. Sponge is very conflicting with Forge. I took it out long ago
  13. Or just send a packet to the server if this assignment is real.
  14. Get the team client-side and the rest server-side
  15. You are not calling this "function" or any method to set a team for the player in your onEntitySwing(...) method. And we do Java here, I don't know where you call or apply this function so I can't really help...
  16. I guess so.
  17. Then why is elTeam identified here?
  18. Then why isn't it working for him when world is not remote?
  19. Sorry, only setting the team in his case...
  20. ^ Where in your code do you set the team anyways?
  21. Potion effects are handled server-side, your other lines in that method (such as things like AABB) are handled in the logical client-side. Therefore, you must insert !World::isRemote when applying potion effects and World::isRemote with the AABB and setting team.
  22. I would like to see the solution if you figure it out. I myself don't have such a good experience with NBT, but I would like to see what you ended up doing. Happy New Year to you as well. Here in New York, New Year is in 5 hours!
  23. Yeah, I see that's why you used the UUID. I couldn't figure it out myself since I'm not that good at NBTs. Best of luck figuring out the solution!
×
×
  • Create New...

Important Information

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