Hey guys i need help with some coding. If anyone has or knows of any tutorials for the following below, I'd really appreciate it!:
Vending Machine (I want it to be where only a certain item will be able to activate it, like a dollar bill or coin for example. Also i want it to where after you activate it, it will randomly give you an item.)
Trash Can (one that acts like a hopper where if you drop any item into it, it will store that item in it's inventory and then after a certain time, it clears the inventory, if that's possible.)
Dollar Bill (used to activate the vending machine.)
Doors or anything that has a kind of door that opens and closes.
Guns/Gun HUD(or whatever its called. Basically when you are looking through a scope and all that)
Custom Portals (I've made some stuff for my mod using mcreator, but the one thing i dont like is when you want to make a new dimension, the only kind of portal you can make is the portal used to enter the nether world.)
If i can think of anything else, I'll let you all know.
First off, learn Java. Otherwise when you get stuck and people try to help, you won't understand.
For a vending machine, you need to check if the item the player is holding is a dollar bill, and if so, drop an item in front (look at the vanilla dropper code for help)
For the trash can, look at the furnace code, but instead of setting the output, just remove the item.
Dollar is just a regular item.
For doors, just look at the vanilla door code.
A gun HUD is quite tricky, but with a combination of an overlay and checking if the player is using the item should work.
I have never made a portal, but there are tutorials out there, and you can look at the nether portal code to find out how entities are teleported to different dimensions.
As it sounds like you are just starting modding, I would recommend using Minecraft Forge, there are plenty of tutorials for it, and it makes everything easier. But most importantly of all, LEARN JAVA! The satisfaction you get when you write your first program or mod is a huge reward, and it opens up everything. If you know java you can create ANYTHING, if you don't then all you can do is copy someone else's ideas.