MOO-cows Mailing List Archive

[Prev][Next][Index][Thread]

Why #1 is false?



I was coding something like:
....
if (!room:match(object))
player:tell("I can not see that here.");
return;
endif
....
And I was surprised by the fact that it allways tells "I can not see that
here"
I found at Pavel's Manual that: "all objects numbers are false"  (4.1.6)
So:
;!#-1 -> 1
;!#0 -> 1
;!#1 -> 1

Why is this?
I think it is more logical to be false for (#0 ?), #-1, #-2, #-3 and true
for any positive object, do not?
Or maybe to work like valid() ?
Just pure curiosity, but why is this done on this way?
Thanks



Home | Subject Index | Thread Index