Jump to content

Recommended Posts

Posted

Is it possible to have separate instances of a dimension for different players? I mainly want some temporary dimensions that should only contain one player at a time.

 

Also, is it possible to restrict block placement in a dimension?

 

Thanks in advance,

Nephroid

Posted

Does anyone have any ideas?

 

Right now, the only workaround I can think of is hashing each player by player name, then setting a certain spawn location based on the integer from the hash function. These dimensions are meant to be pretty small and enclosed (like the ones from the dimensional doors mod), so that might work.

 

If anyone has any additional ideas or suggestions, I'd like to hear them.

 

Thanks

-Nephroid

  • 2 weeks later...
Posted

I'd like to mention in advance that I don't have a solution to your issue, I'm actually looking for this solution as well and have been unable to find it, I thought it'd be wasteful to create a new thread. Did you ever find a solution or are you still searching?

Posted

One idea I had was to hash the players names (I dont remember if 1.7.2 and/or 1.7.10 use hash values for players or if thats 1.8+, if it's in 1.7.2 then use minecrafts hash value) and somehow translate that into a set of coordinates or like a grid location and rather than having separate instances entirely give each player a portion of a dimension. I don't know if this is exactly what OP needed but in my case this would work as I'd only need a small area for my dimensions anyways, but it has to be a separate dimension as it fits my mod thematically.

 

EDIT: When I say hash I don't really mean like the String.hash function (that isn't the exact name but close enough, I can't remember off the top of my head) but rather like an MD5 sum or something along those lines because it makes life a lot easier if all the "hashes" are the same length which isn't always the case with the hash function. The downside with using something like an MD5 is that is returns I believe a 128 bit number. Which is two longs worth of integer data, AKA very large. So it'd need to be truncated a lot and it becomes a mess. So that wouldn't really work either, hence me not getting any further with the idea

 

EDIT 2: I just reread the post and realized the OP already had this idea, I didn't see the post before though haha, oh well.

Posted

I guess for the block destruction in the instanced dimension its just a simple check whether the player is in the specific dimension and then return the I believe its the canEdit player capability false. But that is just a theory, the living update event should be useful for that.

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...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Announcements



  • Recently Browsing

    • No registered users viewing this page.
  • Posts

    • Please read the FAQ and post logs as described there.
    • Upon starting the server I get; [main/ERROR] [minecraft/Main]: Failed to start the minecraft server net.minecraftforge.fml.LoadingFailedException: Loading errors encountered: [     Framework (framework) has failed to load correctly §7java.lang.NoClassDefFoundError: net/minecraft/client/gui/components/toasts/Toast ] I suspect there is a (possibly a few) client-only mods installed on my server. Any help would be appreciated! (Yes I know there are a lot of mods...) Here is the crash log:   https://paste.ee/p/pRz5mhMl#s=0
    • That's basically what the failure does, my apologies for failing to specify.  It just tries again on the next tick until it detects the entities for that chunk are loaded, and then tries to load the entity.  From there it gets into different failure states depending on what goes wrong, but in short, if the entity fails to load once the entity list becomes available, the request is cleared and must be resubmitted by the end user.  There should be few cases where that actually happens. Yes, that is my understanding of forceloading.  That's why on a successful summon, it removes the forceload.  Otherwise it does just leave the chunks loaded long term. Thank you for your help, any knowledge is useful!  I don't often mess with forceloading and my prior experience is 1.16 so I'm also a bit out of my depth haha.
    • I will have to do more research about 1.18 chunk loading. You were unclear about how your code manages with the entity load failure. If you simply used a loop, I suggest submitting a tick task to the next tick which does the same thing, checking if the entities are loaded and if so teleporting the right one else submitting another tick task etc. Also I think forceloading permanently force loads the chunk, and it only starts to unload when you make a subsequent call to mark the chunk as not forceloaded. I may be completely wrong, I dont know much about 1.18, most of my experience is 1.20. Good luck I hope you figure it out after all this time 😅
    • i managed to fix it by reinstalling the modpack and re-add all the extra mods I've had previously.
  • Topics

×
×
  • Create New...

Important Information

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