@ in a scrip needed for color code

Posted by Aralia Faal on Sun 02 Sep 2012 05:15 PM — 2 posts, 11,693 views.

#0
I play a mud that uses @ as a color code indicator. I made a hiding variable and a trigger to set the variable yes or no depending on if I’m hiding or not. I then made an alias for say to check the variable and then perform one of two actions.



<aliases>
  <alias
   match="say *"
   enabled="y"
   send_to="12"
   sequence="99"
  >
  <send>
if hiding == "yes" then
  SendImmediate ("emote says from the shadows, "@R%1@n"")
 else
  SendImmediate ("say @R%1@n")
end
</send>
  </alias>
</aliases>


How do I get it to send @ within the scrip and not call for a variable?
USA Global Moderator #1
First of all you can't send "something"something"" because the second " terminates the first. Either make the outer ones ' instead of " or escape the inner ones.

e.g.

'something"something"'

or

"something\"something\""


And for your question, either don't use the "expand variables" option, or double up the @ (like @@) to send a literal one instead of interpreting it as a variable request.