Jump to content

LordFokas

Members
  • Posts

    36
  • Joined

  • Last visited

Everything posted by LordFokas

  1. I don't know if you've ever made wine in real life (I have) but with render pass 1 the wine looks really thin, like water. In my country you can barely see through a cup of wine, if you can even see at all. I think render pass 0 looks accurate, especially for a small barrel. on a technical point of view, that's an engine issue, there's no fixing it.
  2. The ability to not render a rider is something I will be needing soon too...
  3. That's sort of what my mod does I have a shield block that allows entities through based on metadata, and it works wonders with living entities... non-living entities, on the other hand, always get stuck.
  4. What I'm suggesting is a quick and painless change, which is changing Block.getCollisionBoundingBoxFromPool(World w, int x, int y, int z) to Block.getCollisionBoundingBoxFromPool(World w, int x, int y, int z, Entity e) where the Entity is the one whose collision is being tested at the moment. It should be ignored by minecraft / forge code, but it's useful when you need to override some block collisions in specific ways. While you can use 'addCollidingBlockToList()' to override collision behavior, as long as your AABB is not null, non-living entities such as EntityItem and EntityArrow will still collide with the block, even if you have overriden 'addCollidingBlockToList()' to allow those entities to go through the block. On the other hand, if your returned AABB is null, addCollidingBlockToList doesn't seem to get called at all, so you can't just sneak your real AABB into the list anyways.
  5. Tessellator? You should either use MC's models (a class extending ModelBase) or call OpenGL directly. Alternatively, take a look at this: https://github.com/LordFokas/AdvancedRenderingCore, you may learn a few things from that code. It shouldn't be a problem...
  6. Actually, tickCount is how slow you want it to rotate. That's the amount of ticks (1/20th of a second) between each rotation. So the fastest setting would be 1, while 20 would result in a rotation / second. Note that the texture width must be a multiple of 16, and the height must be a multiple of the width. Frames are stacked vertically, so the image should always be taller than it is wide.
  7. Make a custom block renderer (and I mean an implementation of ISimpleBlockRenderingHandler). If you make your block's texture overrideable, you can simply override the texture, tell the RenderBlocks instance to render as a normal block, then rollback to the default textures / whatever. At least, that's what I do and it works wonders.
  8. Well, 1) You can't. Minecraft doesn't support it. The best bet you have is to bind textures between rendering calls on the model renderers. Like, render Modelrenderer1, bind texture, render Modelrenderer2. However you can't do it inside modelrenderers that are a child node to other modelrenderers. I have a project, called ARC (Advanced Rendering Core) that is still under development. It is Open Source. It allows you to define a texture not only per block, but also per face. It also enables you to do a lot more things that Minecrafts rendering system doesn't support. 2) You need to save the reference to the specific modelrenderer and rotate it as you wish every time you render. This won't work inside custom block renderers, because they're barely even called. To achieve the kind of animation you want, you need a TileEntitySpecialRenderer. However, using a TESR is very expensive, and you should avoid it unless strictly necessary.
  9. Look at RenderBlocks. find the function that renders fences. It has everything you may need there.
  10. I would like to have a LivingKnockedBackEvent, so I could stop some entities from being knocked back. (which implies @Cancelable) I would also like the LivingHurtEvent to be changed, or variations of LivingEvent to be added, so that I could stop the player from flickering in red / display flames. Is that possible?
  11. I'm not sure... that why I have them on constants instead of directly using the value They should be pretty easy to figure out though, at least they were to me...
  12. You don't need a TileEntity. In fact, that's more downsides than anything else... Like DarkGuardsman said, you get the players rotation. But that's a float, and you can't use that on MetaData. I have a block that can have horizontal rotation, which depends pretty much on the player's Yaw angle. So I have this function on my Helper class: public static int yaw2dir(float yaw){ int dir = (MathHelper.floor_double((double)(yaw * 4.0F / 360.0F) + 0.5D) & 3)+3; if(dir > 4) dir -= 4; switch(dir){ case 1: return dirZPos; case 2: return dirXNeg; case 3: return dirZNeg; case 4: return dirXPos; default: return 0; } } When the block is placed, I call that function with player.rotationYaw, and it returns the block's orientation (facing the player). I then proceed to set that value as the block's Metadata. It is later used by my block's renderer to decide what texture to use on each face.
  13. It's pretty much the same thing. you just need to override String getTextureFile() on your blocks, to return your texture file's path. Then on getBlockTextureFromSide you just return the index of the texture in that file, according to the side. You should also have your client proxy tell Forge to preload that file, when the mod initializes. And that's pretty much it. I don't know if I was clear or you understood me, but in case the answer is no, just tell me and I'll help.
  14. Follow this Tutorial: http://www.minecraftforge.net/wiki/Category:Generic_Mod More specifically, this part of the tut: http://www.minecraftforge.net/wiki/Tutorials/Basic_Modding The generic mod explains the basics of modding very thoroughly in a comprehensive manner. Basic Modding Tutorial explains all you need to know about proxies.
  15. On the server side, you're trying to load a client proxy from the common package. The point of Proxies is that you use different ones for the server and client, and you are trying to use the same...
  16. Of course you can. In Eclipse, just click the folder you want (common or src) and add a new package. When you compile and reobfuscate the code, there will be a folder tree with the same name as your packages in /reobf
  17. On Minecraft 1.3+ you need as much as you need to make a client mod work. Mods are no longer client / server, they are distributed in universal packages, so the same code works both on clients and servers (because the client, internally, is a server too);
  18. There's a class called ModTextureAnimation on net.minecraft.src that does that. I'm not totally sure how to use it though...
  19. I think it uses Metadata... so stone is actually stone, brick and cobble, while wood covers all 4 types of wood.
  20. Is the block made by you, or should it apply to any block? If it's made by you, you can use metadata to do that, assuming you don't need a complex system. If it's not, you can replace the block by another block made by yourself, and have a TileEntity store the block that was in that place. I can't help any more unless you are more specific and give more details on the feature you're trying to create.
  21. Nah, it's actually pretty basic The code behind that is advanced stuff, but you don't need to know how it works, just what methods from what classes you need to call.
  22. I was browsing the tutorial page today (considering making some tutorials) and I accidentally found what you need. Here: http://www.minecraftforge.net/wiki/How_to_make_an_advanced_configuration_file
  23. Oh, I didn't it ignored vanilla ID's. Nice. So yeah, overriding the block by ID is pretty easy to do, and should be clean. I'd do it...
  24. Actually SCC's answer is not that bad... And it does work... although I don't know if you can succeed to assign a block an ID that is already being used... probably Eloraam has a way to go around it, given she's one of the Forge main devs (or was at least), and her skill levels are above those of the average modder. At this moment, the core mod option sounds the best, or you can waste some hours looking at the code, searching for something that allows you to override a block the way Elo does with the Mossy cobble.
  25. I never rendered items, only blocks, that's why I asked. I assumed you knew what you were doing, turns out you needed an entity so you just cast the first object you get your hands on to Entity and use it as a parameter on the function. I'm not able to help you any more, nor do I believe you are fit to be a modder, or any kind of programmer at all. This is probably my last reply on this thread. Please do yourself a favor and learn proper programming before attempting to make a Minecraft mod.
×
×
  • Create New...

Important Information

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