
I've hit on of those silly walls and I can't seem to figure out what mistake I've made.
I'm modifying the Ready Jack pistol script so that it has a dialog box to pick the hold animation. (the device is two handed so it doesn't fit people with really big or small shoulders, so I've made a series of poses with the hands at different places and need a way for the user to select the right(ish) size for them)
Anywho, I've got the dialog box set up and it will work on it's own in a prim, but when I copy and paste it into the existing script, I keep getting a syntax error on the listen line of the script and I can't figure out what I'm doing wrong.
I've put up a snippet of it to se if anyone can see what I'm doing wrong
Thanks so Much

PHP
default
{
state_entry()
{
verifyInventory();
llListen(CHANNEL, "", NULL_KEY, ""
; // listen for dialog answers (from multiple users)}
touch_start(integer x)
{
if (llDetectedKey(0) != llGetOwner()) {
return;
} else if (!llGetAttached()) {
getPerms();
} else if (gArmed) {
disarm();
} else {
arm();
}
{
llDialog(llDetectedKey(0), "Pick you Avatar size", MENU_MAIN, CHANNEL); // present dialog on click
}
listen(integer chan, string name, key id, string msg) //<=== Syntax Error at start of line
{
if(msg=="Large"

{
llStartAnimation(gAnim);
llOwnerSay(name + " changed the pose to ' " + msg + " '."
;}
else if(msg=="Huge"

{
llStartAnimation(gAnim2);
llOwnerSay(name + " changed the pose to ' " + msg + " '."
;}
else if(msg=="Average"

{
llStartAnimation(gAnim3);
llOwnerSay(name + " changed the pose to ' " + msg + " '."
;}
else if(msg=="Small"

{
llStartAnimation(gAnim4);
llOwnerSay(name + " changed the pose to ' " + msg + " '."
;}
else if(msg=="Tiny"

{
llStartAnimation(gAnim5);
llOwnerSay(name + " changed the pose to ' " + msg + " '."
;}
else if(msg=="Reset"

{
llStartAnimation(gAnim);
llOwnerSay(name + " has ' " + msg + " ' the pose."
;}
}
snip
/PHP