|
GeneralStonewall Magician
Joined: 02 Feb 2004 Posts: 364 Location: USA
|
Posted: Thu Jun 03, 2010 2:29 am
[3.18b] BUG: var.key and var.# error |
Using var.key or var.# outside of a command in a script causes an illegal token error.
Example:
Code: |
#send {eat @food.cake}
eat @food.cake |
The first will work, but the second will not.
Quote: |
Error compiling script:
illegal token: .cake |
Edit: The same is true for variable assignment. var = var.1 will not work. |
|
|
|
Zugg MASTER
Joined: 25 Sep 2000 Posts: 23379 Location: Colorado, USA
|
Posted: Thu Jun 03, 2010 4:40 pm |
What is the value of the @food variable when you did this? I couldn't get it to fail with this script:
Code: |
food.cake = chocolate
#send {eat @food.cake}
eat @food.cake |
In both cases it showed "eat chocolate"
I confirmed the problem with "var = @othervar.1" and added it to the bug list. I'm assuming you forgot the @ in front of var.1 as just a typo, right? |
|
|
|
GeneralStonewall Magician
Joined: 02 Feb 2004 Posts: 364 Location: USA
|
Posted: Thu Jun 03, 2010 5:32 pm |
Zugg wrote: |
What is the value of the @food variable when you did this? I couldn't get it to fail with this script:
Code: |
food.cake = chocolate
#send {eat @food.cake}
eat @food.cake |
In both cases it showed "eat chocolate"
I confirmed the problem with "var = @othervar.1" and added it to the bug list. I'm assuming you forgot the @ in front of var.1 as just a typo, right? |
Right, I meant var = @othervar.1
edit: The 'eat @food.cake' bit is still causing an illegal token error on '.cake' for me. I'll try in a fresh session, but it seems odd that anything I have would effect it... nope, still getting the illegal token error. I even removed the default packages. |
|
|
|
Zugg MASTER
Joined: 25 Sep 2000 Posts: 23379 Location: Colorado, USA
|
Posted: Thu Jun 03, 2010 7:36 pm |
Ahh, now I see it. It was a bug I already fixed. I confirm that the bug existed in 3.18b, but it's already fixed for the next update.
|
|
|
|
|
|