Hello, I am trying to make a popular trivia game work on a new network. The issue is the script looks for the first character of incoming text using regex, but the new network has font code for $1. I haven't learned regex in depth yet, can anyone please help me with the regex matches?
The script has 3 text events. It is pretty complicated so I don't want to take the time to combine them into one text event, though that would be much easier for these matches.
I need to match the first character of the text following the font code.
This is how the text with the font code looks.
##*#Arial Black~#7F7F7F~1~1#*##This is a sentence.
This is the regex I was given to strip the font code normally.
/tokenize 32 $regsubex($1-,/^##\*.*\*##/,$null)
These are regex matches I was given by friends but they allow all text.
The first text event is supposed to check for text that starts with a . only.
on $*:text:/^(##\*.*\*##)?(.*)/:#:{ }
The second text event is supposed to check for text starting with ! only.
on $*:text:%st_filter_cmd:#:{ }
%st_filter_cmd = /^(##\*.*\*##)?(!*)/gS
The last text event checks for all text that doesn't start with a . or a !.
on $*:text:%st_filter_norm:#:{ }
%st_filter_norm = /(?!\.|\^|!)##\*.*\*##/gS
Can anyone please help me with the proper regex to do these things? Thank you.