Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

DarkBASIC Professional Discussion / Is there any neato way to fo a wait till video finishes?

Author
Message
MiRRoRMaN 64
22
Years of Service
User Offline
Joined: 11th Jan 2004
Location:
Posted: 28th May 2013 12:28
Hi everybody,

I am wondering if theres a neato way to do this:

I'd like to find a way for a waiting period in which the user can still click the mouse button or a key to skip a video, yet when nothing is done for the software to continue after the video is done.

So yes like a games intro usually works. I know I would technically do that with a periodical loop with an until timer>some value or click=1 etc but what I'd really like to see if theres a way to make that until timer figure out from the video file how long the video exactly is and time that exactly right, so to speak.

Anyway, if anybody has any ideas and can point me in the right direction it would be much appreciated.

Thank you in advance!
Mobiius
Valued Member
23
Years of Service
User Offline
Joined: 27th Feb 2003
Location: The Cold North
Posted: 28th May 2013 17:05 Edited at: 28th May 2013 17:05
Quote: "
Repeat : Sync : Until *AnyKey* Or Animation Playing( Anim ) = 0"

This is a very basic method to accomplish that task.

This is my current project, check it out! [url]forum.thegamecreators.com/?m=forum_view&t=204576&b=8[/url]
This is my website, check it out! [url]http:\\www.TeamDefiant.co.uk[/url]
MiRRoRMaN 64
22
Years of Service
User Offline
Joined: 11th Jan 2004
Location:
Posted: 28th May 2013 23:58
thank you mobiius!
Libervurto
20
Years of Service
User Offline
Joined: 30th Jun 2006
Location: On Toast
Posted: 29th May 2013 01:19
Technically it should be a WHILE loop:
although it makes little difference in this specific situation.

The difficulty in learning is not acquiring new knowledge but relinquishing the old.
Mage
Valued Member
19
Years of Service
User Offline
Joined: 3rd Feb 2007
Location:
Posted: 29th May 2013 05:50
Quote: "Technically it should be a WHILE loop: + Code Snippet although it makes little difference in this specific situation."

We are splitting hairs here. It really depends on the rest of the game code. Since it's just one single screen sync, efficiency is negligible. Plus it'll help initialize the screen if the display mode was just set.

Mobiius
Valued Member
23
Years of Service
User Offline
Joined: 27th Feb 2003
Location: The Cold North
Posted: 29th May 2013 17:07
I chose a repeat loop as you'd want at least one iteration of the loop. With a while loop, it's possible to skip the video altogether, which I'm assuming is not wanted.

This is my current project, check it out! [href]forum.thegamecreators.com/?m=forum_view&t=204576&b=8[/href]
This is my website, check it out! [href]http:\\www.TeamDefiant.co.uk[/href]

Login to post a reply

Server time is: 2026-07-11 14:52:37
Your offset time is: 2026-07-11 14:52:37