Need to make an entity freeze when it hits the wall.

In my tripmine project, I need to make an entity freeze when hitting the worldspawn.

But ENT:Touch won’t work because; “This only works for brush entities and for entities that have Entity:SetTrigger set to true.”

Any idea on how I could check if the entity touches the worldspawn?

Edit: I’m throwing the entity against the wall with a Swep so the physics is moving around a lot. This makes doing a trace difficult.

I don’t know coding but you can try look up at the code of “Battlefield 4 C4”
Maybe that will help you somehow

[editline]3rd November 2016[/editline]

Oops it was Black Ops, rip my reading
Here the link:

Thanks i’ll look at it.



these might be helpful

Why not



PhysObj:EnableMotion if you haven’t found it yet)

ent.physicscollide doesn’t work on stuff like prop_physics

based on OP’s wording it sounded like he was pushing around arbitrary physics objects

Seems obvious to me that the tripmine SENT is the entity in question