157 for (
const TPair<FCollisionPrimPair, FCollisionIgnorePairArray>& KeyPair : CollisionTrackedPairs)
159 if (!bPrim1Exists && !bSkipPrim1)
161 if (KeyPair.Key.Prim1 == Pair.Key.Prim1)
165 return BonePair.BoneName1 ==
Other.BoneName1;
168 else if (KeyPair.Key.Prim2 == Pair.Key.Prim1)
172 return BonePair.BoneName1 ==
Other.BoneName2;
177 if (!bPrim2Exists && !bSkipPrim2)
179 if (KeyPair.Key.Prim1 == Pair.Key.Prim2)
183 return BonePair.BoneName2 ==
Other.BoneName1;
186 else if (KeyPair.Key.Prim2 == Pair.Key.Prim2)
190 return BonePair.BoneName2 ==
Other.BoneName2;
196 if ((bPrim1Exists || bSkipPrim1) && (bPrim2Exists || bSkipPrim2))
202 if (!bPrim1Exists && !bSkipPrim1)
204 Pair.Key.Prim1->GetBodyInstance(BonePair.BoneName1)->SetContactModification(
false);
208 if (!bPrim2Exists && !bSkipPrim2)
210 Pair.Key.Prim2->GetBodyInstance(BonePair.BoneName2)->SetContactModification(
false);
217 RemovedPairs.Reset();
219 if (CollisionTrackedPairs.Num() > 0)
221 if (!UpdateHandle.IsValid())
227 else if (UpdateHandle.IsValid())
229 GetWorld()->GetTimerManager().ClearTimer(UpdateHandle);
233 UFUNCTION(Category =
"Collision")
234 void CheckActiveFilters();
237 void InitiateIgnore();
239 void SetComponentCollisionIgnoreState(
bool bIterateChildren1,
bool bIterateChildren2, UPrimitiveComponent* Prim1, FName OptionalBoneName1, UPrimitiveComponent* Prim2, FName OptionalBoneName2,
bool bIgnoreCollision,
bool bCheckFilters = false);
240 void RemoveComponentCollisionIgnoreState(UPrimitiveComponent* Prim1);
241 bool IsComponentIgnoringCollision(UPrimitiveComponent* Prim1);
242 bool AreComponentsIgnoringCollisions(UPrimitiveComponent* Prim1, UPrimitiveComponent* Prim2);
243 bool HasCollisionIgnorePairs();
246 FTimerHandle UpdateHandle;