Be a Supporter!

Syntax Error!

  • 283 Views
  • 3 Replies
New Topic Respond to this Topic
headphenomenon
headphenomenon
  • Member since: May. 1, 2009
  • Offline.
Forum Stats
Member
Level 13
Programmer
Syntax Error! 2010-09-22 17:58:59 Reply

Okay, I have a simple piece of script for AS2, and the player is giving me back the following error, and I don't know how to fix it.

on(release){
shirt = 6;
}

Description: Syntax Error.
Source: on(release){

Can someone please help me?

BTW, I'm using AS2 (I already mentioned that) and Adobe Flash CS4.

06-17-11: User of the Day
07-25-11: 1500th Post
08-09-11: Level 13!

PoppyClock
PoppyClock
  • Member since: Aug. 19, 2006
  • Offline.
Forum Stats
Member
Level 01
Blank Slate
Response to Syntax Error! 2010-09-22 18:12:35 Reply

Is the code on a symbol?


Balderdash and PoppyClock

BBS Signature
headphenomenon
headphenomenon
  • Member since: May. 1, 2009
  • Offline.
Forum Stats
Member
Level 13
Programmer
Response to Syntax Error! 2010-09-22 18:16:52 Reply

At 9/22/10 06:12 PM, PoppyClock wrote: Is the code on a symbol?

its on a button.


06-17-11: User of the Day
07-25-11: 1500th Post
08-09-11: Level 13!

headphenomenon
headphenomenon
  • Member since: May. 1, 2009
  • Offline.
Forum Stats
Member
Level 13
Programmer
Response to Syntax Error! 2010-09-22 21:50:16 Reply

At 9/22/10 06:20 PM, ActionSplash wrote: Try using proper variable declaration maybe?

on(load){
var shirt:Number
}

on(release){
shirt = 6;
}

It's okay. I fixed it. Weird thing is, I retyped the same code, and it had no error.

A spooky thing, flash is. - Daily Words of Yodaism.

06-17-11: User of the Day
07-25-11: 1500th Post
08-09-11: Level 13!