Jump to content
View in the app

A better way to browse. Learn more.

Forge Forums

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Failender

Forge Modder
  • Joined

  • Last visited

Everything posted by Failender

  1. show ur attempts, ask specific questions
  2. To answer your question, yes should be possible.
  3. u will need to find the surface block, I am not sure if vanilla has a method for that, or if u need to iterate over the blocks in the world until u find a grass block. after that add 1 to the y pos and u are above the grass
  4. and what would neutral do? nothing? EDIT: Take a look at the Redstone class. There is a lot of things to read that might already solve ur questions
  5. seems like my answer got cut. sorry. public ItemStack onItemRightClick(ItemStack Item, World world, EntityPlayer player) { if(!world.isRemote) { doWorldChangesHere(); } show the crash log, should not be happening.
  6. Specifiy please. u mean a cable with negative redstone power?
  7. U can access the actual open container of the player by player.openContainer. Which means u can use a PlayerTickEvent, iterate through the items of the open container, check the nbt tags, and after that dance to some music.
  8. Alright. I know that I am missing something totally dumb. I want to know something custom above the food icons of the player. I know that I need to scale my rendering. But I am to dumb to get the math right now. The y pos is always correct, the x pos gets messed up by changing the size of minecraft. Any help is appreciated. Greetz Failender @SubscribeEvent public void renderGui(RenderGameOverlayEvent event) { if(event.type==ElementType.ALL) { GL11.glColor4f(1.0F, 1.0F, 1.0F, 1.0F); GL11.glDisable(GL11.GL_LIGHTING); ExtendedPlayer ext = ExtendedPlayer.get(Minecraft.getMinecraft().thePlayer); Minecraft.getMinecraft().getTextureManager().bindTexture(schild); int xPos = event.resolution.getScaledWidth()-205; int yPos = event.resolution.getScaledHeight()-48; float percentage = (float)ext.getCurrentShield()/ext.getMaxShield(); drawTexturedModalRect(xPos, yPos, 0, 0, 16, 16); } }
  9. best way to find out if u are on server or client side are world objects. world.isRemote tells u that. world.isRemote=> client !world.isRemote =>server. void onItemRightClick(tons of arguments including world object) {
  10. this copypasted code is obfuscated. I guess ur dev environment is deobfuscated. which means that you need to find the deobfuscated fields names.
  11. show how u call the method. i bet u are calling it on client side, which is wrong. u need to call it on server side.
  12. nothing to add.
  13. u can save the time of creation/ the expire data in the items nbt and validate that every time u want do so. so u know "this steak was created 100 ticks ago" and if the steak is 200 ticks old make it to rotten flesh or sth like that
  14. more information please. which method are u talking about? which class?
  15. normally if synchronized right vanilla will do that for you. I am not sure if they pull the information from openContainer or inventory. But they should be rendering the stuff they find inside that.
  16. Alright. I will tell you what I know, but as I said I abandoned this try because I wasnt able to fix all problems occuring. The player has two instances of his inventory. Player#inventory Player#openContainer Overriding these two is the first step of chaning the player inventory. If you do that u wont have a need to interrupt the keys, because they will fetch the data from the overwritten instances.
  17. should work since ur gui isnt doing anything on server side. just send a packet for selecting the weapon
  18. http://4.bp.blogspot.com/-YqRh7hhBj1M/T-yojv9_gNI/AAAAAAAAAlQ/Q_feMuGM2js/s1600/wat+duck.jpg[/img]
  19. Hmm I might be wrong there. If u are able to find out where the player gets knockbacked (from attacks etc) u will find ur solution for sure
  20. use the id of the entity, they are synced between server and client.
  21. u need to use the PlayerInteractEvent, like u did earlier not create a PlayerInteractEvent.
  22. dont message the client about its motion. set it on the server, just like u have done for everythign else then player
  23. U should try fixxing problems urself instead of asking for help if u cant find the problem in ten minutes
  24. well. I know that if I wont answer u for half an hour u will have it fixxed :'D

Important Information

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

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.