Step 1: you're handling this one correctly
Step 2: $regsubex(%answer,/[^ [:punct:]]/ug,*)
Step 3: $regsubex(%answer,/(?:^|(?<= ))([^ [:punct:]])|([^ [:punct:]])()/Fgu,$iif(\2 != $null,*,\1))
Step 4: $regsubex(value from step 3,/([^ ]+)/g,$iif($pos(\1,*,$r(1,$pos(\1,*,0))),) $left(\1,$calc($v1 - 1)) $+ $mid(%answer,$calc($regml(\n).pos + $v1 - 1),1) $+ $mid(\1,$calc($v1 + 1)))
Step 5: $regsubex(value from step 4,/([^ ]+)/g,$iif($pos(\1,*,$r(1,$pos(\1,*,0))),) $left(\1,$calc($v1 - 1)) $+ $mid(%answer,$calc($regml(\n).pos + $v1 - 1),1) $+ $mid(\1,$calc($v1 + 1)))

[:punct:] equals [!"\#$%&'()*+,\-./:;<=>?@\[\\\]^_‘{|}~], all of these characters won't be replaced by *.


Example with %answer being Bill Gates :

Step 2: **** *****
Step 3: B*** G****
Step 4: (generated a few): Bi** G*t** - B**l Ga*** - Bi** G**e* - Bi** G**e* - Bi** G***s - B*l* G**e* - B*l* Ga*** - Bi** Ga***
Step 5: (generated a few using step4 = Bi** G*t**) Bi** Ga*** - Bi*l G*te* - Bi*l G*te* - Bil* G*te* - Bi*l G*t*s - Bi*l G*t*s - Bi*l Gat** - Bi*l G*te* - Bil* G*t*s - Bil* Gat** - Bil* Gat** - Bil* G*te* - Bi*l G*t*s - Bil* G*te* - Bi*l G*te* - Bil* Gat** - Bil* G*te* - Bi*l G*te*


#mircscripting @ irc.swiftirc.net == the best mIRC help channel