diff options
author | Nipun Garg | 2019-06-23 06:50:09 +0530 |
---|---|---|
committer | Eugene Sandulenko | 2019-09-03 17:16:57 +0200 |
commit | da528445f905011a93b9346a9345aa39abc98acb (patch) | |
tree | 6672cf97ecbd92e5aadddb0c6856c44191386a78 | |
parent | 66a7c617df1be61beed21134b057765460d8bea2 (diff) | |
download | scummvm-rg350-da528445f905011a93b9346a9345aa39abc98acb.tar.gz scummvm-rg350-da528445f905011a93b9346a9345aa39abc98acb.tar.bz2 scummvm-rg350-da528445f905011a93b9346a9345aa39abc98acb.zip |
HDB: Add cineDialog()
-rw-r--r-- | engines/hdb/ai-cinematic.cpp | 12 | ||||
-rw-r--r-- | engines/hdb/ai.h | 1 |
2 files changed, 13 insertions, 0 deletions
diff --git a/engines/hdb/ai-cinematic.cpp b/engines/hdb/ai-cinematic.cpp index 2b3ad716a3..6dbe669dc0 100644 --- a/engines/hdb/ai-cinematic.cpp +++ b/engines/hdb/ai-cinematic.cpp @@ -366,6 +366,18 @@ void AI::cineEntityFace(const char *luaName, double dir) { _cine.push_back(cmd); } +void AI::cineDialog(const char *title, const char *string, int seconds) { + CineCommand *cmd = new CineCommand; + strcpy(cmd->title, title); + strcpy(cmd->string, string); + cmd->delay = seconds; + cmd->start = 1; + if (!title || !string) + warning("cineDialog: Missing Title or Text"); + cmd->cmdType = C_DIALOG; + _cine.push_back(cmd); +} + void AI::cineUse(const char *entName) { CineCommand *cmd = new CineCommand; strcpy(cmd->string, entName); diff --git a/engines/hdb/ai.h b/engines/hdb/ai.h index a88a703b45..76126f85a5 100644 --- a/engines/hdb/ai.h +++ b/engines/hdb/ai.h @@ -720,6 +720,7 @@ public: void cineSetEntity(const char *entName, int x, int y, int level); void cineMoveEntity(const char *entName, int x, int y, int level, int speed); void cineEntityFace(const char *luaName, double dir); + void cineDialog(const char *title, const char *string, int seconds); void cineUse(const char *entName); void cineFadeIn(bool isBlack, int steps); void cineFadeOut(bool isBlack, int steps); |