|
metadata
Okay this may sound like a stupid question but I’ve been reading the source code and I keep running into this strange variable in the code
Game.main.spriteClip.removeChild(this);
From what i’ve managed to figure out, Game.main allows you to reference the
Game class from an outside class like enemy or boss. But where the crap does spriteClip come in? I looked through all the classes and i cant find where spriteClip initializes, nor do any of the comments explain what it is supposed to do. I’ve done a quick google search on this and ppl are saying that spriteClip belongs in the AS2 area, and that it should not be used.
My only educated guess is that spriteClip is supposed to act as some kind of seperate displayObjectContainer.
Can anyone give me more insight into this?
|
|
metadata
spriteClip is the parent of whatever class you took that code from, as it’s the one running the removeChild method.
|
|
metadata
Okay i looked at the Fla file as well now and apparently spriteClip was a library object initialized on the timeline. It does look like its some kind of container since all im getting is a small blank square.
|