i hope this is just a syntax question.
i need to set a Joystick chop’s source parameter from a script.
if i explicitly type the parameter string in quotes, the opparm works perfectly:
opparm $joyNodeName/Joystick source “2 - Controller (MadCatz GamePad)”
however, if i try to set the source using a variable, it doesn’t recognize the string in quotes,
giving errors for each part of the string:
Warning: Skipping unrecognized parameter “-”
Skipping unrecognized parameter “Controller”
Skipping unrecognized parameter “(MadCatz”
Skipping unrecognized parameter “GamePad)”"
below is what i’ve tried, (but always get the above errors):
set joyIn = tab("CurrentJoystickInputs",$i,0)
this pulls sequentially from the infoDat connected to a Joystick to determine what is currently plugged in
echo $joyIn : 2 - Controller (MadCatz GamePad)
echo "$joyIn" : “2 - Controller (MadCatz GamePad)”
set joyInQuotes = "$joyIn"
this adds quotes to the table entry, hoping it will be recognized as a string
echo $joyInQuotes : “2 - Controller (MadCatz GamePad)”
neither of the below opparms will work, even though the echos show the variable is being enclosed in string-defining quotes:
opparm $joyNodeName/Joystick source "$joyIn"
opparm $joyNodeName/Joystick source $joyInQuotes
is there a special way to set a string parameter?
thanks in advance for any help…
–kate