Hi guys, i wondered if anyone around here could help me with a small bit of action script for a space game i created so far through a tutorial, but there is this one line that keeps giving errors!
if (Key.isDown(Key.CONTROL) { laserCounter++;
_root.laser.duplicateMovieClip( "laser"+laserCounter, laserCounter );
_root["laser"+laserCounter]._visible=true;
}
it says this:
**Error** Scene=Scene 1, layer=Spaceship, frame=1:Line 31: ')' expected
if (Key.isDown(Key.CONTROL) { laserCounter++;
Total ActionScript Errors: 1 Reported Errors: 1
Could anyone help please?
Actionscripting help please ;]
Started by iCeWinD, Sep 24 2005 05:31 PM
5 replies to this topic
#1
Posted 24 September 2005 - 05:31 PM
#2
Posted 24 September 2005 - 06:07 PM
the lasercounter++ should be on a new line
#3
Posted 24 September 2005 - 06:52 PM
Yeah, tried that but it doesn't change anything, still the same error:
**Error** Scene=Scene 1, layer=Spaceship, frame=1:Line 11: ')' expected
if (Key.isDown(Key.CONTROL) {
Total ActionScript Errors: 1 Reported Errors: 1
**Error** Scene=Scene 1, layer=Spaceship, frame=1:Line 11: ')' expected
if (Key.isDown(Key.CONTROL) {
Total ActionScript Errors: 1 Reported Errors: 1
#4
Posted 24 September 2005 - 07:01 PM
here the code 
if (Key.isDown(Key.CONTROL)) {
laserCounter++;
_root.laser.duplicateMovieClip( "laser"+laserCounter, laserCounter );
_root["laser"+laserCounter]._visible=true;
}
Edited by funkysoul, 24 September 2005 - 08:39 PM.
#5
Posted 25 September 2005 - 03:28 AM
thanks baby, you own!
it works now
i'll post the game once its finish ;].. only need to create the enemies and a few touch ups now ;]
#6
Posted 25 September 2005 - 07:54 AM
cool
please do that.. I would also like to see it
please do that.. I would also like to see it
1 user(s) are reading this topic
0 members, 1 guests, 0 anonymous users
