PHP-Scripte PHP-Tutorials PHP-Jobs und vieles mehr

PHP-Scripte PHP-Tutorials PHP-Jobs und vieles mehr (
-   XML (
-   -   Need a help (

Maxjade 07-08-2019 15:06

Need a help

in a for loop, after a PHP query, create multiple instances of a movie clip dynamically, all of which I put into a separate MC as a container, all of which can be quickly deleted.
But here is the problem. I just can not delete the instances and can not figure it out ...

HTML code:
var container: MovieClip = new MovieClip ();
addChild (container);
for (i = 1; i <= 15; i ++) {
ClassReference: Class = getDefinitionByName ("mc _" + ["field" + i]) as Class;
var instance: MovieClip = new ClassReference ();
instance.x = posx;
instance.y = posy;
container.addChild (instance);
The ad works wonderfully. The instances should now be deleted at the touch of a button, and the whole thing should start from the beginning ... but what does not work ... The new instances just superimpose tellpizzahut those before.
I tried removeChild (container), to no avail. Actually, I thought to myself, I just delete the whole container, create again a new one and fill it again with instances .... as I said, does not work. I just do not get the container deleted ... What am I doing wrong ???

Thanks in advance.

Alle Zeitangaben in WEZ +2. Es ist jetzt 13:52 Uhr.

Powered by vBulletin® Version 3.8.2 (Deutsch)
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.3.0
[c] ebiz-consult GmbH & Co. KG