64,649
社区成员
发帖
与我相关
我的任务
分享
#pragma once
enum { THERE, };
enum { FOREVER, };
class Emotion
{
public:
Emotion() {}
~Emotion() {}
Emotion& operator++() { return *this; }
Emotion& operator--() { return *this; }
Emotion& operator=(const int& other) { return *this; }
Emotion& operator=(const Emotion& other) { return *this; }
public:
int Happyness;
int Love;
int Position;
};
class Heart
{
public:
Heart() {}
~Heart() {}
public:
int Position;
};
class Hand
{
public:
Hand() {}
~Hand() {}
void Hold(const Hand& hand) {}
public:
int HoldTime;
};
class Person
{
public:
Person() {}
~Person() {}
bool Meet(const Person& person) { return true; }
bool Miss(const Person& person) { return true; }
bool Love(const Person& person) { return true; }
bool Follow(const Person& person) { return true; }
public:
Emotion Emotion;
Heart Heart;
Hand Hand;
int Position;
int Arms;
};
class CodeLife
{
public:
CodeLife(void) {}
~CodeLife(void) {}
static void Story()
{
Person you, me;
if ( you.Meet(me) || !you.Meet(me) )
{
me.Position = THERE;
me.Emotion.Happyness--;
me.Emotion.Happyness++;
}
if ( you.Miss(me) || !you.Miss(me) )
{
me.Emotion = THERE;
me.Emotion++;
me.Emotion--;
}
if ( you.Love(me) || !you.Love(me) )
{
me.Emotion.Love = THERE;
me.Emotion.Love++;
me.Emotion.Love--;
}
if ( you.Follow(me) || !you.Follow(me) )
{
me.Hand.Hold(you.Hand);
me.Hand.HoldTime = FOREVER;
}
if ( you.Position == me.Arms || me.Position == you.Heart.Position )
{
do
{
me.Emotion.Love = you.Emotion.Love = FOREVER;
} while ( true );
}
}
};
int _tmain(int argc, _TCHAR* argv[])
{
CodeLife::Story();
return 0;
}