Video OnError bug in r227

Bugs will be moved here once resolved.

Post » Wed Apr 13, 2016 8:20 am

Problem Description
Following release r227 (or those part of it, since I upgraded from last stable release, r221), the Video plugin has a
problem with the OnError event. It triggers even without anything having been done with the Video plugin (my code worked
fine in r221 and now triggers the error routine).

Attach a Capx
Easy to reproduce with the following code:

OK Button : OnClick Video : Set video source to "videoname.webm", "", "videoname.mp4)
Video : On Can Play Video Play
Video : On Error Browser Alert "Error detected"

Description of Capx
The code above triggers the Video error as soon as it is run, even before anything is loaded. It has to be this way to reproduce
the error, as if you immediately load the video (e.g. with the System On Start of Layout), it works fine and doesn't trigger the error.

Steps to Reproduce Bug
  • Create code above
  • Run it without pressing the button

Observed Result
Error is triggered and browser displays error message "Error detected"

Expected Result
Nothing in this case, until you press OK, then video loads and plays fine.

Affected Browsers
  • Chrome: Yes
  • FireFox: Yes
  • Internet Explorer: Yes

Operating System and Service Pack
Windows 7 Professional 64, Sp1 latest patches applied

Construct 2 Version ID
Posts: 87
Reputation: 957

Post » Wed Apr 13, 2016 8:28 am


The posting of a .capx is not optional, as stated in the Bug Reporting Requirements.

Please amend your post to include a simple .capx or it is likely that Ashley will close your post automatically.
If your vision so exceeds your ability, then look to something closer.
Posts: 5,812
Reputation: 62,218

Post » Wed Apr 13, 2016 9:30 am

For those who can't read 3 lines of code and on this forum where one can't post files directly (that's why I avoided posting a Capx), here's the link to a Capx in Dropbox: ... .capx?dl=0

Sorry for not being "politically correct", but I think some people could do with a bit of relaxing. If the issue isn't clear from what I wrote above,
I'm rather surprised.
Posts: 87
Reputation: 957

Post » Wed Apr 13, 2016 11:04 am

We deal with thousands of bug reports and about half of them are useless because the reporter did not follow the bug report guidelines. So we are very strict about this.

Your .capx includes no video files and sets an empty video src. I don't know why you expect that to work? It also contradicts your original report, which mentions setting a video src of "videoname.webm", but your .capx does not do that, so I am not sure what you are really trying to report. It doesn't look like there's anything particularly wrong here, so closing as won't fix.
Scirra Founder
Posts: 25,097
Reputation: 199,802

Post » Wed Apr 13, 2016 12:05 pm

Ashley, I didn't include the video files I had experienced the problem with, as I didn't think the issue was related to the files themselves. Try just using my code with two video files of your choice to see if the problem occurs or not (does the On Error trigger without anything happening or not).

The change is due to the move from r221 to r227, as the video code in my game was working fine in the previous version (no error triggered).

If anything has changed in the latest release due to video formats, this could explain the issue. Otherwise, it's just something not working in your code. Please therefore don't close this. Thank you.

Whilst I understand the need to provide a Capx in many cases to reproduce the problems, in this case it was just 3 lines of code, which I had provided. Probably takes you just as much time to download them as to enter them into an empty project.
Posts: 87
Reputation: 957

Return to Closed bugs

Who is online

Users browsing this forum: No registered users and 2 guests