How can I check when my trace “leaves” an entity ?
local OldHitting = false
local trace = LocalPlayer():GetEyeTrace()
local hitting = trace.Entity:IsValid()
if hitting == false and OldHitting == true then
print(“Stopped hitting the entity!”)
OldHitting = hitting
Something like that would work, if i understood you correctly.
Thank you. I’m working on some sort of penetration type.
I want to dispatch a trace through an entity and then check if it left the entity or not.
Sorry for not expressing it as clear as I should
Look at FractionLeftSolid.