title: How to localize a string in unity where different languages may have different grammars
body: <p>I'm translating a Unity game and some of the lines go like</p>
  
  <blockquote>
    <p>Unlock at XXXX</p>
  </blockquote>
  
  <p>where "XXXX" is replaced at runtime by an arbitrary substring. Easy enough to replace the wildcards, but to translate the quote, I can't simply concatenate a + b, as some languages will have the value before or inside the string. I figured I needed to, effectively, de-replace it, ie isolate and keep the substring and translate whatever's around it.</p>
  
  <p>Problem is that while I can easily do the second part, I can't think of any avenues for the first. I know to get the character index of what I'm looking for, but the value takes up an arbitrary number of characters, and I can't use whitespace since some languages don't use it. Can't use digit detection since not all of the values are going to be numbers. I tried asking Google, but I couldn't translate "find whatever replaces a wildcard" into something keyword-searchable.</p>
  
  <p>In short, what I'm looking for is a way to find the "XXXX" (the easy part) and then <strong>find whatever replaces it in the string</strong> (the less-easy part).</p>
  
  <p>Thanks in advance.</p>