ID:2146710
 
(See the best response by Nadrew.)
Problem description:
So I'm trying to make like false walls. What it's intended to do is allow all projectiles/objects through it but interact with mobs to either allow or prevent them from going through. The object is nondense and I'm using the cross proc. But it still effects objects. If I change it to where cross effects all movable atoms I can define objects and sorta get them to pass through by setting their location var. The problem with that is some objects still act as though they bump it and it procs the projectile's bump proc.

I'D like to know if I should be using the cross proc in the first place. Again all I want is for it to allow objects to freely pass through but interact with mobs.

Best response
If the object is not dense, you can either return 1 or 0 inside of Cross() to allow or disallow passage, as the reference states.
Is that for the projectile objects that attempt to go through it? I have the mob part working fine. It's just some objects even if I get them to pass through they bump it..
When you're asked to provide a code snippet for the original post, you're supposed to actually provide the code you have that's related to the issue. That way, we can tell you that you did it all wrong and need to start over what you did right and wrong, and how to improve.

Here's a basic example of how to use Cross():
// Override Cross() for the type you're trying to give conditional density to
// (the wall, in your case)
// Note: there is no reason to override the Cross() of the types of movers involved.

obj/conditional_density

// override the Cross() proc, which takes one argument:
// * Crosser: the movable atom that's trying to intersect src
// (src is obviously the conditional_density obj)
Cross(atom/movable/Crosser)

// Implement the conditions yourself.
// Could use istype() or collision flags or a proc of the Crosser.

if(/* Crosser is a projectile */)
return TRUE

if(/* Crosser is a mob */)
// pick one:

// * if you want to ignore the mob's density:
return FALSE

// * if you want to allow non-dense mobs through:
return !Crosser.density

// If none of the above cases were handled,
// (Crosser is neither a projectile nor a mob)
// return the default result (as if you didn't override Cross())
return ..()
Yes thank you and sorry I got though.