FIXED players may no longer teleport through exits
authorAri Johnson <ari@cobramush.org>
Tue, 20 Feb 2007 21:28:52 +0000 (21:28 +0000)
committerAri Johnson <ari@cobramush.org>
Tue, 20 Feb 2007 21:28:52 +0000 (21:28 +0000)
src/wiz.c

index f1d2b04546cf76e869dcb3e85cc207c7ca5c9878..afb16609475fa94ca4fbd6fb8f88a06c37015251 100644 (file)
--- a/src/wiz.c
+++ b/src/wiz.c
@@ -558,13 +558,17 @@ do_teleport(dbref player, const char *arg1, const char *arg2, int silent,
       return;
     } else {
       /* attempted teleport to an exit */
-      if (Tel_Thing(player, victim) || controls(player, victim)
-         || controls(player, Location(victim)))
+      if ((Tel_Thing(player, victim) || controls(player, victim)
+          || controls(player, Location(victim)))
+         && !Fixed(Owner(victim)) && !Fixed(player)) {
        do_move(victim, to, 0);
-      else
-       notify_format(victim,
-                     T("%s tries to impose his will on you and fails."),
-                     Name(player));
+      } else {
+       notify(player, T("Permission denied."));
+       if (victim != player)
+         notify_format(victim,
+                       T("%s tries to impose his will on you and fails."),
+                       Name(player));
+      }
     }
   }
 }