git @ Cat's Eye Technologies Samovar / c16af8e
Attempt to fix the near() rules. Chris Pressey 6 years ago
2 changed file(s) with 6 addition(s) and 7 deletion(s). Raw diff Collapse all Expand all
4949
5050 ### TODO
5151
52 * Implement a simple equality rule, `eq(?X,?X)`, as a built-in.
53 This is basically necessary to stop characters from talking to
54 themselves, nodding to themselves, ET CETERA.
52 * Implement a "wildcard" variable that will match anything *without* binding it.
5553
5654 ### TODO for v0.3
5755
5856 * Consider what it would take to add a predicate that evaluates to whether
5957 a given action has been taken previously or not.
6058 * Consider macros.
61 * Consider a "wildcard" variable that will match anything *without* binding it.
6259 * Consider making "wildcard" work such that you can say `¬holding(?_, club)`
6360 to mean "if no one is holding the club".
1212 // sitting_on(?A,?S)
1313 // empty(?S) ?S is a seat that is not currently occupied.
1414 // fenestration(?P) ?P is a prop that can be looked out of to the outside.
15 // near(?A,?P) ?A is an actor who is near or next to prop ?P.
15 // near(?A) ?A is near a prop.
16 // near_to(?A,?P) ?A is an actor who is near or next to prop ?P.
1617 // described(?P) ?P is a prop that has been described.
1718
1819 // topic(?T) ?T is a topic of conversation.
4445
4546 [actor(?A),fenestration(?P)] ?A looked out the ?P. []
4647
47 [actor(?A),!sitting(?A),prop(?P),!near(?A,?P)] ?A walked over to the ?P. [near(?A,?P)] // TODO: retract all other near
48 [actor(?A),near(?A,?P)] ?A examined the ?P closely. []
48 [actor(?A),!sitting(?A),prop(?P),!near(?A)] ?A walked over to the ?P. [near(?A),near_to(?A,?P)]
49 [actor(?A),near_to(?A,?P)] ?A examined the ?P closely. []
50 [actor(?A),near_to(?A,?P)] ?A walked away from the ?P. [!near(?A),!near_to(?A,?P)]
4951
5052 [prop(?P),!described(?P)] Nearby there was a ?P. [described(?P)]
5153