Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- (defrule searchRepeats
- (declare (salience 1000));
- ?tmpNode <- (Node
- (status 0)
- (id ?tId)
- )
- =>
- (assert (IdVF ?tId))
- )
- (defrule searchRepeatsCont
- (declare (salience 950));
- ?nId <- (IdVF ?tId)
- ?tmpNode <- (State
- (xy00 ?s00) (xy10 ?s10) (xy20 ?s20)
- (xy01 ?s01) (xy11 ?s11) (xy21 ?s21)
- (xy02 ?s02) (xy12 ?s12) (xy22 ?s22)
- (id ?tId))
- (State
- (xy00 ?s00) (xy10 ?s10) (xy20 ?s20)
- (xy01 ?s01) (xy11 ?s11) (xy21 ?s21)
- (xy02 ?s02) (xy12 ?s12) (xy22 ?s22)
- (status 2)
- )
- =>
- (retract ?tmpNode)
- (retract ?nId)
- )
- (defrule searchRepeatEnd
- (declare (salience 800));
- ?nId <- (IdVF ?tId)
- ?tmpNode <- (State
- (id ?tId)
- )
- =>
- (modify ?tmpNode(status 1))
- (retract ?nId)
- )
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement