Adventure Game Studio

AGS Support => Advanced Technical Forum => Topic started by: on Fri 13/02/2004 23:07:50

Title: Can't make movies run
Post by: on Fri 13/02/2004 23:07:50
I'm making an adventure game, and I want to make it play movie files to keep the story interesting  ::) ,  but the game plays one movie and won't play another!

The movie files have the .mov extension, for Quicktime Movie - I know the FAQ says it can only play .mpg and .avi files, but these seem to work for the moment.  In the game, you're supposed to recover some evidence from a security camera.  When you touch it, it uses this script line:

PlayVideo ("Robbery.mov", 1, 3);

Which also works the first time.  But when I continue through the game where another movie is played, or if I return to the camera and try to play the movie again, it comes up with this error message:

Error-unable to play video stream

That's not the EXACT error message, but it's pretty close.  If I have to go into deeper detail later in this topic, I'll tell you the EXACT message.

Could somebody please help? ???
Title: Re:Can't make movies run
Post by: Scummbuddy on Sat 14/02/2004 04:51:48
well, im sure youre going to have to convert to the mentioned movie files. it seems you've found an unsupported format on ags, and for the error mentioned, its proof that its not approved for use.  yeah, thats cool that it worked the first time, but i dont believe we'll be able to fix this one. if you post up the error message, ill move this to the tech forum so CJ will get a better chance to see this post, but still, I'm going to have to say you should read up on those .avi's and such.
Title: Re:Can't make movies run
Post by: on Sat 14/02/2004 18:57:47
Here's the exact error message:

Video playing error:  Unable to play stream

I'll try converting the ".mov"s to ".avi"s soon to see if it helps.
Title: Re:Can't make movies run
Post by: on Mon 16/02/2004 22:53:08
Nope.  Doesn't help.

In fact, I get the exact same error message!  ???

I went to Windows Media Player and opened the .mov files and said "Save as."  I typed in the name with the .avi extension on it, saved, opened AGS, redid the script, played the game, and nothing has changed!!!  >:(
Title: Re:Can't make movies run
Post by: Scummbuddy on Tue 17/02/2004 01:15:00
I think you need to use an actual movie editing program to save it as a .avi file. What you did was probably movie1.avi.mov, unknowingly.
Title: Re:Can't make movies run
Post by: on Tue 17/02/2004 02:42:44
Where would I get a movie editing program, possibly free?  ???

Meanwhile, I have another question.  How would I control and play  multiple characters in my game, a la Day of the Tentacle, but with five characters instead of three?  And how would I switch among them?
Title: Re:Can't make movies run
Post by: on Wed 18/02/2004 22:10:29
Got a movie editing program, saved as .avi, put it in the game, EXACT SAME ERROR MESSAGE.

Obviously it's a problem with AGS...
Title: Re:Can't make movies run
Post by: Scummbuddy on Thu 19/02/2004 07:23:32
I wouldn't jump to conclusions so far... but we'll see what CJ has to say.
Title: Re:Can't make movies run
Post by: Gilbert on Thu 19/02/2004 07:55:43
Hmmm well, I read your line of code over, and that you set the FLAGS variable to 3, which is not documented as a supported value in the manual, the supported values are:
Quote0: the video will be played at original size, with AVI audio
1: the video will be stretched to full screen, with appropriate black borders to maintain its aspect ratio and AVI audio.
10: original size, with game audio continuing (AVI audio muted)
11: stretched to full screen, with game audio continuing (AVI audio muted)

Try setting that variable to one of teh above values and see if the prooblem's gone.

Actually I suspect that you get the two parameters mixed up, you probably want:
PlayVideo ("Robbery.mov", 3,1);

as documented in the manual, though I agree that the entry for that function in the manual can be a bit misleading.
Title: Re:Can't make movies run
Post by: on Sun 29/02/2004 00:22:09
Thanx.  You were right about switching the numbers around.  Now the movie plays fullscreen like it's supposed to, but I still get an error message after the first playing!  ??? ??? ??? ???
Title: Re:Can't make movies run
Post by: Phemar on Sun 29/02/2004 14:05:33

Oh yeah, to make switch characters just use

SetPlayerCharacter (charid);

.:Zor:.
Title: Re:Can't make movies run
Post by: Pumaman on Sun 29/02/2004 17:28:28
Strange - is it possible for you to try it out on another computer and see if it has the same problem? Also, I'd recommend making sure you have the latest DirectX version installed.
Title: Re:Can't make movies run
Post by: Gilbert on Mon 01/03/2004 03:04:32
What's teh error message now, actually?
Title: Re:Can't make movies run
Post by: Pumaman on Mon 01/03/2004 22:13:51
"Unable to play stream" happens if the call to IMultiMediaStream::SetState (http://msdn.microsoft.com/library/default.asp?url=/library/en-us/directx9_c/directx/htm/imultimediastreamsetstate.asp) fails. It's odd, I've never seen it failing there before.
Title: Re:Can't make movies run
Post by: on Tue 02/03/2004 13:54:41
I have DirectX 8.1.
Title: Re:Can't make movies run
Post by: Pumaman on Tue 02/03/2004 22:22:42
It's probably worth upgrading to DirectX 9.0b and see if that fixes the problem.
Title: Re:Can't make movies run
Post by: on Sun 14/03/2004 19:45:04
I'm pretty sure DirectX isn't the problem, because the movies run fine in an ordinary movie player on the computer.

Would it help if I put a beta of the game on the Internet, so you guys could look at it?  ???
Title: Re:Can't make movies run
Post by: Pumaman on Mon 15/03/2004 20:14:13
That might be an idea - or even, just post a test game which simply plays the video twice, to easily see if other people have the same problem without giving the game away.