PDA

View Full Version : help me guys~ i having a problem here~



vincent1987
July 19th, 2008, 08:46 PM
Well, i just a beginner of action script 3.0
now i doing a point and click game
i face some problem when i doing my project hope can get some guide in here

The problem is in action script file i create a Clickable class, in this class i create a box that user can click it and jump to another frame ( the box width, height, x,y all is in variable so when i call it out in fla, i can adjust the size and positon)

but now the problem is when in fla, in 1st frame i call it out the class and create 3 box in my 1st frame, in 2nd frame i also create different box. When i ctrl+enter, in 1st frame have 3 place can click, so when click one of the box it go to another 2ndframe but the 1st frame box that i didn't click it also go to 2nd frame.....

Have method to remove 1st frame script? or have other method to solve this problem?
Can anyone help out? thx a lot

nikefido
July 19th, 2008, 10:55 PM
parentObject.removeChild(objectToRemove)

if parentObject is the stage, either use "stage", "this" or nothing, depending on where you are calling the code from.