When I tried testing your expression, I noticed the \ was causing a problem. GD seems to treat them as a special character or something. I checked the forum and someone said that when using \ you need to 2 slashes \\ or a single /
They both worked but gave different results.
https://forum.gdevelop.io/t/using-custom-player-name-in-yarn-dialogue/50689/22
This seems to work. At least, it doesn’t cause an error. IDK if it returns what you expect to.
RegEx::Replace("(^|\\b)([a-z])\\w{1,3}", "gi" , "Lorem ipsum dolor sit amet" , "XXX" )
Top is with \\ bottom /
