D:\Revex DM\Mod — копия\gamemodes\revex.pwn(332) : warning 213: tag mismatch Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase 1 Warning.
public OnPlayerText(playerid, text[])
{
if (login_check[playerid] == false)
{
SendClientMessage(playerid, 0xFFA500FF, "Вы не авторизованы.");
return 0;
}
if (isAFK[playerid])
{
SendClientMessage(playerid, 0xFF0000FF, "Вы в AFK и не можете отправлять сообщения.");
return 0;
}
new color = 0xFFFFFFFF; // белый по умолчанию
if (dmPlayerVW[playerid] != 0)
{
color = 0x8B0000FF; // тёмно-красный, если в DM зоне
}
new name[MAX_PLAYER_NAME];
GetPlayerName(playerid, name, sizeof(name));
new msg[144];
format(msg, sizeof(msg), "[%d] %s", playerid, text);
for (new i = 0; i < MAX_PLAYERS; i++)
{
if (IsPlayerConnected(i))
{
SendClientMessage(i, color, msg); // тут используем цвет color
}
}
if (IsPlayerConnected(playerid))
{
if (IsValidDynamic3DTextLabel(g_chatLabel[playerid]))
{
DestroyDynamic3DTextLabel(g_chatLabel[playerid]);
}
g_chatLabel[playerid] = CreateDynamic3DTextLabel(msg, color, 0.0, 0.0, 0.7, 15.0, playerid, true, -1, -1, playerid, 30.0);
SetTimerEx("ClearChatLabel", 5000, false, "i", playerid);
}
return 0; // чтобы стандартное сообщение не дублировалось
}
строка с ошибкой
g_chatLabel[playerid] = CreateDynamic3DTextLabel(msg, color, 0.0, 0.0, 0.7, 15.0, playerid, true, -1, -1, playerid, 30.0);
forward ClearChatLabel(playeridid);
public ClearChatLabel(playeridid)
{
if(g_chatLabel[playeridid] != Text3D:INVALID_3DTEXT_ID)
{
Delete3DTextLabel(g_chatLabel[playeridid]);
g_chatLabel[playeridid] = Text3D:INVALID_3DTEXT_ID;
}
return 1;
}
Вход
Регистрация
Помощь

Тема закрыта









