attribute write lock
authornveid <nveid@comcast.net>
Mon, 11 Sep 2006 05:59:58 +0000 (05:59 +0000)
committernveid <nveid@comcast.net>
Mon, 11 Sep 2006 05:59:58 +0000 (05:59 +0000)
src/attrib.c

index a9c06f80728677f07373038aaa1a94dd57a20f37..191bc2fbc233d67abaed4985e8fa58e7b16bdd7c 100644 (file)
@@ -148,6 +148,10 @@ int cannot_write_this_attr_internal(dbref player, ATTR *attr, dbref obj, char sa
   if(!controls(player, lock_owner) && AL_WLock(attr) != TRUE_BOOLEXP && !eval_boolexp(player, AL_WLock(attr), obj, NULL))
     return 1;
 
+  /* As well if no lock is set.. and they don't controlt he player in the first place.. then they obviously can't.. */
+  if(AL_WLock(attr) == TRUE_BOOLEXP && !controls(player, obj))
+    return 1;
+
   return 0;
 }
 /*======================================================================*/