Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
1

Compiler Error 1151: A conflict exists with definition _this in namespace internal

Community Beginner ,
Feb 17, 2021 Feb 17, 2021

I am doing an interactive animation project in school using Adobe Animate. Everything works when I test it out (Ctrl + Enter), but when I export movie, I get a bunch of compiler errors saying what's in the subject line. I will attach a screenshot of the compiler error window and the actions tab of one of the frames that is referred in the list. All of the actions use the same code that was brought by the wizard.

2.5K
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Feb 17, 2021 Feb 17, 2021

Hi.

 

You're using JavaScript in an AS3 document.

 

Go to File > Convert To > HTML5 Canvas.

 

All the code will be commented out so just uncomment it.

 

Regards,

JC

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Feb 17, 2021 Feb 17, 2021

It already is an HTML5 canvas. The filename in the screenshot above the stage shows a little bit of that.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Feb 17, 2021 Feb 17, 2021

It's strange because there's no compiler errors in HTML5 Canvas documents.

 

Can you upload another screenshot showing the whole window?

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Feb 17, 2021 Feb 17, 2021

Sure. Here is the updated screenshot.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Feb 17, 2021 Feb 17, 2021

upload the fla to a file server and post a link.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Feb 17, 2021 Feb 17, 2021

I've never done that before. What file server do you recommend?

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Feb 17, 2021 Feb 17, 2021

use dropbox 

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Feb 17, 2021 Feb 17, 2021
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Feb 17, 2021 Feb 17, 2021

i don't see an error when publishing.  in fact, the published files look like they work as expected:

 

http://www.kglad.com/Files/forums/snhu/

 

close and reopen animate and republish.  if that fails, restart your computer and republish.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Feb 18, 2021 Feb 18, 2021

Hi again.

 

I also didn't get any error.

 

Besides of what kglad told, I think the reason may be the version of your Animate. Are you using a version that is older than the current one (21.0.3)?

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Feb 18, 2021 Feb 18, 2021

Thanks everyone.

 

Thank you kglad for posting your publish so I can see for myself. This makes me wonder though. Are your publish settings different than mine? If not, then I won't worry about it anymore but I'm just curious.

 

 Joao, my copy of Animate's version is 21.0.3. That is the same version that the file I put in dropbox was saved on.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Feb 18, 2021 Feb 18, 2021

i didn't change publish settings (except to rename the file):

 

kglad_0-1613682603354.pngexpand image

 

i assume you're not seeing those errors any longer, correct?

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Feb 18, 2021 Feb 18, 2021

I didn't see the errors when I published, but I think that's where the problem lies. I wasn't publishing originally, I was exporting a movie. That's when the compiler errors came up.

 

Now I'm noticing a problem with my published HTML document that my buttons aren't doing anything. My cursor doesn't change from an arrow to a pointing hand either and I'm not getting any audio.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Feb 18, 2021 Feb 18, 2021

if you export a bitmap sequence there shouldn't be a problem, but if you export a swf you're essentially publishing an as3 and that explains the errors.

 

do you see any of those problems with the files i publishing and linked in a previous message?

 

are you seeing those problems when testing in animate (where everything should work) or when opening the html on you local computer (where you can expect those problems because of cross-domain security issues)?

 

 

 

 

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Feb 18, 2021 Feb 18, 2021

So the link of the animation you posted worked fine the first time I clicked on it, but every other time after that, the song that plays at the beginning wouldn't play anymore, yet every other sound clip and song that I added to it played just fine. The buttons also work fine as well.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Feb 19, 2021 Feb 19, 2021

you probably need to clear your cached files.

 

anyway, is everything working on your end?

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Feb 19, 2021 Feb 19, 2021

Yeah, everything is working ok. The buttons work fine now, but the music at the beginning is still not playing properly. (It starts later than it's supposed to)

 

I just tried clearing the publish cache and ran another test, it didn't fix the issue with the audio starting at the wrong time. Is there another cache I'm supposed to clear?

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Feb 19, 2021 Feb 19, 2021

nothing to clear when testing in animate.

 

try changing your sound's sync setting (to stream if you want it sync'd with your timeline).

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Feb 19, 2021 Feb 19, 2021

I tried changing to stream, but it still didn't play properly and only played when I clicked one of the movie's buttons.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Feb 19, 2021 Feb 19, 2021

does the sound play fully when you test in the fla's library?

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Feb 19, 2021 Feb 19, 2021

Yes, and it plays properly when I play from the timeline. Just in a playtest, it starts playing when Mario starts jumping down the stairs, and when I publish it, it doesn't play at all. All the other audio plays fine except for that song.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Feb 19, 2021 Feb 19, 2021

if it plays fully in the timeline and when the timeline moves, but you want it to start playing when the page loads you should reset its sync property back to "event" start the sound on frame 2 of the main timeline and make sure frame 2 plays when your files load.  ie, no this.stop() in frame 1.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Feb 19, 2021 Feb 19, 2021

I've tried that before as well.

 

I uploaded the latest save to my dropbox again. As I have tried everything you've suggested thus far, I feel you looking at it and seeing for yourself might show you what's happening exactly.

 

https://www.dropbox.com/s/08ccovbplvjfvvi/Final_PMario_BlockofMystery_HTML5%20Canvas.fla?dl=0

 

Playing the timeline, running a playtest and publishing have given me different results. Let me know if you're getting the same thing.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Feb 20, 2021 Feb 20, 2021
LATEST

i don't normally download and correct files unless i'm hired.  sometimes i do so when an issue intrigues me.

 

like @JoãoCésar i couldn't believe you were seeing an actionscript error message when publishing for html5.  that's why i initially downloaded your fla.

 

the sound issue you're having doesn't interest me enough to work on it gratis.  if you want to hire me, let me know.

 

other options are to wait to see if someone else will download and work on it for you or to google the problem and see what others have done.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines