of     1   

POC0bob
#157120599Tuesday, March 03, 2015 6:06 PM GMT

Hello, I am trying to figure out how to get this FindPartsInRegion3 script to work, basically what it does is create a vector box in front of the character, and determine if there are any parts in front of the character: print("Finding parts...") local pnt1 = Vector3.new(selectedchar.Head.Position.X-1.5,selectedchar.Head.Position.Y-4,selectedchar.Head.Position.Z-2.5) local pnt2 = Vector3.new((selectedchar.Head.Position.X-1.5)+3,(selectedchar.Head.Position.Y-4)+5,(selectedchar.Head.Position.Z-2.5)-4) Region = Region3.new(pnt1,pnt2) pfound = game.Workspace:FindPartsInRegion3(Region,nil,50) print(Region.Size) print(Region.CFrame) print(#pfound) if #pfound >= 1 then print(#pfound .. " parts found") end for _,Part in pairs(pfound) do --Do stuff with the parts end However, despite my best efforts the list is always empty, I even attempted to have it create a small part to mark where the center (the CFrame of the Region) is, and it seems to be in the correct spot every time, however the list is still empty. Any ideas? Thank you for reading.
POC0bob
#157124620Tuesday, March 03, 2015 7:52 PM GMT

I cant figure out why this isnt working, i even wrote a function to draw out the box its using to check for objects and the box is in the right place and size, and most of the parts are small enough to fit entirety in the box...
POC0bob
#157138237Tuesday, March 03, 2015 11:16 PM GMT

I am starting to think this might just not work, I haven't spent much more time on this, but seriously >.<

    of     1