Example #1
0
void IN_Drawer(void)
{
	static int oldinterstate;

	if(!intermission)
	{
		return;
	}
	if(interstate == 3)
	{
		return;
	}
	UpdateState |= I_FULLSCRN;
	if(oldinterstate != 2 && interstate == 2)
	{
		S_StartSound(NULL, sfx_pstop);
	}
	oldinterstate = interstate;
	switch(interstate)
	{
		case 0: // draw stats
			IN_DrawStatBack();
			switch(gametype)
			{
				case SINGLE:
					IN_DrawSingleStats();
					break;
				case COOPERATIVE:
					IN_DrawCoopStats();
					break;
				case DEATHMATCH:
					IN_DrawDMStats();
					break;
			}
			break;
		case 1: // leaving old level
			if(gameepisode < 4)
			{
				V_DrawPatch(0, 0, patchINTERPIC);
				IN_DrawOldLevel();
			}
			break;
		case 2: // going to the next level
			if(gameepisode < 4)
			{
				V_DrawPatch(0, 0, patchINTERPIC);
				IN_DrawYAH();
			}
			break;
		case 3: // waiting before going to the next level
			if(gameepisode < 4)
			{
				V_DrawPatch(0, 0, patchINTERPIC);
			}
			break;
		default:
			I_Error("IN_lude:  Intermission state out of range.\n");
			break;
	}
}
Example #2
0
void IN_Drawer(void)
{
    static int oldInterState;
    dgl_borderedprojectionstate_t bp;

    if(!intermission || interState > 3)
    {
        return;
    }
    if(interState == 3)
    {
        return;
    }

    if(oldInterState != 2 && interState == 2)
    {
        S_LocalSound(SFX_PSTOP, NULL);
    }

    if(interState != -1)
        oldInterState = interState;

    GL_ConfigureBorderedProjection(&bp, BPF_OVERDRAW_MASK|BPF_OVERDRAW_CLIP, SCREENWIDTH, SCREENHEIGHT, Get(DD_WINDOW_WIDTH), Get(DD_WINDOW_HEIGHT), cfg.inludeScaleMode);
    GL_BeginBorderedProjection(&bp);

    switch(interState)
    {
    case -1:
    case 0: // Draw stats.
        IN_DrawStatBack();
        switch(gameType)
        {
        case SINGLE:
            IN_DrawSingleStats();
            break;
        case COOPERATIVE:
            IN_DrawCoopStats();
            break;
        case DEATHMATCH:
            IN_DrawDMStats();
            break;
        }
        break;

    case 1: // Leaving old level.
        if(wbs->episode < 3)
        {
            DGL_Enable(DGL_TEXTURE_2D);

            DGL_Color4f(1, 1, 1, 1);
            GL_DrawPatchXY(dpInterPic, 0, 0);

            DGL_Disable(DGL_TEXTURE_2D);

            IN_DrawOldLevel();
        }
        break;

    case 2: // Going to the next level.
        if(wbs->episode < 3)
        {
            DGL_Enable(DGL_TEXTURE_2D);

            DGL_Color4f(1, 1, 1, 1);
            GL_DrawPatchXY(dpInterPic, 0, 0);
            IN_DrawYAH();

            DGL_Disable(DGL_TEXTURE_2D);
        }
        break;

    case 3: // Waiting before going to the next level.
        if(wbs->episode < 3)
        {
            DGL_Enable(DGL_TEXTURE_2D);

            DGL_Color4f(1, 1, 1, 1);
            GL_DrawPatchXY(dpInterPic, 0, 0);

            DGL_Disable(DGL_TEXTURE_2D);
        }
        break;

    default:
        Con_Error("IN_lude:  Intermission state out of range.\n");
        break;
    }

    GL_EndBorderedProjection(&bp);
}