Exemplo n.º 1
0
static void doIntro()
{
	Entity *e;
	Target *t;

	e = getFreeEntity();

	if (e == NULL)
	{
		showErrorAndExit("No free slots to add Edgar's Soul");
	}

	t = getTargetByName("EDGAR_SOUL_TARGET");

	if (t == NULL)
	{
		showErrorAndExit("Azirel cannot find target");
	}

	loadProperties("boss/edgar_soul", e);

	e->x = t->x;
	e->y = t->y;

	e->startY = e->y;

	e->alpha = 0;

	e->action = &soulWait;

	e->draw = &drawLoopingAnimationToMap;

	e->type = ENEMY;

	e->thinkTime = e->maxThinkTime;

	self->head = e;

	e->target = self;

	e->mental = 0;

	setEntityAnimation(e, "STAND");

	self->flags |= LIMIT_TO_SCREEN;

	initBossHealthBar();

	self->takeDamage = &takeDamage;

	self->action = &attackFinished;

	checkToMap(self);

	becomeTransparent();

	setEntityAnimation(self, "STAND");

	addScythe();
}
Exemplo n.º 2
0
static void init()
{
	if (self->active == TRUE)
	{
		initBossHealthBar();

		self->action = &entityWait;

		self->thinkTime = 180;

		self->health = 0;
	}
}
Exemplo n.º 3
0
static void initialise()
{
	if (self->active == TRUE)
	{
		setContinuePoint(FALSE, self->name, &continuePoint);

		initBossHealthBar();

		self->thinkTime = 60;

		self->maxThinkTime = 0;

		self->action = &entityWait;
	}

	checkToMap(self);
}
Exemplo n.º 4
0
static void initialise()
{
    Target *t;

    self->flags |= NO_DRAW;

    if (self->active == TRUE)
    {
        if (cameraAtMinimum())
        {
            createBody();

            centerMapOnEntity(NULL);

            t = getTargetByName("SNAKE_BOSS_TARGET_RIGHT");

            if (t == NULL)
            {
                showErrorAndExit("Snake boss cannot find target");
            }

            setSnakePosition(t->x, t->y);

            self->targetY = self->y - 64;

            self->thinkTime = 60;

            self->face = LEFT;

            self->flags |= LIMIT_TO_SCREEN;

            self->action = &riseUp;

            playDefaultBossMusic();

            initBossHealthBar();

            setContinuePoint(FALSE, self->name, NULL);
        }
    }
}
Exemplo n.º 5
0
static void introPause()
{
	checkToMap(self);

	if (self->startX <= 0)
	{
		self->takeDamage = &takeDamage;

		self->action = &attackFinished;

		playDefaultBossMusic();

		initBossHealthBar();

		self->touch = &entityTouch;

		self->mental = 15;

		self->endY = self->y;
	}
}
Exemplo n.º 6
0
static void init()
{
	if (self->active == TRUE)
	{
		initBossHealthBar();

		setContinuePoint(FALSE, self->name, &continuePoint);

		self->thinkTime = 120;

		self->action = &teleportAway;

		self->maxThinkTime = 0;

		self->startX = 0;

		self->startY = -1;
	}

	checkToMap(self);
}
Exemplo n.º 7
0
static void doIntro()
{
	self->thinkTime--;

	if (self->thinkTime <= 0)
	{
		self->flags |= LIMIT_TO_SCREEN;

		playDefaultBossMusic();

		initBossHealthBar();

		self->action = &attackFinished;

		self->startX = 0;

		self->endX = 0;

		self->thinkTime = 0;
	}

	checkToMap(self);
}
Exemplo n.º 8
0
static void introPause()
{
	hover();

	self->dirX = 0.5;

	checkToMap(self);

	self->thinkTime--;

	if (self->thinkTime <= 0)
	{
		playDefaultBossMusic();

		initBossHealthBar();

		self->action = &entityWait;

		self->flags |= LIMIT_TO_SCREEN;
	}

	facePlayer();
}