Ejemplo n.º 1
0
void Mechanical::o_birdCrankStart(uint16 var, const ArgumentsArray &args) {
	MystAreaDrag *crank = getInvokingResource<MystAreaDrag>();

	uint16 crankSoundId = crank->getList2(0);
	_vm->_sound->playEffect(crankSoundId, true);

	_birdSingEndTime = 0;
	_birdCrankStartTime = _vm->_system->getMillis();

	MystAreaVideo *crankMovie = static_cast<MystAreaVideo *>(crank->getSubResource(0));
	crankMovie->playMovie();
}
Ejemplo n.º 2
0
void MystScriptParser::o_triggerMovie(uint16 var, const ArgumentsArray &args) {
	// The original has code to pause the background music before playing the movie,
	// if the movie has a sound track, as well as code to resume it afterwards. But since
	// the movie has not yet been loaded at this point, it is impossible to know
	// if the movie actually has a sound track. The code is never executed.

	int16 direction = 1;
	if (args.size() == 1)
		direction = args[0];

	// Trigger resource 6 movie overriding play direction
	MystAreaVideo *resource = getInvokingResource<MystAreaVideo>();
	resource->setDirection(direction);
	resource->playMovie();
}
Ejemplo n.º 3
0
void MystScriptParser::o_triggerMovie(uint16 op, uint16 var, uint16 argc, uint16 *argv) {
	debugC(kDebugScript, "Opcode %d: Trigger Type 6 Resource Movie..", op);
	// The original has code to pause the background music before playing the movie,
	// if the movie has a sound track, as well as code to resume it afterwards. But since
	// the movie has not yet been loaded at this point, it is impossible to know
	// if the movie actually has a sound track. The code is never executed.

	int16 direction = 1;
	if (argc == 1)
		direction = argv[0];

	debugC(kDebugScript, "\tDirection: %d", direction);

	// Trigger resource 6 movie overriding play direction
	MystAreaVideo *resource = getInvokingResource<MystAreaVideo>();
	resource->setDirection(direction);
	resource->playMovie();
}