
Naiten
Members-
Posts
325 -
Joined
-
Last visited
Everything posted by Naiten
-
I've made a key handler that adds some motion to the locomotive the player is currently riding when key is pressed. It defines the key well and locomotive moves, but it gets teleported back after some seconds. I guess it's because of mistiming between server and client, so i have to use packets... I send a packet in the key handler class... And where should i read it and apply changes to the entity?
-
That tutorial only shows how to make a packet that does some some weird stuff with random numbers and i can hardly understand how to use that in my locomotive control system.
-
Okay. And how do i perform them?
-
Hello. I've read the tutorial about packets and understand that they are used to transfer data between server and client side. There's said that packets are good for TE and GUI, but should i use them for usual entities or key bindings? If yes, tell me how, please.
-
Firstly, when i unzipped forge and started installing, i got errors when decompiling caused by something with libraries. But i believe, this method fixed them correctly. Than I tried recompiling clear MC 1.6.2 and got a buch of errors: I opened Minecraft class and changed the visibility of running to public. Now it recompiles, but when i try to start, i get a damn i-can't-even-suppose-what-the-duck-can-it-be error. Grrr!!! Any ideas what i have to do?
-
The title says. If i modify updateRiderPosition() so that the rider is outside the collision box, everything is fine, but when it's inside, the whole thing begins to twitch and spasm. Any ideas?
-
can't get collisions to work with custom model.
Naiten replied to endershadow's topic in Modder Support
Use setBlockBoundsBasedOnState(IBlockAccess par1, int i, int j, int k){} with several setBlockBounds(minX, minY, minZ, maxX, maxY, maxZ) inside to change the bounding box by the direction of your cabel. -
GL11.glscalef(-1F, -1F, 1F)
-
Uh, i'm not sure if i can do that.
-
This saved my mental health. if(underBlockId < 1 && underBlockId != RoW.rails.blockID && underBlockId != RoW.railGag.blockID){ addVelocity(0, -0.04, 0); } if(underBlockId == RoW.rails.blockID || underBlockId == RoW.railGag.blockID){ setPosition(posX, MathHelper.floor_double(posY) + 0.38, posZ); // 0.38 = my rail block height (0.375) + little spare space. }
-
So, where do you think the error is? It uses standard pushOutOfBLocks() and i think it's somewhere there... And i can't even imagine why it rides rails well if strted on ground -.-
-
Adding next code to onUpdate() helped me to make my wagons collide with each other, but only if they are empty. How do i make them collide with player inside? //taket from boat class if (!this.worldObj.isRemote) { List list = this.worldObj.getEntitiesWithinAABBExcludingEntity(this, this.boundingBox.expand(0.20000000298023224D, 0.0D, 0.20000000298023224D)); if (list != null && !list.isEmpty()){ for (int l = 0; l < list.size(); ++l){ Entity entity = (Entity)list.get(l); if (entity != this.riddenByEntity && entity.canBePushed()){ entity.applyEntityCollision(this); this.applyEntityCollision(entity); // line added by me } } } }
-
I've said, this is not the problem of server-client, because it lags only on certain blocks like mine rails and half-slabs... --- Also, i've fixed my rails block collision, but this gave no effect on the locomotive... It still runs good on earth and bad on rails -.- --- Here's the video showing the bug. And i repeat once again, this is problem of collision thing, not server-client system... http://www.youtube.com/watch?v=p0mmf_x78l4
-
You are just lucky...
-
For me it throws null exception.
-
Suggest alternatives if so.
-
Oh, but it actually works. Will tell the right way then?
-
What do you want to say, darling?
-
Well, unlike some persons i don't make a secret of my code, so here's the solution. robot = new Robot(); BufferedImage shot = robot.createScreenCapture(x, y, w, h);
-
Solution was just weird. This thing made the trick: public boolean renderAsNormalBlock(){ return false; }
-
Self-solved by public boolean shouldRiderSit(){ return false; }...
-
Hello. So, i've made my locomotive rideable, this is what i want: And this is what i actually have: Any legal ways to do that?