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 doing a block that is supposed to track the player's position. I'm using randomDisplayTick(...) but I noticed that soon as I am far away from the block it stops tracking. I think that there must a better solution instead randomDisplayTick but I don't know what. Can anybody help me here?  :-\

There's probably a better function for it I'm pretty sure about that, but I think the reason that it stops outputting the locations, is probably because of the chunk unloading limit.

I'm doing a block that is supposed to track the player's position. I'm using randomDisplayTick(...) but I noticed that soon as I am far away from the block it stops tracking. I think that there must a better solution instead randomDisplayTick but I don't know what. Can anybody help me here?  :-\

 

I would assume that the block get's unloaded since the player is far away and the whole chunk get's unloaded?

If you guys dont get it.. then well ya.. try harder...

  • Author

I'm doing a block that is supposed to track the player's position. I'm using randomDisplayTick(...) but I noticed that soon as I am far away from the block it stops tracking. I think that there must a better solution instead randomDisplayTick but I don't know what. Can anybody help me here?  :-\

 

I would assume that the block get's unloaded since the player is far away and the whole chunk get's unloaded?

 

The chunk doesn't unload, because I only get like 30 or 40 blocks away from the block. But it may unload if I go farther, that way what can I do?

  • Author

Note that randomDisplayTick is a Client-side only function. If you use it for anything that modifies the world (e.g. spawning entities, setting blocks) it will not work.

It is intended for stuff like torches spawning their particles. So it makes sense that it stops getting called when you go away, since the particles wouldn't be visible anyways.

Depending on what you want to do, you probably want a TileEntity.

 

That did the trick ;)

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.