Macro troubles help

Omega
Exile
Post #1

Macro troubles help

by Omega » Wed Sep 16, 2015 6:12 am

Been trying to add new macro... I have had this issue for a while but now and just let it go but I plan on being out a lot again i need to resolve this. This specific issue isn't the only time the same errors occurred it is just the latest occurrence.

For the most part my macro file runs fine and always has but it seems I can no longer add commands. I've added a spell page to my book and wanted to macro the command. At first i copy and pasted the previous spell and then just changed the numbers and received this error. Then I though C&P isn't good so I physically typed it to no avail. Again this has happened anytime I've gone in to modify a previously working macro and have always had to revert back to a back up to get the specific macro working again. I will list the macro at the end

• MACRO Unexpected closing brace encountered '}'
FILE "omega" LINE 994
• MACRO Unexpected closing brace encountered '}'
FILE "omega" LINE 999

I have always used TextEdit. Since the fail I then went to MS word and saved out as plain text file with the same above results.

Please help...

Here is a still working macro


"p20h"
{
"/equip Phantasmonomicon\r"
"/use 20 /hide\r"
"/equip moonstone\r"
}

"p21"
{
"/equip Phantasmonomicon\r"
"/use 21\r"
"/equip moonstone\r"
}

"p21h"
{
"/equip Phantasmonomicon\r"
"/use 21 /hide\r"
"/equip moonstone\r"
}

"p22"
{
"/equip Phantasmonomicon\r"
"/use 22\r"
"/equip moonstone\r"

Here is the broken line

“p33”
{
“/equip Phantasmonomicon\r”
“/use 33\r”
“/equip moonstone\r”
}

“p33h”
{
“/equip Phantasmonomicon\r”
“/use 33 /hide\r”
“equip moonstone\r”
}

I am baffled... Is there a special or specific text editor i should be using instead?

Thanks in advance

Warder
Exile
Post #2

Macro troubles help

by Warder » Wed Sep 16, 2015 1:41 pm

Can you check to see if it wouldn't be because TextEdit is set to use smart quotes (check the preferences)? smart quotes “test” and regular quotes "test" aren't the same to the macro parser. Sometimes text editors try to help you by replacing straight quotes with smarts ones. I'm assuming you're on a mac since you mentioned TextEdit.

Icy
Exile
Post #3

Macro troubles help

by Icy » Wed Sep 16, 2015 1:58 pm

Warder wrote:Can you check to see if it wouldn't be because TextEdit is set to use smart quotes (check the preferences)? smart quotes “test” and regular quotes "test" aren't the same to the macro parser. Sometimes text editors try to help you by replacing straight quotes with smarts ones. I'm assuming you're on a mac since you mentioned TextEdit.
That is absolutely it.

Omega
Exile
Post #4

Macro troubles help

by Omega » Wed Sep 16, 2015 2:19 pm

Hey Guys! Perfect!!! that was it!!! Thanks so much! see ya's soon!

noivad
Exile
Post #5

Macro troubles help

by noivad » Fri Sep 18, 2015 8:40 am

Yap! All text editors are not created equal. Some save a file in its default character encoding (say UTF-8 to show the true quotes versus the inch & foot marks programmers use to denote strings). Improper encoding or decoding will cause the client to not recognize it as a valid macro file too. If you don’t know what text encoding is, fret not—just know that it does matter & is the reason macros written on the OS X must be converted to by the Windows client to its encoding.

Ever “¥” in place of “•” in a macro? That’s an example of the program misinterprting the text encoding and showing it as something else. It is sometime as sinple as finding the text encoding selection & setting it to the right encoding. (This also explains why you sometimes see email with garbled characters: the sender might have fogotten to specify the encoding in the header or the mail client might not support the character encoding.

This has ben an issue as long as computers have been around. ASCII “solved” it, until other formats emerged.

This has been your technical hidtory reader’s digest version of technical stuff you shouldn’t NEED to know, but it helps.

noivad
Exile
Post #6

Macro troubles help

by noivad » Tue Sep 22, 2015 8:21 am

Omega just spotted an error on my Quik 'n Dirty Moonstone Functions macro generator (available here): http://noivad.net/moonstone_functions-template.php

Now its even less buggy (by 2 transposed characters), and I also give credit where credit is due. Considering what a staunch advocate of giving people credit (not stealing it), I am personally admonishing myself for not initially listing the people who helped make this macro what it is in the first place in a clear and obvious place. My mistake has been rectified. If you helped with feeedback, suggestions and are not listed, let me know. It has been a long time and I can’t remember all the people who said “ya know I like it, but it would be better if it did _insert cool idea here_” and I added it. There’s even some shift-click features I even forgot about, like shift-Fkeying a person that is already in that Fkey slot will cad lock them.

Idea Hamster just told me:
I should make a option-shift-Fkey share lock selected people…