This site requires JavaScript, please enable it in your browser!
Greenfoot back
kaatja
kaatja wrote ...

2012/12/20

Grow method. Need help :(

kaatja kaatja

2012/12/20

#
So im working on a scenario and I want that my baby.class grows to a child.class, but I dont know how to do this. Im sorry for my english, Im german :) This is for the baby, I want, that it meets the Wissenschaftler.class (german word) it grows and becomes an other class.. Please help me!! if (canSee(Wissenschaftler.class)) { }
erdelf erdelf

2012/12/20

#
pls write exactly what you want, if you cant in english, write it in german
danpost danpost

2012/12/20

#
if (canSee(Wissenschaftler.class))
{
    getWorld().addObject(new child(), getX(), getY());
    getWorld().removeObject(this);
}
You need to login to post a reply.