27.09.2018, 22:50
Try make it like this
PHP Code:
new name[MAX_PLAYER_NAME + 1];
GetPlayerName(playerid, name, sizeof name);
if (_:g_WelcomeChannelId == 0) //this one missing.
g_WelcomeChannelId = DCC_FindChannelByName("discord widget server id"); // Discord channel ID
new str1[128];
format(str1, sizeof str1, "[Server] %s: %s", name, text[1]);
DCC_SendChannelMessage(g_WelcomeChannelId, str1);