Jump to content

RSQ

Members
  • Posts

    24
  • Joined

  • Last visited

Converted

  • Gender
    Undisclosed

RSQ's Achievements

Tree Puncher

Tree Puncher (2/8)

0

Reputation

  1. Thanks for the replies! I ended up using TGG's first piece of code. Thanks delpi too.
  2. Lol delpi... As for the actual problem, I assume you want to recreate what you just stated. I currently have three of those types of blocks in my mod. The way I do it is create a tile entity, where an item variable is changed when you right click the block. Then the tile entity's renderer renders either that item's model directly, or one of your own models. Have fun with the rest.
  3. I was actually messing with nano time and all that last night. I actually got pretty close, but your code looks a lot better. Thanks once again mate!
  4. Hello, I currently have an item that it supposed to display something on screen when held. I do this by subscribing to the RenderGameOverlayEvent event. But, after some experimenting, I have found that this event runs more times per second with higher FPS than low FPS, which makes sense. The problem is that I want it to render at a certain speed without FPS changing the speed. How would I do this? Any help is appreciated!
  5. Привет товарищ! I haven't been getting sound either. Is this a bug?
  6. createNewTileEntity() is only called if you extend BlockContainer. If you don't want to extend it, try implementing ITileEntityProvider.
  7. Forgot to post this earlier, but I found that 8_b eventually calls 7_a.
  8. After exploring some random classes, I found this piece of code: WorldServer ws = (WorldServer) e.worldObj; ws.getEntityTracker().func_151248_b(e, new S12PacketEntityVelocity(e)); Also, a method .func_151247_a() exists but has similar features. Unsure about which to use. After putting that after my push code, and inserting an !isRemote, the issue seemed to be fixed for long distances, but still exists if the snowball is close to the player.
  9. Hello, I'm not sure how to send the packet, but I have found the classes. I've googled for a while but can't find the answer. Thanks for the help so far though!
  10. After some experimenting, I also discovered that when I only push the entity on the client side(worldObj.isRemote), it goes the first half of the flight, and the opposite for the server. I guess that means that without an isRemote or !isRemote check, the two are combined into one, so the snowball has to move quickly to get to the server bit after the client part is done, which explains the fast zone.
  11. Hello, I have a tile entity that is changing the motion of certain entities around it, like snowballs. If I change the motionX/Y/Z of the snowball, the movement is pretty strange. First it goes like it should, then goes hyperspeed in the middle of flight(almost teleports) and then returns back to normal. Is this a bug in vanilla minecraft/forge, or am I changing the motion incorrectly? This is basically all I'm doing: entity.motionX = someForceVariable; Any help is appreciated.
  12. Item.getItemFromBlock() Oh, that works too.
  13. Forgot about IItemRenderer, thanks guys! I'll try the code out later today. I assume I can register the IItemRenderer to the block somehow? Maybe through an ItemBlock? Not sure exactly.
  14. Hey forums, I recently made a block in my mod that has some fancy rendering when you place it down. I was wondering how I would render the same effects when the player is holding the block in their hand. I looked through the Item and Block classes to see if there was a method for when you hold the item, I found nothing. I also have tried a tick handler recently, but I'm unsure about which type of tick handler to use. Any help is appreciated.
  15. Hello forums, I've recently been into rendering. I wanted to have some fun with the tessellator and rendering random 3D shapes, like this triangular prism: I currently have the two slanted sides, and the two triangular bits rendering. I want to know how to figure out what 'direction' a group of vertices faces. For example, this code renders the image below: tessellator.addVertexWithUV(0.0F, 0, 0, 1, 0); tessellator.addVertexWithUV(0.5F, 1, 0, 1, 1); tessellator.addVertexWithUV(1.0F, 0, 0, 0, 0); tessellator.addVertexWithUV(0.5F, 0, 0, 0, 1); But, by simply changing a couple of numbers(i.e. the first parameter) and switching some around, I can make it face the opposite direction. What about the new code makes it so that it faces another direction? I only have about 2 days worth of experience on this topic, so sorry if the answer is obvious. Any help is appreciated. EDIT: TheGreyGhost saves the day, once again. Thank you! <3
×
×
  • Create New...

Important Information

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