RhostMUSH / trunk

RhostMUSH 4.0: This is the official main repository of RhostMUSH. Visit us at rhostdev.mushpark.com 4201
23 stars 21 forks source link

sweep() for listeners #200

Closed Hope-Shangrila closed 6 months ago

Hope-Shangrila commented 8 months ago

We use lcon(here, listen) in our main parent room to help identify spying objects, such as puppets, audible exits, audible rooms, players with a specific @listen attribute... Players get a generic message in the room "There are listening devices in this room. Everything you do and say may be being forwarded to other people." Players then have access to a global command to identify what those spying objects are, the destination of the messages, and who might be connected at the destination. This allows them to make an informed decision as to whether they wish to play in that location or move elsewhere.

It is currently selecting all players, which is not what we are expecting, we only want the players with an @listen attribute. We would have to complicate the code in both places to run through the items lcon(here, listen) picks up and test for hasattr(##,listen).

It has been suggested that a functional version of @sweep, sweep(), detecting listeners would solve this problem.

mrsenile commented 6 months ago

This was added with https://github.com/RhostMUSH/trunk/commit/8eb633b6669fd6edd0c45806438f568361ee54c5