• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!
  • 2026 staff recruitment is open! Check it out and consider applying!

TFS 1.X+ Put 2 collors in message, like Img

Solution
player:sendTextMessage(5, "You advanced for level 55 and received: {25x crystal coins}.")
5 - is the correct message type id for client 8.6(you didn't specify for what version you need this), if it wouldn't work then you need to modify your sources to enable sending that message type id.
It has downside that it open NPC channel every time you receive that message but the message will arrive on default channel.
LUA:
player:sendTextMessage(TALKTYPE_NPC_FROM, "You pitpocket the {best answer} from Evil Puncker")

doPlayerSendTextMessage(cid, TALKTYPE_NPC_FROM, "You look back at the {older release} of TFS with nostalgia") ;
 
Last edited:
"normal text {dark txt}"
from npc file
npcHandler:setMessage(MESSAGE_GREET, "I offer {travel}...")
 
LUA:
player:sendTextMessage(MESSAGE_STATUS_CONSOLE_BLUE, "You pitpocket the {best answer} from Evil Puncker")

doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "You look back at the {older release} of TFS with nostalgia") ;
"normal text {dark txt}"
from npc file
npcHandler:setMessage(MESSAGE_GREET, "I offer {travel}...")
dont worked fine
1587364907469.png
 
You don't know that for sure until you reboot the server. Behavior after reload isn't canonical as far as I'm concerned.

Also, try changing the color of the message?, to the orange one.
 
It's working only if speaktype.npcChat is true (OTC).
You don't know that for sure until you reboot the server. Behavior after reload isn't canonical as far as I'm concerned.

Also, try changing the color of the message?, to the orange one.

I suspect that client just does not support that in every place. Npc channel is an exception
the fist imagem is on default channel and old client cip
appears when player advance level:
1587421178318.png
You advanced for level X, and received: 25x coins
 
Last edited:
player:sendTextMessage(5, "You advanced for level 55 and received: {25x crystal coins}.")
5 - is the correct message type id for client 8.6(you didn't specify for what version you need this), if it wouldn't work then you need to modify your sources to enable sending that message type id.
It has downside that it open NPC channel every time you receive that message but the message will arrive on default channel.
 
Solution
Actually, he should use TALKTYPE_NPC_FROM because if it breaks later if he tries to upgrade gameengine, 5 will be something meaningless to him and others on the support forum when he eventually makes here. Whereas the the constant will make it clear what was going on.
 
Back
Top