Displaying from the Display List?

  • 218 Views
  • 5 Replies
New Topic Respond to this Topic
Tired-Maniac
Tired-Maniac
  • Member since: Jul. 7, 2011
  • Offline.
Forum Stats
Member
Level 08
Blank Slate
Displaying from the Display List? Jun. 17th, 2012 @ 09:43 PM Reply

Couldn't fit the full title in T _ T...

Anyway I was just wondering how I show objects in my display list on the actual stage in Flash using AS3? I figured it would be far more efficient to place all my MC's in the display list by using the .addChild(); method - but i'm usually greeted with Syntax errors and have no idea how to show these MC's from the DL, can anyone help me? Thank you very much.


My sig? I have no idea.

BBS Signature
MintPaw
MintPaw
  • Member since: Jun. 11, 2006
  • Offline.
Forum Stats
Supporter
Level 10
Programmer
Response to Displaying from the Display List? Jun. 17th, 2012 @ 09:59 PM Reply

I don't get it, what's the code and what error are you getting?


If ya have something to say, PM me. I have a lot of time to spare.
Also never PM egg82.

BBS Signature
Tired-Maniac
Tired-Maniac
  • Member since: Jul. 7, 2011
  • Offline.
Forum Stats
Member
Level 08
Blank Slate
Response to Displaying from the Display List? Jun. 17th, 2012 @ 10:09 PM Reply

var myTriangle:TriangleShape = new TriangleShape();
addChild(myTriangle);

I understand that I've added the variable to my Display List, but how do I get it to physically show on the Flash output?

Errors:

1046: Type was not found or was not a compile-time constant: TriangleShape.
1180: Call to a possibly undefined method TriangleShape.

Thanks for your help.


My sig? I have no idea.

BBS Signature
Khronosis
Khronosis
  • Member since: Mar. 28, 2010
  • Offline.
Forum Stats
Member
Level 17
Programmer
Response to Displaying from the Display List? Jun. 17th, 2012 @ 10:51 PM Reply

Did you make sure to export the MovieClip for ActionScript?

Displaying from the Display List?


I implore you to reconsider.

MintPaw
MintPaw
  • Member since: Jun. 11, 2006
  • Offline.
Forum Stats
Supporter
Level 10
Programmer
Response to Displaying from the Display List? Jun. 18th, 2012 @ 12:06 AM Reply

Yeah, the overhanging error is "TriangleShape" as a Class does not exist, your problem is elsewhere.


If ya have something to say, PM me. I have a lot of time to spare.
Also never PM egg82.

BBS Signature
Tired-Maniac
Tired-Maniac
  • Member since: Jul. 7, 2011
  • Offline.
Forum Stats
Member
Level 08
Blank Slate
Response to Displaying from the Display List? Jun. 18th, 2012 @ 01:40 PM Reply

At 6/17/12 10:51 PM, Khronosis wrote: Did you make sure to export the MovieClip for ActionScript?

THANKS! I had to link it to the AS (or something :s) and create the Class of TriangleShape so it would show in the .swf. Thank you very much again for all your help NG Flash Forum - I'm learning new stuff errday ;D


My sig? I have no idea.

BBS Signature