Hey there, does anyone know how Bee Swarm Simulators does their tool system? What I mean by this is, that when you're collecting pollen, they have a system to detect every flower around you within a specific radius, if you've played the game you may know about this
I don't believe they just use .Touched, some math to generate patterns for collections
Lets say I wanted to have a collection system that will collect anything around the player (the yellow square) (Image below)
What would be the best way to accomplish that?
Granted, that I will be making the green parts smaller upon activation, like bee swarm sim. I'm unsure if Bee Swarm Simulator uses .Touched (doubt) but if anyone knows the best way to handle this, I'd appreciate it
Originally I was going to create patterns that I would weld to the character, and from there I would use .Touched, or fire raycasts from the part to the ground, however I believe this would be computationally expensive https://gyazo.com/18605d00d972bbe454c914b8d7009455

12 comments
makes sense
Thank you, I'll read up on region3's as I'm pretty unfamiliar with it, but just to clarify I would need to create the pattern region, then detect every flower that is in in region on tool activation??
well yes
You would need FindPartsInRegion3
https://developer.roblox.com/en-us/api-reference/function/WorldRoot/FindPartsInRegion3
But first you need to have a Region3 made for the parameter tho.
To create a region3 do region3.new(min, max). Min is the 1st corner and max is the 2nd corner, to demonstrate, creating a region with the code Region3.new(Vector3.new(0,0,0), Vector3.new(1,1,1)) will look like https://imgur.com/5a1CJQe
I really do appreciate the help, I'd mark this post as the solution but I'm unsure how haha
I believe you can use multiple regions for that? I'm not an expert for that one since I don't use it much
to accept this answer the button is below this comment vvv
i'll acept nob
WAH