Hello,
I'm playing a mud whose encoding is utf8.
I have checked this checkbox in the output settings "UTF-8 (Unicode)".
Also, I use this plugin to send text in utf8:
<?xml version="1.0" encoding="iso-8859-1"?>
<!DOCTYPE muclient>
<muclient>
<plugin
name="Translate_ISO_TO_UTF8"
author="lostsnow"
id="b5d6c2e22177e7a13b081a29"
language="Lua"
purpose="Translate sent text GBK into UTF-8"
date_written="2018-07-02 13:19:26"
requires="4.25"
version="1.0"
>
</plugin>
<!-- Script -->
<script>
<![CDATA[
function OnPluginSend (sText)
assert (package.loadlib ("luaiconv.dll", "luaopen_iconv")) ()
local cd = iconv.open("UTF-8", "ISO-8859-1")
local nstr, err = cd:iconv(sText)
Send ((nstr))
return false
end -- OnPluginSend
]]>
</script>
</muclient>
But when I create a trigger and use the Note() function to send text with special characters, it looks bad:
<triggers>
<trigger
enabled="y"
group="Quest"
match="El Dios Probador te cuenta 'Busca * en el area de *!'"
omit_from_log="y"
omit_from_output="y"
send_to="14"
sequence="99"
>
<send>Note("Busca el objeto en %1, área %2")
Execute("history_add questman=Busca el objeto en %1, área %2")</send>
</trigger>
</triggers>
But when the trigger is triggered, the accent on the á of the word área is not displayed correctly.
How can I make the text I sent through the Note() function be sent in utf8?
thanks
I'm playing a mud whose encoding is utf8.
I have checked this checkbox in the output settings "UTF-8 (Unicode)".
Also, I use this plugin to send text in utf8:
<?xml version="1.0" encoding="iso-8859-1"?>
<!DOCTYPE muclient>
<muclient>
<plugin
name="Translate_ISO_TO_UTF8"
author="lostsnow"
id="b5d6c2e22177e7a13b081a29"
language="Lua"
purpose="Translate sent text GBK into UTF-8"
date_written="2018-07-02 13:19:26"
requires="4.25"
version="1.0"
>
</plugin>
<!-- Script -->
<script>
<![CDATA[
function OnPluginSend (sText)
assert (package.loadlib ("luaiconv.dll", "luaopen_iconv")) ()
local cd = iconv.open("UTF-8", "ISO-8859-1")
local nstr, err = cd:iconv(sText)
Send ((nstr))
return false
end -- OnPluginSend
]]>
</script>
</muclient>
But when I create a trigger and use the Note() function to send text with special characters, it looks bad:
<triggers>
<trigger
enabled="y"
group="Quest"
match="El Dios Probador te cuenta 'Busca * en el area de *!'"
omit_from_log="y"
omit_from_output="y"
send_to="14"
sequence="99"
>
<send>Note("Busca el objeto en %1, área %2")
Execute("history_add questman=Busca el objeto en %1, área %2")</send>
</trigger>
</triggers>
But when the trigger is triggered, the accent on the á of the word área is not displayed correctly.
How can I make the text I sent through the Note() function be sent in utf8?
thanks