ryakra seemed to have trouble with knowing when to place semicolons, and seeing as Priceofmar5's post contained no semicolons, I did not see how that would help. We clearly have different opinions about how to learn a programming language, so why don't we just agree to disagree?
Let me make a real life analogy.
Lets say I have no idea how to drive. I have never seen a car before, and I have no idea what anything does inside of a car. If you just put me in the car and say go forward, I wouldn't know what to do. If you put me in the car and say go forward, and then explain where and what the gas pedal does, then I have learned this. In this case, the car is the code. You are putting functional code. He has no experience in java programming, and has no idea what anything does. But if you say "This part is wrong: *insert code here* to fix it you do *insert fix here*, here's why: *insert reason here*" Then he can learn what he is doing and learn to improve on his mistakes.
Some times you need to see real code to know what your doing wrong.
When I was younger, I did not understand inheritance. I knew WHAT it meant, but whenever I tried extending classes, it wouldn't work. So I found an example of code using inheritance, and found that I was just messing up the constructor. From then on, I knew what to do.
Here's the thing. You knew what it was, then got example code. He doesn't know what he is doing and got code. NOTHING was explained in the code, so he cannot learn. I started making mods in the same way. Didn't know what I was doing. Then I learned some java by watching online tutorials and I finally got what I was doing. The code finally made sense after I learned java.
The downside to that would be that there isn't a way to call it every possible moment. I attempted something similar but unless the mouse was either down or was just clicked about the time of the tick it was called in it didn't work.
Use modloaders OnTickInGame method. make sure you have the code in the load method to set the hook.
ModLoader.setInGameHook(bla bla bla);
If you look at the debug screen in minecraft by pressing F3, there is an int labeled with "f" and it has a value between 0 and 3 depending on what way the player is facing. Use that.
0
Let me make a real life analogy.
Lets say I have no idea how to drive. I have never seen a car before, and I have no idea what anything does inside of a car. If you just put me in the car and say go forward, I wouldn't know what to do. If you put me in the car and say go forward, and then explain where and what the gas pedal does, then I have learned this. In this case, the car is the code. You are putting functional code. He has no experience in java programming, and has no idea what anything does. But if you say "This part is wrong: *insert code here* to fix it you do *insert fix here*, here's why: *insert reason here*" Then he can learn what he is doing and learn to improve on his mistakes.
1
Here's the thing. You knew what it was, then got example code. He doesn't know what he is doing and got code. NOTHING was explained in the code, so he cannot learn. I started making mods in the same way. Didn't know what I was doing. Then I learned some java by watching online tutorials and I finally got what I was doing. The code finally made sense after I learned java.
0
0
EDIT: It also looks like the skeletons chest is bigger than it should be comparing it with one of the previous images
0
Use modloaders OnTickInGame method. make sure you have the code in the load method to set the hook.
ModLoader.setInGameHook(bla bla bla);
0
0
0
0
0
0
0
MCP was meant to de-compile the game. ModLoader was meant to be used for MCP.
0
nextFloat generates a number between 0.1 and 1.0
0
0
Pretty sure this should work, but I'm not entirely sure.
if ((mc.thePlayer.getItemInUse() != null) && mc.thePlayer.getItemInUse().itemID == (BPick.shiftedIndex | BSword.shiftedIndex | BAxe.shiftedIndex | BHoe.shiftedIndex | BSpade.shiftedIndex))