1
0
Fork 0
mirror of https://github.com/ganelson/inform.git synced 2024-06-26 12:10:44 +03:00

patch to can't eat other people's food rule

This commit is contained in:
Zed Lopez 2022-05-02 21:15:11 -07:00
parent 31c156b2b5
commit 6512ed0823

View file

@ -529,10 +529,14 @@ Check an actor eating (this is the can't eat clothing without removing it first
if the actor is wearing the noun, stop the action.
Check an actor eating (this is the can't eat other people's food rule):
if the noun is enclosed by a person (called the owner) who is not the actor:
if the actor is the player:
say "[The owner] [might not appreciate] that." (A);
stop the action.
if the actor does not hold the noun and the noun is enclosed by a person:
let the owner be the holder of the noun;
while the owner is not a person:
now the owner is the holder of the owner;
if the owner is not the actor:
if the actor is the player and the action is not silent:
say "[The owner] [might not appreciate] that." (A);
stop the action;
Check an actor eating (this is the can't eat portable food without carrying it rule):
if the noun is portable and the actor is not carrying the noun: