STARK: Implement the "do nothing" command

This commit is contained in:
Bastien Bouclet 2016-06-01 18:33:20 +02:00
parent 20e98144da
commit 90ee6b02ff
3 changed files with 9 additions and 0 deletions

View file

@ -108,6 +108,8 @@ Command *Command::execute(uint32 callMode, Script *script) {
return opGameEnd();
case kInventoryOpen:
return opInventoryOpen(_arguments[1].intValue);
case kDoNothing:
return opDoNothing();
case kItem3DPlaceOn:
return opItem3DPlaceOn(_arguments[1].referenceValue, _arguments[2].referenceValue);
case kItem3DWalkTo:
@ -416,6 +418,10 @@ Command *Command::opInventoryOpen(bool open) {
return nextCommand();
}
Command *Command::opDoNothing() {
return nextCommand();
}
Command *Command::opItem3DPlaceOn(const ResourceReference &itemRef, const ResourceReference &targetRef) {
FloorPositionedItem *item = itemRef.resolve<FloorPositionedItem>();

View file

@ -82,6 +82,7 @@ public:
kInventoryOpen = 24,
kBookOfSecretsOpen = 26,
kDoNothing = 80,
kItem3DPlaceOn = 81,
kItem3DWalkTo = 82,
kItem3DFollowPath = 83,
@ -211,6 +212,7 @@ protected:
Command *opFadeScene(int32 unknown1, int32 unknown2, int32 unknown3);
Command *opGameEnd();
Command *opInventoryOpen(bool open);
Command *opDoNothing();
Command *opItem3DPlaceOn(const ResourceReference &itemRef, const ResourceReference &targetRef);
Command *opItem3DWalkTo(Script *script, const ResourceReference &itemRef, const ResourceReference &targetRef, bool suspend);
Command *opItemFollowPath(Script *script, ResourceReference itemRef, ResourceReference pathRef, uint32 speed, uint32 suspend);

View file

@ -62,6 +62,7 @@ const Command::SubTypeDesc *Command::searchSubTypeDesc(Resources::Command::SubTy
{ Resources::Command::kGameEnd, "gameEnd", kFlowNormal },
{ Resources::Command::kInventoryOpen, "inventoryOpen", kFlowNormal },
{ Resources::Command::kBookOfSecretsOpen, "bookOfSecretsOpen", kFlowNormal },
{ Resources::Command::kDoNothing, "doNothing", kFlowNormal },
{ Resources::Command::kItem3DPlaceOn, "item3DPlaceOn", kFlowNormal },
{ Resources::Command::kItem3DWalkTo, "item3DWalkTo", kFlowNormal },
{ Resources::Command::kItem3DFollowPath, "item3DFollowPath", kFlowNormal },