- exported the drawer function of the colorpicker menu.

This commit is contained in:
Christoph Oelckers 2017-02-10 13:20:19 +01:00
commit 8c780ab7ff
15 changed files with 211 additions and 127 deletions

View file

@ -498,12 +498,15 @@ static void ListEnd(VMVa_List &tags)
int ListGetInt(VMVa_List &tags)
{
if (tags.curindex < tags.numargs && tags.args[tags.curindex].Type == REGT_INT)
if (tags.curindex < tags.numargs)
{
return tags.args[tags.curindex++].i;
if (tags.args[tags.curindex].Type == REGT_INT)
{
return tags.args[tags.curindex++].i;
}
ThrowAbortException(X_OTHER, "Invalid parameter in draw function, int expected");
}
ThrowAbortException(X_OTHER, "Invalid parameter in draw function, int expected");
return 0;
return TAG_DONE;
}
static inline double ListGetDouble(VMVa_List &tags)
@ -1350,18 +1353,18 @@ void DCanvas::Clear (int left, int top, int right, int bottom, int palcolor, uin
}
}
//==========================================================================
//
// no-ops. This is so that renderer backends can better manage the
// processing of the subsector drawing in the automap
//
//==========================================================================
void DCanvas::StartSimplePolys()
{}
void DCanvas::FinishSimplePolys()
{}
DEFINE_ACTION_FUNCTION(_Screen, Clear)
{
PARAM_PROLOGUE;
PARAM_INT(x1);
PARAM_INT(y1);
PARAM_INT(x2);
PARAM_INT(y2);
PARAM_INT(color);
PARAM_INT_DEF(palcol);
screen->Clear(x1, y1, x2, y2, palcol, color);
return 0;
}
//==========================================================================
//