Highlighted

Custom Cursor error in Animate

New Here ,
Jan 30, 2020

Copy link to clipboard

Copied

Hello, I'm trying to make a custom cursor for my project in actionscript and I'm having a bit of problem with the codes. The custom cursor works fine until I turn on the camera. The project is to make an interactive comic and the camera moves around the panels, and for this one specific panel I wanted to change the cursor for the interaction. The cursor changes just fine but as soon as I publish it with the camera on I get a 1120: Access of undefined property error. The error doesn't pop up if I publish it without the camera. Is there a way I can fix this?

TOPICS
ActionScript, Code, Error, How to

Views

71

Likes

Translate

Translate

Report

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

Custom Cursor error in Animate

New Here ,
Jan 30, 2020

Copy link to clipboard

Copied

Hello, I'm trying to make a custom cursor for my project in actionscript and I'm having a bit of problem with the codes. The custom cursor works fine until I turn on the camera. The project is to make an interactive comic and the camera moves around the panels, and for this one specific panel I wanted to change the cursor for the interaction. The cursor changes just fine but as soon as I publish it with the camera on I get a 1120: Access of undefined property error. The error doesn't pop up if I publish it without the camera. Is there a way I can fix this?

TOPICS
ActionScript, Code, Error, How to

Views

72

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Jan 30, 2020 0
Adobe Community Professional ,
Jan 30, 2020

Copy link to clipboard

Copied

you have a reference change.  on the custom cursor's timeline put:

 

trace(this)

 

to see its reference and how it changes when you enable the camera.

 

https://community.adobe.com/t5/animate/debugging-actionscript-3-0-errors/td-p/4788610?page=1

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Jan 30, 2020 0
New Here ,
Jan 30, 2020

Copy link to clipboard

Copied

hello, thank you for taking your time answering my question, but I'm not sure if I follow, I just started learning how to use animate and we barely learned anything so I barely have knowledge about coding. I've tried reading the linked source but it was very difficult to understand. If you can, may I request some elaboration on this?

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Jan 30, 2020 0
Adobe Community Professional ,
Jan 30, 2020

Copy link to clipboard

Copied

on the custom cursor's timeline put:

 

trace(this);

 

1. what do you see in the output panel?

2. what code are you using that's triggering the 1120 error?

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Jan 30, 2020 0
New Here ,
Jan 30, 2020

Copy link to clipboard

Copied

1. It still shows the same error codes 1120: Access of undefined property

 

2. I am using a code snipplet of "Custom Mouse Cursor" from adobe itself

 

stage.addChild(name);

name.mouseEnabled = false;

name.addEventListener(Event.ENTER_FRAME, fl_CustomMouseCursor_2);

 

function fl_CustomMouseCursor_2(event:EVENT)

{

name.x = stage.mouseX;

name.y = stage.mouseY;

}

Mouse.hide();

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Jan 30, 2020 0
kglad LATEST
Adobe Community Professional ,
Jan 30, 2020

Copy link to clipboard

Copied

comment out your code and retest so you can report that trace output.

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Jan 30, 2020 0