 |
crycry Apprentice

Joined: 24 Jun 2006 Posts: 169 Location: UK - South Coast
|
Posted: Tue Dec 12, 2006 12:36 pm
[1.22] unmatched braces error |
any idea why this line, gives an unmatched braces error?
| Code: |
| #LOG {logs/$main_tag.txt} |
also tried this, incase it was the /
| Code: |
| #LOG logs/{$main_tag}.txt |
realising this prolly isnt a bug, just my lack of knowledge. |
|
_________________ 'Life is what happens, when your too busy doing something else'
_________________
XP Pro SP2
cMud 1.24
_________________ |
|
|
 |
Fang Xianfu GURU

Joined: 26 Jan 2004 Posts: 5155 Location: United Kingdom
|
Posted: Tue Dec 12, 2006 1:46 pm |
Try this instead:
#LOG logs/$main_tag.txt
Compiles for me. |
|
|
|
 |
crycry Apprentice

Joined: 24 Jun 2006 Posts: 169 Location: UK - South Coast
|
Posted: Tue Dec 12, 2006 1:53 pm |
does for me to, but wont expand the local var. annoyingly
|
|
_________________ 'Life is what happens, when your too busy doing something else'
_________________
XP Pro SP2
cMud 1.24
_________________ |
|
|
 |
Fang Xianfu GURU

Joined: 26 Jan 2004 Posts: 5155 Location: United Kingdom
|
Posted: Tue Dec 12, 2006 2:28 pm |
Hmm... how about:
#log {%concat("logs/",$main_tag,".txt")}
EDIT: One other thing. In file paths you generally need to use a backslash, not a slash. See if that helps. |
|
Last edited by Fang Xianfu on Tue Dec 12, 2006 2:40 pm; edited 1 time in total |
|
|
 |
crycry Apprentice

Joined: 24 Jun 2006 Posts: 169 Location: UK - South Coast
|
Posted: Tue Dec 12, 2006 2:32 pm |
ooooo ok thanks fang. will try
|
|
_________________ 'Life is what happens, when your too busy doing something else'
_________________
XP Pro SP2
cMud 1.24
_________________ |
|
|
 |
Fang Xianfu GURU

Joined: 26 Jan 2004 Posts: 5155 Location: United Kingdom
|
Posted: Tue Dec 12, 2006 2:40 pm |
Forgot a slash in there. Changed it.
|
|
|
|
 |
Larkin Wizard

Joined: 25 Mar 2003 Posts: 1113 Location: USA
|
Posted: Tue Dec 12, 2006 7:07 pm |
#LOG logs/${main_tag}.txt
Maybe? |
|
|
|
 |
Fang Xianfu GURU

Joined: 26 Jan 2004 Posts: 5155 Location: United Kingdom
|
Posted: Tue Dec 12, 2006 7:18 pm |
See the first post. Didn't work.
|
|
|
|
 |
Larkin Wizard

Joined: 25 Mar 2003 Posts: 1113 Location: USA
|
Posted: Tue Dec 12, 2006 7:27 pm |
Mine has a very subtle difference: I moved the first curly bracket over. This works for me.
|
|
|
|
 |
Fang Xianfu GURU

Joined: 26 Jan 2004 Posts: 5155 Location: United Kingdom
|
Posted: Tue Dec 12, 2006 9:06 pm |
...I think I'm going blind in my old age. I thought crycry's example had the $ outside the brackets. I imagine that that way does work.
Does it create the folder properly though? I can't seem to get the #log command to create folders using the same syntax. |
|
|
|
 |
|
|
|