Jump to content
View in the app

A better way to browse. Learn more.

Forge Forums

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (โ‹ฎ) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Featured Replies

Posted

I'm trying to make a block that has interactions triggered by being moved by a piston. I don't suppose anyone would know offhand from previous experience the series of functions called when a piston moves blocks? I'm trying to figure it out myself, but it's taking time and I thought if someone already knows, why not ask?

  • Author

I'm trying to make a block that has interactions triggered by being moved by a piston. I don't suppose anyone would know offhand from previous experience the series of functions called when a piston moves blocks? I'm trying to figure it out myself, but it's taking time and I thought if someone already knows, why not ask?

I don't have any actual experience with this, but I do have a few ideas. First, when dealing with something from Minecraft itself like this, look at the source code. The second thing is that I know the way pistons work is they basically "deconstruct" the block, turn it into an entity so that it can move, and then "reconstructs" it where it ends up. I have a suspicion that either the block's rendering is turned off or it is actually destroyed before the movement is done. Try adding println() statements to figure out what events are being triggered or if the block may be getting recreated (which feels excessive and isn't that likely.)

width=336 height=83http://img836.imageshack.us/img836/1237/cooltext624963071.png[/img]

I make games, minecraft mods/plugins, and some graphic art.

ย 

Current Project: LoECraft - An industrial minecraft server with its own modpack and custom launcher.

I don't have any actual experience with this, but I do have a few ideas. First, when dealing with something from Minecraft itself like this, look at the source code. The second thing is that I know the way pistons work is they basically "deconstruct" the block, turn it into an entity so that it can move, and then "reconstructs" it where it ends up. I have a suspicion that either the block's rendering is turned off or it is actually destroyed before the movement is done. Try adding println() statements to figure out what events are being triggered or if the block may be getting recreated (which feels excessive and isn't that likely.)

width=336 height=83http://img836.imageshack.us/img836/1237/cooltext624963071.png[/img]

I make games, minecraft mods/plugins, and some graphic art.

ย 

Current Project: LoECraft - An industrial minecraft server with its own modpack and custom launcher.

  • Author

Thanks! I'm really just looking for a Block-side function that I can modify to act as a trigger for actions, preferably with an indication of which direction the block is traveling in. I've tried looking at the code, but I'm afraid some of it is rather hard to follow.

  • Author

Thanks! I'm really just looking for a Block-side function that I can modify to act as a trigger for actions, preferably with an indication of which direction the block is traveling in. I've tried looking at the code, but I'm afraid some of it is rather hard to follow.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

Important Information

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

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions โ†’ Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.