mirror of
https://github.com/EngineHub/WorldGuard.git
synced 2024-11-27 21:15:57 +01:00
Added parent region checking to PRTree manager as per Dark_Arc's specifications.
This commit is contained in:
parent
0edb6e6157
commit
2c4d4708d8
@ -122,6 +122,16 @@ public ApplicableRegionSet getApplicableRegions(Vector pt) {
|
||||
for (ProtectedRegion region : tree.find(pointMBR)) {
|
||||
if (region.contains(pt)) {
|
||||
appRegions.add(region);
|
||||
|
||||
ProtectedRegion parent = region.getParent();
|
||||
|
||||
while (parent != null) {
|
||||
if (!appRegions.contains(parent)) {
|
||||
appRegions.add(parent);
|
||||
}
|
||||
|
||||
parent = parent.getParent();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user