• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.

[General] Escaping "[]" in a cinematic scene

Status
Not open for further replies.
Hi guys,

I just noticed that characters engulfed by square brackets don't show up in a cinematic scene, when letterbox mode is activated.

The code below will only show "AC" ingame.
JASS:
call ShowInterface(false, 0.)
call SetCinematicScene('npn3', GetPlayerColor(Player(0)), "Title", "A[B]C", 5., 5.)

How can I escape the "[]" so that "A[B]C" is fully displayed?

Best regards,
Eikonium
 
Unfortunately doesn't work.

Inputting "A\[B\]C" gives a compile error in lua (which I'm using), because "\[" ist not a known escape sequence.

One can still input the desired characters by typing "A\x5C\x5BB\x5C\x5DC" (5C, 5B and 5D being the ASCII hex codes for \, [ and ] respectively), but that again will just show "A\C" ingame.

What language is Warcraft actually written in? I reckon that escaping things in lua doesn't work, as the string is passed to the SetCinematicScene-native, which is written in another language (maybe C?).
 
Status
Not open for further replies.
Top