ID:236798
 
What if invisible or invisibility was a list of type's or pointers?

For example,

mob
iDisappear
Click()
usr << "I go poof!"
usr.invisibles += src
sleep(20)
usr << "... and I come back!"
usr.invisibles -= src


Or

turf
yellow_flowers
Click()
usr << "You can't see us!"
usr.invisibles += /turf/yellow_flowers
sleep(20)
usr.invisibles -= /turf/yellow_flowers


Basically, anything in this list would not be visible to the client.

Feel free to expand this idea...
It's been suggested a few times before to pretty high regard but not much came of it. For now though you can use Visibility Groups by Forum_account.
I think invisibility should be versatile so that it can support any kind of value... Anything other than a number requires a match to the see_invisible in order to be seen
I think types and actual references are fine... I'm not sure how much overhead there would be to support ANY value, but it doesn't seem necessary. You almost always have access to at least the type path or the actual reference if you know you want something to be invisible.
I think some of the processing is handled on the client. If your instance of Dream Seeker knows the invisibility value for each atom and your see_invisible value, it can easily determine what you can and can't see. The more complex this gets, the more information your client has to have.

As Nadrew mentioned, the Visibility Groups library can easily handle this:

obj
yellow_flower
New()
..()

// add this object to the "yellow flower" group
vis = new(src)
vis.is_a("yellow flower")

Click()
// remove the mob's ability to see yellow flowers,
// then add it back.
usr.vis.cant_see("yellow flower")
sleep(20)
usr.vis.can_see("yellow flower")

mob
New()
..()

// make mobs able to see yellow flowers by default
vis = new(src)
vis.can_see("yellow flower")