diff options
author | Ľubomír Remák | 2018-02-25 04:14:32 +0100 |
---|---|---|
committer | Eugene Sandulenko | 2018-08-25 23:12:01 +0200 |
commit | 3672ea55720666acfd64b6df01b35d0727d6be78 (patch) | |
tree | 58e77efe67e9381c788c30d1e75b518a984c2020 /engines/mutationofjb/commands/seqcommand.cpp | |
parent | f7d5a825a053199ddbf4d7c564e84e9f9709d958 (diff) | |
download | scummvm-rg350-3672ea55720666acfd64b6df01b35d0727d6be78.tar.gz scummvm-rg350-3672ea55720666acfd64b6df01b35d0727d6be78.tar.bz2 scummvm-rg350-3672ea55720666acfd64b6df01b35d0727d6be78.zip |
MUTATIONOFJB: Continue implementation of if/else script commands.
Diffstat (limited to 'engines/mutationofjb/commands/seqcommand.cpp')
-rw-r--r-- | engines/mutationofjb/commands/seqcommand.cpp | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/engines/mutationofjb/commands/seqcommand.cpp b/engines/mutationofjb/commands/seqcommand.cpp index ab98497f21..22d1c9051b 100644 --- a/engines/mutationofjb/commands/seqcommand.cpp +++ b/engines/mutationofjb/commands/seqcommand.cpp @@ -20,10 +20,20 @@ * */ -#include "seqcommand.h" +#include "mutationofjb/commands/seqcommand.h" +#include "common/translation.h" namespace MutationOfJB { +void SeqCommandParser::transition(ScriptParseContext &, Command * oldCommand, Command * newCommand) { + if (!oldCommand || !newCommand) { + warning(_("Unexpected empty command in transition")); + return; + } + + static_cast<SeqCommand *>(oldCommand)->setNextCommand(newCommand); +} + void SeqCommand::setNextCommand(Command *nextCommand) { _nextCommand = nextCommand; |