2 new presentation commands: CLS and CALL

git-svn-id: svn://svn.code.sf.net/p/sc2/code/trunk@1469 8092fc87-c524-0410-9efc-e669fe64eaf9
This commit is contained in:
avolkov
2005-01-20 02:04:18 +00:00
parent f4ba999534
commit a45b8d389a
+18
View File
@@ -431,6 +431,24 @@ DoPresentation (PVOID pIS)
{ /* fade to white */
return DoFadeScreen (pPIS, pStr, FadeAllToWhite);
}
else if (strcmp (Opcode, "CLS") == 0)
{ /* clear screen */
RECT r;
LockMutex (GraphicsLock);
GetContextClipRect (&r);
r.corner.x = r.corner.y = 0;
/* paint black rect over screen */
SetContextForeGroundColor (BUILD_COLOR (
MAKE_RGB15 (0x0, 0x0, 0x0), 0x00));
DrawFilledRectangle (&r);
UnlockMutex (GraphicsLock);
}
else if (strcmp (Opcode, "CALL") == 0)
{ /* call another script */
CopyTextString (pPIS->Buffer, sizeof(pPIS->Buffer), pStr);
ShowPresentation (pPIS->Buffer);
}
else if (strcmp (Opcode, "NOOP") == 0)
{ /* no operation - must be a comment in script */
/* do nothing */