SimpleZone | A simple, fast and new Zone module!

I am confused which one can I do meshes in? SimpleZone or LessSimpleZone?

1 Like

um, what is the correct code to use a mesh as a zone? and query it and do something if player is in it, and also what if it the player leaves it?

thanks

1 Like

SimpleZone supports meshparts yeah, it’s the same as parts

1 Like

Does it support Priorities for zones?, if not, then that would be cool to add

1 Like

Ooh i could add this cuz SimpleZone hasnt had an update in a bit, ill lyk when it’s in

how would priorities work again? just what zone calls first?

1 Like

No like what zone is able to take in items when theyre overlapping

Say i have 2 zones, 1 inside another

If i set the inside one priority to higher, there is no issue with how items will enter/exit (If item enters inner zone, they leave outer zone and enter inner zone)

Its kinda like if you used a Union as a zone but less janky

1 Like
  1. Is there a way where it can be set up so that it does not throw that they left the bigger zone, when they are really still in it? (when they entered the inner zone) , meaning the zones have independent enters and exits? or if the priorities are the same , then do they have independent enters and exits?

For example the big zone is a biome background sound zone that your want to continue to play , even if they enter a smaller inner zone , that is like an effects zone…

  1. can you start adding version control numbers to your releases, so we know which one we are using? and put it in the script file at the top comments…

ahh,… I see you do have a version in the comments… I thought this was like update 2.4.3…

image

  1. also when I open up the .rbxl, it says this is a package or something like that… what does that mean? is there a way to have it not use a package, if I want all the code to be in the .rbxl or published game…?

I am I supposed to click on ‘click here’ to modify? or not.,…

1 Like

It’s cuz i have a PackageLink for easy version control for users so that updates r easy to roll out

It’s version 2 because it’s the 2nd new PackageLink i’ve used :V When you change a PackageLink the old one no longer gets updated, currently versions are based on the PackageLink

To do this you just group the 2 zone areas as 1 Zone with SimpleZone.fromParts() or SimpleZone.fromBoxes(), tho i’m kinda confused as to what this means exactly

This was related to your comment that ’ (If item enters inner zone, they leave outer zone and enter inner zone)’ … I thought this meant it the code would say they left the outer zone, when in reality they are still in it… so for my example above, they are still in the outer zone even if they are in the inner zone, so I would want them to still hear the music from the outerzone, and not have it stop (because I would be starting the music when they enter, and ending it when they leave the outer zone for real)

This is innacurate, it’s more so that the item has entered a higher priority zone (this is planned as a feature currently, not implemented)

Yeah just set the inner and outer zones priority to the same

Package Version 76:

  • Updated the SimpleSignal dependency to the latest version, 33, which uses swapback arrays for connection storage (This reduced disconnection time from O(n) to O(1) at the cost of slightly degrading order), and some other minor optimizations to the signal dependency

Zone priorities are delayed because I’m focused on plugin development right neow…

The latest version is available via the download link

Inside of copyToQuerySpace function, you’re attempting to call Instance.fromExisting but this method doesn’t exist. This may be unintentional and shows as an error in linters like Selene.

Instance.fromExisting() is indeed a valid Roblox builtin function, it’s probably Selene’s issue not mine :person_shrugging:

I would love to use this library to replace this with ZonePlus. However, you say in the best practices section that I could use fromParts to optimise multiple spatial queries in bulk, but due to my way of having constantly destroying and adding new zones, like a few hundred per times per say. I don’t really understand how I would accomplish this with this library and have had given it an attempt. Got any tips I could do to counter this or stay with using ZonePlus?

What’s your use-case for doing this?

maybe we need a feature something like updateQueryZones(queries: { Part }, ...), so we dont have to .new & destroy it to make new one?

2 Likes

Hi, if you’re doing this I’d recommend using LessSimpleZone instead which lets you update volume

2 Likes

I’ll definitely considering adding this, maybe before zone priorities cause those aren’t even half done :skull_and_crossbones: (i been busy :frowning: )

Thanks for this! Definitely will be swapping out ZonePlus for this.

1 Like