My System
- The way my systme works is that I get C# and clips running
together. C# starts clips.
- Each agent gets an update
call regularly (in XNA in C#).
- In the update, I make some calls to clips. I clear the
old rules and facts.
- I then set the new facts from C#, things like Random Ten and
Near Sun.
- Then I load the agent1.clp rules for the left agent, or the agent2.clp
rules for the right one.
- Then I run clips which goes until no more rules can fire.
- I then get the facts I care back from Clips and act on them.
- A good place to look for this is in the Update function of agent1.cs
- The form saves the rules into agent2.clp. If you want to play
agent1, just copy agent2.clp to agent1.clp.