void FairyTale() { CMonster* dragon = new CMonster(); CObject* kingdom = new CObject(); CPerson* prince = NULL; CPerson* princess = new CPerson(Type.Female); princess->home = false; while(!princess->home) { prince = new CPerson(Type.Male); if(prince->strength() >= dragon->strength()) { delete(dragon); prince += princess + kingdom / 2; princess->home= true; } else { prince -= head; delete(prince); } } }
Thursday, July 30, 2009
Fairy Tale C++
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment