Exemplo n.º 1
0
bool Logic::caculate()
{
	time +=sta.dt;
	if (escape) return true;
	run_me();
	run_enemy();
	run_things(sta.dt);
	swap_me();
	swap_enemy();
	update_explode();
	delete_out();
	background->update(me->blood,me->life,me->bigshot);
	set_result(time);
	return false;
}
Exemplo n.º 2
0
reconstruct_path(char *s, char *t, int i, int j)
{
/*printf("trace (%d,%d)\n",i,j);*/

	if (m[i][j].parent == -1) return;

	if (m[i][j].parent == MATCH) {
		reconstruct_path(s,t,i-1,j-1);
		match_out(s, t, i, j);
		return;
	}
        if (m[i][j].parent == INSERT) {
                reconstruct_path(s,t,i,j-1);
		insert_out(t,j);
		return;
        }
        if (m[i][j].parent == DELETE) {
                reconstruct_path(s,t,i-1,j);
		delete_out(s,i);
		return;
        }
}