|
Re: Playing an Avi in the Pro 6.1 Game Engine
[Re: webamerica]
#44718
04/20/05 18:46
04/20/05 18:46
|
Joined: Mar 2004
Posts: 1,201 Switzerland, Baselland
Bird
Senior Developer
|
Senior Developer
Joined: Mar 2004
Posts: 1,201
Switzerland, Baselland
|
Ok, i'm not conitec, but i think, you should update to the newest version of A6. With this update you will have more and better features, less bugs and a faster engine. Newest Update is A6.31.4
PS: I have read, that you had the newest Update, but you should really update it (again). It's much better!
Last edited by Bird; 04/20/05 18:50.
- A6pro 6.40.5
|
|
|
Re: Playing an Avi in the Pro 6.1 Game Engine
[Re: webamerica]
#44720
04/20/05 21:39
04/20/05 21:39
|
Joined: Feb 2005
Posts: 130
Roger
Member
|
Member
Joined: Feb 2005
Posts: 130
|
hmm...Keyword unknown word Media_play... try this command at the end of the main function before the "}" of your level: media_play("my_movie.avi", null, 100);
replace my_movie.avi by the real name of your video file ,and make sure the AVI is in the same directory than the WMP.
It should work if you did that right .
STREETKICKER IS DOWN ! ...Soon in your street !
|
|
|
Re: Playing an Avi in the Pro 6.1 Game Engine
[Re: webamerica]
#44721
04/20/05 21:39
04/20/05 21:39
|
Joined: Oct 2003
Posts: 2,628 IL,US
FeiHongJr
Expert
|
Expert
Joined: Oct 2003
Posts: 2,628
IL,US
|
heres a code i use to play a movie on a model should be pretty much the same. Code:
var tv_handle = 0; function new_tv() { if(event_type == event_scan && media_playing(tv_handle)== 0) { media_play("01.avi",bmap_for_entity(my,2),100); tv_handle = media_handle; } }
action activate_TV// action to attach to tv { //TV = me; my.enable_scan = on; // sensitive to scans my.event = new_tv;// run tv_on_off if im scanned while(1) { if(media_playing(tv_handle) != 0) { my.skin = 2; } else { my.skin = 1; } wait(1); } }
Hope it helps/
|
|
|
Re: Playing an Avi in the Pro 6.1 Game Engine
[Re: webamerica]
#44722
04/21/05 15:27
04/21/05 15:27
|
Joined: Sep 2002
Posts: 8,177 Netherlands
PHeMoX
Senior Expert
|
Senior Expert
Joined: Sep 2002
Posts: 8,177
Netherlands
|
I really recommend updating your version to the newest version, though i'm sure there's no bug for the mediaplay function, you're missing the whole shader features and some other big improvements... As far as your script problem, maybe you should download the newest manual from the download page, and look up the function media_play , because 99% of the functions are explained with a short example, which will definately help you, i'm sure! Also usually when the engine gives this error, it could mean you did a few things wrong, for example at the end of each line of code should come a ; Or you made a typo or something like that, maybe you can post your script??
Cheers
|
|
|
Re: Playing an Avi in the Pro 6.1 Game Engine
[Re: PHeMoX]
#44723
04/21/05 20:34
04/21/05 20:34
|
Joined: Jul 2000
Posts: 8,973 Bay Area
Doug
Senior Expert
|
Senior Expert
Joined: Jul 2000
Posts: 8,973
Bay Area
|
Quote:
I really recommend updating your version to the newest version,
If I understand his posts, he did upgrade, then returned back to 6.1, and then is now back to the latest version.
Try “FeiHongJr” solution and let us know if it works. Remember, as a Pro owner you have a year of support. We can't answer programming questions but, if you think you have a bug, please let us know.
|
|
|
Re: Playing an Avi in the Pro 6.1 Game Engine
[Re: Doug]
#44724
04/22/05 02:50
04/22/05 02:50
|
Joined: Oct 2002
Posts: 2,256 Oz
Locoweed
Expert
|
Expert
Joined: Oct 2002
Posts: 2,256
Oz
|
Hi webamerica,
Perhaps you should post the part of the code where you are trying to play the avi, then someone could look at it and see if they see something wrong with the code itself. Alot of times with the kind of error you explained, the actual error is in one of the lines above the line of code where the error shows up, usually a syntax error, this may or may not be the problem, but it wouldn't hurt to show the code and find out.
Loco
Professional A8.30 Spoils of War - East Coast Games
|
|
|
Re: Playing an Avi in the Pro 6.1 Game Engine
[Re: Locoweed]
#44725
04/22/05 04:03
04/22/05 04:03
|
Joined: Apr 2005
Posts: 47
webamerica
OP
Newbie
|
OP
Newbie
Joined: Apr 2005
Posts: 47
|
Hello,
As you requested here is a sniplet of the code and it's placement in the script. ----------------------------------------------------------------------------- I did try this script enclosed below and it opens the avi for about 1-1/2 frames with no sound and then i recieve the following error message.
Acknex has encountered a problem and needs to close. To be more specific, it crashes the game.
Interestingly enough, no other script will even open the avi. This will at least perform the function as far as i mentioned above.
I have tryed several file sizes on the avi's from very large to very small with out any change in the ability to run the avi.
So the size does not seem to be the issue or at least not at this point untill we find the script and or the location to place the script in the main wdl.
However, the resolutions of the avi's that we make are of broadcast quality since this is one of the services we provide to the film, video and television industry.
I mention the possible problem with the resolution being to high and the frame rate to fast for the engine to run based on the help files which point out that it is best to keep both as low as possible.
At this point i do not know how to adjust down or up an avi resolution or frame rate to satisfy the engine if this is what it needs.
Please find the script that peforms the above mentioned actions. Please remember that this is the only script that has even come close to running an avi so far.
///////////////////////////////////////////////////////////////// // The main() function is started at game start function main() {media_play("walls.avi",Null,100);
// set some common flags and variables // warn_level = 2; // announce bad texture sizes and bad wdl code tex_share = on; // map entities share their textures
// center the splash screen for non-640x480 resolutions, and display it splashscreen.pos_x = (screen_size.x - bmap_width(splashmap))/2; splashscreen.pos_y = (screen_size.y - bmap_height(splashmap))/2; splashscreen.visible = on; // wait 3 frames (for triple buffering) until it is flipped to the foreground wait(3);
// now load the level level_load(level_str); // freeze the game freeze_mode = 1;
// wait the required second, then switch the splashscreen off. sleep(5); splashscreen.visible = off; bmap_purge(splashmap); // remove splashscreen from video memory
// load some global variables, like sound volume load_status();
// display the initial message msg_show(mission_str,10);
// initialize lens flares when edition supports flares ifdef CAPS_FLARE; lensflare_start(); endif;
// use the new 3rd person camera move_view_cap = 1;
// un-freeze the game freeze_mode = 0;
// client_move(); // for a possible multiplayer game // call further functions here... } {
As you requested i am sending you this information to see if we can possibly continue to search for soulutions.
|
|
|
|