- moved stats.cpp to common.
This commit is contained in:
parent
fa99fc5346
commit
932f5c64c2
9 changed files with 39 additions and 14 deletions
|
|
@ -34,6 +34,8 @@
|
|||
#include "vm.h"
|
||||
#include "c_buttons.h"
|
||||
|
||||
F2DDrawer* twod;
|
||||
|
||||
EXTERN_CVAR(Float, transsouls)
|
||||
|
||||
IMPLEMENT_CLASS(DShape2DTransform, false, false)
|
||||
|
|
|
|||
|
|
@ -173,5 +173,10 @@ public:
|
|||
bool mIsFirstPass = true;
|
||||
};
|
||||
|
||||
extern F2DDrawer* twod;
|
||||
void DrawText(F2DDrawer* drawer, FFont* font, int normalcolor, double x, double y, const char* string, int tag_first, ...);
|
||||
void DrawText(F2DDrawer* twod, FFont* font, int normalcolor, double x, double y, const char32_t* string, int tag_first, ...);
|
||||
void DrawChar(F2DDrawer* drawer, FFont* font, int normalcolor, double x, double y, int character, int tag_first, ...);
|
||||
void DrawTexture(F2DDrawer* drawer, FTexture* img, double x, double y, int tags_first, ...);
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -433,6 +433,25 @@ void DFrameBuffer::DrawText(FFont *font, int normalcolor, double x, double y, co
|
|||
DrawTextCommon(font, normalcolor, x, y, string, parms);
|
||||
}
|
||||
|
||||
void DrawText(F2DDrawer *twod, FFont* font, int normalcolor, double x, double y, const char32_t* string, int tag_first, ...)
|
||||
{
|
||||
Va_List tags;
|
||||
DrawParms parms;
|
||||
|
||||
if (font == NULL || string == NULL)
|
||||
return;
|
||||
|
||||
va_start(tags.list, tag_first);
|
||||
bool res = screen->ParseDrawTextureTags(nullptr, 0, 0, tag_first, tags, &parms, true);
|
||||
va_end(tags.list);
|
||||
if (!res)
|
||||
{
|
||||
return;
|
||||
}
|
||||
screen->DrawTextCommon(font, normalcolor, x, y, string, parms);
|
||||
}
|
||||
|
||||
|
||||
void DFrameBuffer::DrawText(FFont *font, int normalcolor, double x, double y, const char *string, VMVa_List &args)
|
||||
{
|
||||
DrawParms parms;
|
||||
|
|
|
|||
|
|
@ -357,6 +357,7 @@ class FTexture;
|
|||
class DFrameBuffer
|
||||
{
|
||||
friend void DrawText(F2DDrawer* drawer, FFont* font, int normalcolor, double x, double y, const char* string, int tag_first, ...);
|
||||
friend void DrawText(F2DDrawer* twod, FFont* font, int normalcolor, double x, double y, const char32_t* string, int tag_first, ...);
|
||||
friend void DrawChar(F2DDrawer* drawer, FFont* font, int normalcolor, double x, double y, int character, int tag_first, ...);
|
||||
friend void DrawTexture(F2DDrawer* drawer, FTexture* img, double x, double y, int tags_first, ...);
|
||||
protected:
|
||||
|
|
@ -681,8 +682,4 @@ public:
|
|||
};
|
||||
|
||||
|
||||
void DrawText(F2DDrawer* drawer, FFont* font, int normalcolor, double x, double y, const char* string, int tag_first, ...);
|
||||
void DrawChar(F2DDrawer* drawer, FFont* font, int normalcolor, double x, double y, int character, int tag_first, ...);
|
||||
void DrawTexture(F2DDrawer* drawer, FTexture* img, double x, double y, int tags_first, ...);
|
||||
|
||||
#endif // __V_VIDEO_H__
|
||||
|
|
|
|||
|
|
@ -29,7 +29,7 @@
|
|||
#include "actor.h"
|
||||
#include "i_time.h"
|
||||
#include "g_game.h"
|
||||
#include "gamedata/fonts/v_text.h"
|
||||
#include "v_text.h"
|
||||
|
||||
#include "hwrenderer/utility/hw_clock.h"
|
||||
#include "hwrenderer/utility/hw_vrmodes.h"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue