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.

delpi

Forge Modder
  • Joined

  • Last visited

Everything posted by delpi

  1. I haven't done it this way,but I traced out the code and I think it will work. You will have to test it out. If a block is in the players hand and you want to deny them the ability to place it, set the result of the event to false or: "event.useItem = Result.DENY;" Don't cancel the event. That should block placement of the block only but allow the GUI to open.
  2. Use the following ItemStack itemstack = player.inventory.getCurrentItem(); you will need to do a null check though. Your statements about client/server appear to be wrong. Probably a Syntax Statement. Why are you using BlockID? I can't tell what you are asking " I also wonder about how you exclude all items and blocks who can be used to place blocks, could you point me to the methods you got in mind to implement this? " Try saying it a different way. There are no items used to place blocks. All Blocks are used to place blocks.
  3. Your enList is in the item? How is that going to work. You need to store the list in the itemstack.
  4. Just watched your video. The only thing you show is the shift click problem. If you drag the inventory with the cursor and drop it in place, does it work?
  5. With the cat thing, does that mean you didn't get the PM?
  6. If you were just doing this with a custom block then you could just program it in the block itself. However that does not seem to be the case. You will need to check the event to see what was clicked and what was in hand and decide based upon areas. Its not that hard. Maybe 6 lines of code and you are done. You will need to have your areas defined somehow. That could be a bit more invovled.
  7. What you want to do is very doable, including animation. Its not that hard, but finding the right words to search for can be. Look at some of Jabelar's stuff as well. Its for entities mostly, but the concept for rotation and setup will help you enormously. If you want to venture outside of the normal 4 armor slots, now you are getting a bit more exotic. I can help you with that if it comes to it, but for the basic 4 you should be good with the tutorials and Jabelar's stuff.
  8. Think about it a bit. You know the player involved. Hint - look for what is in his hand. As far as what you are trying to do, its a little unclear. You want to place a block by right clicking it like normal or you want multiple blocks to be placed. No need to do this from events, do it from your custom block. I doubt that is what you are meaning though. Explain more.
  9. OMG, now the buttons work after I sent it the ugly way. Oh the humanity. You should have something in your inbox.
  10. Ok, this is probably a dumb question. How do you get the stupid buttons on a post to work? All of a sudden I can't use the insert picture, spoiler, ect buttons. Makes it really hard to send a PM that won't be annoying as hell.
  11. It could. Do you want me to PM you some of my working stuff?
  12. What I meant by what the graphics does is I'm trying to verify you have the graphics and your code aligned correctly.
  13. That really sounds like the one theory I had. I don't think you have the graphics and the slots lined up. When you made your graphic, which minecraft graphic did you start with? Did you delete the 'extra' space around the sides?
  14. Not with the standard setup. You could watch on some basis for the first two achievements to be true or whatever pattern you want and then just grant the one you are interested in.
  15. You have a mistake in the following line. achMicrochip = new Achievement("achievement.microchip", "microchip", 0, 0, Microchip, AchievementList.acquireIron).registerStat(); Replce "AcheivementList.acquireIron" with null. Copy/Paste has struck again.
  16. Create IExtendedEntityProperties for your players and set it to load with a construct event. Create a custom playerInventory implimenting IIventory. Create the saves/loads for this custom inventory in your new properties. Now for the hard part - Create a graphical interface to get to the inventory. If you just want the inventory there to be able to set it with your mod and such no need. If any of the above doe not make sense to you, or you fail to search and find how to do them, Abandon the effort until you can.
  17. Sorry to hear you are still having trouble. I ended up going to sleep last night early. What is your latest code?
  18. This is really strange I created a custom particle using a custom texture. When you do this, you utilize FXLayer 3 just like TNT. When I change my view to 3rd person looking at my front there are no particles. In 3rd person from behind me or 1st person there are just fine. So, I thought surely I screwed something up, so I looked at the explosion from TNT. It does the exact same thing. Looking at the Tessellator Code and the Effect render code, i'm not seeing where anything looked at point of view. Anybody else had this issue?
  19. I'll post an example of something recent when I get home. I've looked through your stuff and I don't see anything 'wrong'. But its hard to spot.
  20. Some of you are handling where the invenotry is at is going to have issues for saving, but that would cause an issue the next time you open it, not stopping you from clicking on it. Ok, one other thing, are you sure your graphics and your container are lined up right? When you mouse over the item image, doest it color whitish? have you tried clicking aroudn the screen and seeing if you magically pick up the item from somwether the item isn't? I've done that before.
  21. "No...I don't override it in client proxy. I'll change that and the init bit." Hope I didn't mislead, was making sure you were not overriding. As long as you extend your common to client and don't override, that should be fine. I'm going to go back and re-read your stuff in depth and see if I can spot something I missed last time. In the meanwhile, you might add some preint statements to your custom slot to see when it is called and what it thinks it has in it at the time. That should be revealing.
  22. I've never liked that method of doing this using your Common/Client Proxies, but it is a coding style thing. I'm assuming in your client proxy, you are not overriding your get GUI elements. As far as the Pre-Init or Init, I don't think it matters, but move it and see what happens. Lastly, how are you opening the GUI? Exact details. Are you sending a packet to the server and that is what is taking action or... Also, back to your original post. When you say nothing, you can't pick it up with the cursor - which slots can't you pickup? your custom ones, the original player inventory?? If you can pick it up, it isn't saving or it doesn't deposit anywhere?
  23. If you have your Handler setup right, it does it all for you. If you don't, wierd thing happen like you are describing. If you are only registering it on your CommonProxy (depending on your setup), that makes me think you are only registering it on your server side. Anyhow, if you have it registered, you have it opened on your serverside and everything happens on client/server seemlessly. If you try to open it on the client and server manually or with something not quite right, it does wierd stuff. There are tutorials on this if my rambling doesn't help. I don't have access to any of my new stuff from work, but if this doesn't help you, I can post somethign else tonight. This is my handler class. Don't pay attention to the horrible coding, this was from years ago. In your main class for the FMLInitializationEvent, you register it. NetworkRegistry.INSTANCE.registerGuiHandler(this, myguihandler);
  24. There is a post I had recently about orang color where GreyGhost posted some very helpfull material. Search and read up on it. Before doign anything elaborate, I would boundary your render code inside push/pop calls to make sure that you are not being gifted by some other gl calls.
  25. Where is your registered GUI Handler so that it syncs up the container on the server/client?

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.