This is G o o g l e's cache of http://www.flashsandy.org/forum/index.php?showtopic=474 as retrieved on 22 Aug 2007 08:25:40 GMT.
G o o g l e's cache is the snapshot that we took of the page as we crawled the web.
The page may have changed since that time. Click here for the current page without highlighting.
This cached page may reference images which are no longer available. Click here for the cached text only.
To link to or bookmark this page, use the following url: http://www.google.com/search?q=cache:r6WYSLeudfkJ:www.flashsandy.org/forum/index.php%3Fshowtopic%3D474+site:www.flashsandy.org/forum&hl=en&ct=clnk&cd=99


Google is neither affiliated with the authors of this page nor responsible for its content.

Welcome Guest ( Log In | Register )

 
Reply to this topicStart new topic
> Problem to remove an object from the scene
samothtronicien
post Apr 24 2007, 04:27 PM
Post #1


Member
**

Group: Members
Posts: 25
Joined: 23-August 06
Member No.: 326



Hello,

I have som difficulty to remove an object that i add to a group dynamically. I've tried remove(), destroy(), and other tricky codes, but nothing seems remove the object from the scene.
Someone has ever been able to remove an object ? (IMG:style_emoticons/default/biggrin.gif)

Thanks.
User is offlineProfile CardPM
Go to the top of the page
+Quote Post
kyuzo
post Apr 24 2007, 05:00 PM
Post #2


Advanced Member
***

Group: Members
Posts: 46
Joined: 19-June 06
Member No.: 18



try something like parent.getChildList().splice(...); it worked for me.
User is offlineProfile CardPM
Go to the top of the page
+Quote Post
samothtronicien
post Apr 24 2007, 05:18 PM
Post #3


Member
**

Group: Members
Posts: 25
Joined: 23-August 06
Member No.: 326



Yes i've tried also to pop the last child, so the object is not anymore in the group, but still rendering like a zombie ...
There is something i have not understood (IMG:style_emoticons/default/sad.gif)

thx anyway

This post has been edited by samothtronicien: Apr 24 2007, 05:19 PM
User is offlineProfile CardPM
Go to the top of the page
+Quote Post
kyuzo
post Apr 24 2007, 06:16 PM
Post #4


Advanced Member
***

Group: Members
Posts: 46
Joined: 19-June 06
Member No.: 18



well, it works for me. maybe send some code?
User is offlineProfile CardPM
Go to the top of the page
+Quote Post
samothtronicien
post Apr 24 2007, 08:37 PM
Post #5


Member
**

Group: Members
Posts: 25
Joined: 23-August 06
Member No.: 326



I have write a little example, it is in attachment.
I draw line between the center of the scene and the center of the sphere, and as you can see the previous lines are not erase.

This post has been edited by samothtronicien: Apr 24 2007, 08:38 PM


Attached File(s)
Attached File  Test.zip ( 34.06k ) Number of downloads: 12
User is offlineProfile CardPM
Go to the top of the page
+Quote Post
kiroukou
post Apr 24 2007, 09:11 PM
Post #6


Administrator
***

Group: Root Admin
Posts: 930
Joined: 12-June 06
Member No.: 1



AsI told you, I think there's a typo error on one of the remove method...
I noticed that during the AS3 port, but forgot to fix it in AS2 I guess.. :s

that's the best place to look at anyway (IMG:style_emoticons/default/smile.gif)
++
User is offlineProfile CardPM
Go to the top of the page
+Quote Post
samothtronicien
post Apr 24 2007, 09:26 PM
Post #7


Member
**

Group: Members
Posts: 25
Joined: 23-August 06
Member No.: 326



I think i have found, when we destroy (object3D method) we forgot to remove the movieClip, so i had a container.removeMovieClip(), and it works.
User is offlineProfile CardPM
Go to the top of the page
+Quote Post
kyuzo
post Apr 24 2007, 09:55 PM
Post #8


Advanced Member
***

Group: Members
Posts: 46
Joined: 19-June 06
Member No.: 18



the code you've sent is working as you expected for me; or maybe i've misunderstanded something.
(built with sandy 1.2 beta)
User is offlineProfile CardPM
Go to the top of the page
+Quote Post
samothtronicien
post Apr 24 2007, 10:05 PM
Post #9


Member
**

Group: Members
Posts: 25
Joined: 23-August 06
Member No.: 326



You have only one line3D at a time ?
Very strange ... because without the removeMovieClip you have to see all the lines (even if there are not in the rendering tree).

This post has been edited by samothtronicien: Apr 24 2007, 10:07 PM
User is offlineProfile CardPM
Go to the top of the page
+Quote Post
kyuzo
post Apr 24 2007, 10:06 PM
Post #10


Advanced Member
***

Group: Members
Posts: 46
Joined: 19-June 06
Member No.: 18



test

yes
User is offlineProfile CardPM
Go to the top of the page
+Quote Post
samothtronicien
post Apr 24 2007, 10:08 PM
Post #11


Member
**

Group: Members
Posts: 25
Joined: 23-August 06
Member No.: 326



(IMG:style_emoticons/default/blink.gif) Lol

edit :

Ah!
I've checked the code 1.2 beta, and it'sa bit different in the 1.2 beta 2, this is probably why you just make the code working and me not.

This post has been edited by samothtronicien: Apr 24 2007, 10:15 PM
User is offlineProfile CardPM
Go to the top of the page
+Quote Post

Reply to this topicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

 

- Lo-Fi Version Time is now: 22nd August 2007 - 08:02 AM
phpMyVisites