Latest Code – Awesome Paper.. AND FANS!!

November 23rd, 2007

ch-ch-check it.

morphemeat.zip

Jack and I have been working on this all night. Not 100% done yet.. but it’s come a long way. The paper is cool. The fans are cooler (but annoyingly so. You can disable them with ‘f’).

There’s quite a lot we can do with the map. We can do all sorts of things with the visuals (I’m thinking of creating a tiny floating paper object, which ‘snaps’ off the paper and flies away)

And more importantly, we can try to make a more interesting & perhaps dynamic map. Chuck some obstacles in there.. Jack’s day night thing could be turned into an actual desk lamp. Fan?

The more stuff we get done on the map, the better it’ll look.. and the more interesting our AI can be. More things to learn, interact with, etc..

 Anyway, check out the code.

Ben.

P.S. Jack, Igor suggested we try masks. Gives us more control, so I’ve had to redo your images as masks. Also, it’s not going to be hard at all to make stages of paper eating. So we should do that, maybe at 0(done), 75,150,255(done).. While it may look good now when they eat heaps fast.. it might look a little strange when the square suddenly disapears when eating normal speed. Anyway, plenty of stuff to work with 🙂

Paper Finer, Wooden desk and Daylight

November 22nd, 2007

remove println(dayLight); in World class, if you need to use println();

press g to toggle graphics.

morphemear.zip

will keep you updated.

fan fun

November 22nd, 2007

so awesome. morphemeaq.zip

Thursday Meeting

November 21st, 2007

Just want to confirm that we are meeting again tomorrow at 1pm. Please post a comment and say if you can make it or not.

Thanks.

New Code Version

November 20th, 2007

Just posting the newest version of the code. Finally got the AI working well enough to post. This is the first implementation of Fuzzy Logic AI. It’s basically a Fuzzy State Machine at the moment but I am hoping to expand it. The rules are also very rudimentary at this stage but I think it still works quite well.

Some minor GUI additions also:

  • Cause of Death display – So we can keep track of what is killing the creatures and aid debugging.
  • Pressing “p” will reset this – useful if you want to know what is killing the creatures at different points during the simulation.

I think that’s all. Anyway here is a link to the sketch:
Morpheme – First Fuzzy

Meeting today (tuesday) at 1pm.

November 19th, 2007

Be there.. or be square.

updated code (memory ++)

November 19th, 2007

heyo, here’s the latest AI code.

 morphemeaq.zip

Got a few new things in this one:

Read the rest of this entry »

Meeting Date Change

November 19th, 2007

Sorry for the short notice, but upon discussion with several group members the consensus was reached that the Monday (19/11) 1PM meeting should be switched to Tuesday (20/11).
I will send an email around also but please spread the word so we are clear on the meeting time.

Thanks all.

PS. For convenience meet on MSN to discuss the amalgamation of the documentation or email it.

Walking GA

November 18th, 2007

Here is the current version of the walking GA if anyone wants to have a look.

Pressing ENTER toggles the graph on/off.

Pressing BACKSPACE toggles drawing of the creatures (it runs substantially faster with drawing turned off).

They can also turn now. Hold down LEFT or RIGHT arrow keys to see.

Plenty more to do.

By the way, we’re meeting up tomorrow right? 1pm? Or am I remembering incorrectly?

Code Addition

November 18th, 2007

I quickly coded up a scroll wheel zoom feature a couple of days ago. Nick mentioned that we should probably keep the code versions as consistent as possible to avoid a big mess when combining it all at the end. So to that end here is the short snippet of code that you can all add to your sketches. I’m not posting it together with the AI because it’s not ready yet and this will just keep things consistent in the meantime.

Place this at the end of your Setup() method, right after the “//Load Sounds” stuff.

  //Mouse Wheel Zoom
  addMouseWheelListener(new java.awt.event.MouseWheelListener() {
    public void mouseWheelMoved(java.awt.event.MouseWheelEvent evt) {
      int notches = evt.getWheelRotation();
      if(notches!=0){
      float notchTemp = notches;
      zoom -= (notchTemp/100);
      }
    }
  });