I did a tutorial for loading videos into the BGE, using the same scripts to upload and refresh that I see most people using–described in the blender online manual. I had an initial problem, which other people on that site had but which no one ever answered.
(I’m using Blender 2.49. Windows XP)
I got this error message, which repeated twice:
Python script error from controller ”cont#CONTR#1”=
Traceback :
File “LoadingVideo”, line 13, in
RunTimeError: VideoTexture.materialID: Object doesn’t have material with given name
I couldn’t find an answer, but I was able to get rid of this error message and play the animation by changing
– Get the material that is using our texture
matID = VideoTexture.materialID(obj, ‘IMinvite.png’)
to…
– Get the material that is using our texture
matID = VideoTexture.materialID(obj, ‘MAinvite’)
(“invite.png” being the image in my UV and loaded texture, per the tut’s example, “invite” being the name of the material I assigned to the plane)
…and using the movie file as my loaded texture and UV image (the tutorial told me to load a picture file–its example: bbb.png, same as manual I think).
So now I have the video file in the game, but there’s no audio. Does anyone know how I can add a video file with both video and audio into the blender game engine?