Jump to content

EverythingGames

Forge Modder
  • Posts

    388
  • Joined

  • Last visited

Everything posted by EverythingGames

  1. I'm guessing override updateTick and return true for setRandomTick in the block constructor. Trying it now!
  2. Hey thanks for the replies! I was looking as well and now I realize that it kind of makes sense to make this a tile entity, but I'm just trying to find out a simpler way. I've looked in the pressure plate class and pressure plate base class and they do the exact same thing oddly enough with the random tick and update tick method. I really do appreciate your help!
  3. Why would I create a tile entity for a simple block? Seems like there is an easier way to get a ticker with these needed instances. Thanks for the reply, though. If I need to resort to TE's I will.
  4. Hi Is there a method in the block class that is called every tick that includes a BlockPos instance and World instance? Or maybe there's an event that includes these parameters? Thanks in advance. (BTW the updateTick method in the block class is not being called [yes my parameters are definately correct])
  5. Hi I have successfully rendered .JSON models, its just that they don't have the flexibility that the Java coded models have. For example, animating, rendering / de-rendering cuboids within its own code. You can do this in .JSON, you just have to switch models and use IPerspectiveAwareModel. Anyway, how do you render a create a model and render it for an item? I know you must extend ModelBase and use or code your own model there (I mean use as in create it in Techne and use the exported code there). I just need pointed in the right direction: 1.) What is the replacement for the interface IItemRenderer? 2.) How do you attach the model to your item? 3.) Are there any 1.8 tutorials on this that covers items, not blocks or entities? Thanks for all the help in advance!
  6. Thanks for the replies. I'm terribly sorry about the typos, I wrote that fast because I was busy. Anyway I was trying to render the MODEL1 for first person and MODEL2 for third person. I have successfully done this, its just that when looking in your inventory (when you can see the player and he follows your mouse), the first person model is rendered when I want the third person model to be rendered. Well, the .JSON model is giving me too many bugs and there really isn't any tutorials on IPerspectiveAwareModel (seems like nothing supports 1.8, ), so I'm just going to close this topic and stick to rendering models for items in Java rather in .JSON. Thanks, topic closed and locked.
  7. Hi Here's my suggestion - use forge events (just ask if you need to know specifics) to cancel the health bar, render your own based upon how many hearts you have. As for your sword's custom damage, listen for when the sword is attacking the entity and then cause custom damage there (or change the sword's damage [easier IMO]). Hope that helps!
  8. Hi His code is fine if he wants to put it in a seperate method...its still going to be called regardless. Anyway, I don't really see a problem in your code (quick skim through it), I think you should be looking more into your .JSON model to see if all the code is correct there, its really easy to mess that up. Remember this (I'm not saying your code is wrong) - Item Class[Registers your items and contains methods to invoke the rendering], ClientProxy[Calls the static method that contains the rendering], Main[Calls the registerRender() method (or whatever you called the method) to actually execute the code - remember to not call this in the pre-initialization event or you will crash]. With all this remember to make sure your modID is the same everywhere, I recommend keeping a constant storing your modID in your Main or some reference class to keep things organized and to ensure the same modID when called every time. Lastly, please check that your package structure in your resources is correct and that the modID is the same there. Hope that helps!
  9. Let me add that I am using .JSON models and using the getModel method to return different models in third and first person view. Thanks.
  10. Hi I would like to know how to return textures for items in inventory view, a specific model in first person, and a specific model in third person. I have the first and third person models rendered correctly according to the third / first person status. The only thing that is wrong with that is that in the survival inventory (where you can see the player looking at your cursor), the first person model is rendered when the third person should be (this is problem 1). Problem 2 is that I need to be able to return a texture in the inventory while still being able to see the models in first person and third. Basically, model1 first person (DONE), model2 third person (DONE), inventory - texture (NOT DONE), third person model when in survival inventory (again, when player is looking at your cursor) (NOT DONE). Any help is much so appreciated, thanks.
  11. Hi Spawn the entity at the player (make sure your entity's construcor has world and player parameters). par2World.spawnEntityInWorld(new YOURENTITY(par2World, par3EntityPlayer)); EDIT: Use this and extend EntityThrowable (unless you specifically want an arrow type projectile): public YOURENTITY(World par1World, EntityLivingBase par2EntityLivingBase) { super(par1World, par2EntityLivingBase); }
  12. Thanks TGG for the reply. I'm not to sure on how to use the interface in terms of how I link it with my item and model (I've never used this before). Are there any tutorials for 1.8 out there that cover this? Any more help is greatly appreciated, thanks.
  13. Hi I realize the need to be able to access the rotation / translation values of an item to do minor animations. I know this is possible because I've seen others do this such as TheGreyGhost and his Item translation tool. I just need to know how to access these values and change them (I don't need to save them) in Java. Any help is appreciated, thanks.
  14. Thanks for the reply, it wasn't hard, something just wasn't clicking in my mind till you described that, thank you for doing so. Easy fix, topic is now solved and locked (locked in a moment's time).
  15. Could I see an example just in a method setting NBT? I just need pointed in the right direction. Thanks all.
  16. Hey, thanks for the reply. I think there are some odd parameters like old and new itemstacks, I just wish it was as simple as saying "no item, you may not go up and down!". Haha, and yeah, my code gets very complicated, I hate re-writing it because it takes hours, I just want a simple NBT system to get special item properties and not have to use polymorphism for array instances and using enhanced - for loops to loop / check through each instance of my base class (grabbing properties from my child classes and apply them to the parent without using static variables). I also have to use an alternative to "getTagCompound().getInteger("")".For this, I use polymorphic getters implementing string based if statements to return different values. I send packets to sync these values with the server and client and hook them into IEEP, some reflection is involved if you want to draw strings using these values based on what item you are holding. See, NBT would be a lot easier!
  17. Hi I heard there was a definite fix for the NBT bug for when the item is updated (the item equip animation). How exactly do I implement this fix? I've looked at the changelogs on the repository but I can't seem to see what I should do. I don't need help at all on the NBT, just how to implements Lex Manos' fix for the bug animation. I really do need this, otherwise its up to my old system of packets, IEEP, and polymorphism. Thanks all in advance!
  18. I figured there would be a dynamic texture path that I could attach to a json and UV the arm with its coords, but I guess not. If anyone can figure this out or know of a better way (like maybe draw the arm with the local skin in Java then render the item), just let me know, I'll keep this topic unlocked.
  19. Hi Is it possible to bind the local skin of the player to a .JSON model? I want the texture of the player's arm to be on a certain part of the model. I'm thinking that where you declare your texture locations in your .JSON file you just plug in the texture location of the local skin (maybe the bind local skin texture has a texture location). I can't seem to think of anything, everything else is done in my mod except this functionality, I'd just like players to be able to see their own skin on the arm model rather than having a default texture on the arm. Also, I don't want to draw a model in Java using Techne, I want to stick with .JSON modeling (I like the simplicity yet the creativity of being able to create complex model renders). Any help is much appreciated, thanks to all in advance!
  20. Man I sure do appreciate your help! Thanks alot! That cleared up so many things for me.
  21. That looks like that'll work! I thought about doing exactly that, but I wanted to make sure it was fullproof. May I ask why you are checking the player's unique ID? Thanks so much for the response!
  22. Hi As the title says, I want to return a .json model in third person. How would I be able to check if I was in third person and change the ModelResourceLocation of an item? I have the model, I just need to know if this is possible and if players on a multiplayer server would be able to see the third person model rather than the first person model. If I could also add that I would like to also return a texture rather than a model for the inventory (Gui) view. Thanks all in advance!
  23. Exactly. GuiContainer simply does it for you, using their packets. I highly suggest learning how to implement packets in your mods because they are so useful. @diesieben07 has a great tutorial on the SNW packet system. Go take a look at it here: http://www.minecraftforge.net/forum/index.php?topic=20135.0
  24. Hi Take a look at the code for the vanilla stained glass and how they returned a texture with a semi-transparent background. Hope that gives you a basic idea.
  25. Ah, I did not know that you could specify which mods are loaded first within your mod. Thats something to keep in consideration.
×
×
  • Create New...

Important Information

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