BIS 3325 Home Page The Prior Page The Next Page
Middlesex Logo

Lab 2

  1. We're going to start off playing with Buckland's miner code.
  2. I don't care if you download his C++ code, or use my (admittedly inferior) C# version. Get it.
  3. For the C++ code I grabbed it from www.wordware.com/files/ai as suggested on page xxi. I did it in gnu g++ on cygwin and had to turn off some of the text colours. I didn't understand how he initialized variables with the : in Miner.cpp. I also don't really understand how he's creating new states, but I have a rough idea.
  4. As we're using C#, I did a quick hack to stick it into C#. Grab the file minerC#.rar off my server. You'll have to save as minerC#.rar or convert it (I don't think my server will serve up .rar files.).
  5. Now that you have something, get it running. (4 points)
  6. You should get something like the figure on page 51.
  7. Futz around with it a bit so you get a feel for it. Change some messages. Put some print stubs in. Change some constants.
  8. If you're using C# can you figure out how to get the end of the window to display instead of scrolling each time? (1 point)
  9. Try something slightly better. Add in a new state (gone fishin). Whenever he is anywhere, he has a 10% chance of just giving up and going fishin. After fishin, he goes home. (2 points)
  10. Try to add another state of your own. (1 point)
  11. Can you put Elsa in? (If you're using C#, you might want to try some subclassing.) (1 point)
  12. Can you add message passing?(1 point)
  13. What's going to happen when there are lots of agents communicating, and effecting each other?