Jump to content

delpi

Forge Modder
  • Posts

    840
  • Joined

  • Last visited

Everything posted by delpi

  1. I'll have to play around with that tonight. That was the event I started with, but I must have done something wrong.
  2. This is probably obvious but i'm missing it. I want to cancel all things to do with buckets under certain conditions. I see the bucketfill event. What I can't figure out is the empty bucket event and I don't see anything searching. Could someone point me in the right direction?
  3. Lets assume you returned a list of EntityItem's into your Entity list. or something close to that. Play around with it.
  4. You would look for EntityItem.class Then you would need to cycle through each of the targets found that way and see what the item is of the EntityItem. It has a method called GetEntityItem() which will give you the ItemStack. If you haven't researched how to look through the base Minecraft code, I highly recommend it. Both from examples on how to do things as well as being able to find stuff as I just listed above.
  5. Assuming you want to take the same action if it is any of those, you might try something a bit more efficient As far as looking for entities, you need to use a bounding box. You can find some of that code in various mobs. I use soemthing like this With a custom BB like this. Good Luck.
  6. I noticed a lot of post about how to create a book type questions but nobody had an answer for 1.7.2. I created one and it seems to work fine so posting here for others. This is a snipet of code from a command I have in each of my mods.
  7. Just figured something out. This doesn't look like a Forge issue so much as a minecraft issue. Hold a colored glass block in your hand and compare it from 1st person to 3rd person. It messes up in 3rd just like my Custom Item Render. Tried this out in vanilla 1.7.2 and 1.7.4 and the issue goes away in 1.7.4 but exists in 1.7.2. Very interesting. Wonder what they changed and if we could duplicate it?
  8. I had posted about this before but hadn't had time to really did into the issue. I have now. Item Blending in 3rd person on self does not work. It works in 1st person, and on other Entities(both players and mobs) holding the item whether looking from 1st person or 3rd person. Basically the only time it doesn't work is when you are holding the item yourself in 3rd person. Something is happening render wise to negate the blend functions: GL11.glEnable(GL11.GL_BLEND); GL11.glBlendFunc(GL11.GL_SRC_ALPHA, GL11.GL_ONE_MINUS_SRC_ALPHA); There was a post on something similar at : https://github.com/MinecraftForge/MinecraftForge/issues/972 However, there are several wrong statements in there. I can promise this worked in 1.6.4. I had it in my mod and it worked fine. Nothing serious has changed. The portion of the custom render from forge that renders the item in 3rd person for player and a different entity call up the same ItemRenderType of EQUIPPED. I think this is a bug at this point. I looked at the bug part of the forum and it doesn't seem to be for stuff like this. could you point me towards the right place to get this looked at?
  9. This is pretty vague description. In order for your mob to have a name over it, you had to tell it to do that in the render. This name render is normally only for players. I took that code and put it in place for my custom NPC's, but then had it do a distance check so it only shows up in a very short radius around the NPC. Delete from your render code the part you put in associated with displayname.
  10. I haven't played with this other than setting the spawn position, but are you sure this is used on respawn or is it used the very first time to find the spawn point every in a world? Try deleting your entire world folder and starting fresh with your code in place and see what happens.
  11. That would be the 2nd option I gave him, but couldn't remember the name of the function.
  12. I wasn't looking to mess with the code directly, just readily see it. I found it under a different place. I'll look for the .csv files in the location you mentioned and see what I find. THANKS!
  13. You are not going to get it that easy as changing the attribute. You will have to recode part of the mob.
  14. If I rember right, there is a variable for phase of the moon in the world provider. You could then use an entityspawn event to watch for the moon to be right and then replace the spawning of other mobs with your custom mob. You could also on your custom mob change the function for is it a good spawn that normally just looks at light and such to also look at the moon phase.
  15. The first time I setup the dev eclipse env everything was there. This time, the sourcecode isn't under build and the folder unpacked/conf with all the field names isn't there. I've tried re-running everything and it just doesn't show up. Any ideas what i'm missing. Btw, everything works fine, I just can't see this information anymore.
  16. Woota!!! Thanks. I couldn't find that after hours of searching.
  17. I'm sure this is simple but I can't figure it out for the life of me. Gradle is using Java 1.6 to compile my mod. All the path variables are pointing at 1.7. I can't find any references to 1.6. I even went and uninstalled 1.6 from the machine. Still, the same error persists. Anybody know a solution?
  18. I hadn't really looked into blocks that check for time of day. Which ones are you thinking of?
  19. I found a way to pull this off. Basically I created a custom "EntityRenderer" class. At the first client tick of the game I replace the original with my custom. In the custom I check to see if it is one of my custom portals and use difffent checks for the wobble effect. Works perfect, but seems overkill. I would still really like to know how to do what I posted the question on.
  20. I 'think' I pulled off telling it to just change the time in one world and but posting to the log at various parts of tick events, I would see it change for a fraction of a tick, then it would be the same as all the others. Something is calling the method to write to all of them. For your comment about mobs spawning with a night sky. If you use the nosky variable, then there is no light in the world. I 'think' that mobs try to spawn always, but when they test for light and there is too much, they do not. This looks like it is working right in my custom dimension I talked about above.
  21. I've got my own custom portal setup fully working except for one visual. I can't get the wobble effect while you are in the portal. I've looked at other post on this but nothing was really complete. It seems the way to do this is with a render event but there isn't a lot out there on it for something like this. Has anyone pulled this off and could provide an example? If not, could someone point me to the right event to utilize? I've tried several and I know they are running my attempt at causing the wobble effect. It is a version of what does the base minecraft effect for portals. Nothing changes though. I'm not that great with openGL. I've had some success but most of it is from inferring what is going on and reading tutorials.
  22. One observation is that the way you have this written it will call return to owner every tick after it reaches the timer. Might be on purpose, but can't tell. My guess at your problem is that ther is no owner. You need to ad some log points in the code and watch for certain parts if the code to happen. That will find it.
  23. This isn't exact code as I'm on my phone, but you should be able to get it. Double radius = 2.0d. Specify how far out for loop for as many particles per iteration you want. I it's per tick, Ild keep it low double x_shift = random.nextfloat() * 2 * radius + ( posX - radius) Do same for y and z. Except for y need to add Hal the height if your entity as well or it won't be centered The spawn an entityfx of flame at your new shift coords Play with it until it looks right.
  24. Just a guess, but I bet if you look at the entity fish code you will find some variable to set.
  25. Here is something that works for me. I've done it different ways, but you should be able to modify this to suit your purposes. Then setup a custom command to call it with something similar to this. Let me know how it goes.
×
×
  • Create New...

Important Information

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