[PEDIDO] Arreglar doble mensaje
#1
Hola todos, bueno yo uso el admin chat colors de arion pero tiene un problema cuando el admin esta de espectador o esta muerto los jugadores q estan vivos y escriben en chat les sale el mensaje doble y tambien cuando el admin esta vivo mira los mensajes dobles de los q estan en espectador y tambien los q estan muertos, alguien podria arreglar este problema?.. gracias antemano


Archivos adjuntos
.sma   Descargar AMXX / admin_chat_colors.sma (Tamaño: 10.4 KB / Descargas: 136)
Responder
#2
Muestra tu lista de plugins (plugins.ini) talves tengas el amx_super u otro plugin que hooke el say
Todos los MODS VHL totalmente gratuitos  Descarga Aqui

Mis plugins:
STEAM: https://steamcommunity.com/id/Metrikcz/
FB: fb.com/rwoong
Venta plugins a pedido en México mándame MP
Responder
#3
Si uso el amx_super pero no uso el admin chat color de ahi lo tengo apagado, eso afecta igual si lo tengo apagado?

esta es mi lista de plugins:

zp_addon_parachute.amxx
zp_countdown.amxx
zp_biohazardicon.amxx
zp_addon_ldp.amxx
nademodes.amxx
bullet_damage.amxx
zp_rounddraw_blast.amxx
galileo.amxx
restart.amxx
trueChat.amxx
ad_manager.amxx
high_ping_kicker.amxx
zp_descriptive_fire_in_the_hole.amxx
amx_super.amxx
amx_super_menu.amxx
sound_connect.amxx
mute_menu.amxx
admin_chat_color.amxx
Responder
#4
truechat que es???
prueba desactivando el amx_super y el amxsupermenu y fijate si ya no sale doble si sigue desactiva el truechat y me dises
Todos los MODS VHL totalmente gratuitos  Descarga Aqui

Mis plugins:
STEAM: https://steamcommunity.com/id/Metrikcz/
FB: fb.com/rwoong
Venta plugins a pedido en México mándame MP
Responder
#5
El truechat sirve para q los q estan muertos puedan ver el chat de los vivos pero los vivos no le salen los mensajes de los muertos, ok voy a testiar y aviso..
Responder
#6
Lo testie y lo causa el truechat alguien sabe como lo puedo arreglar? es que no quiero quitar el plugin..

Este es el codigo del truechat:

Código PHP:
#include <amxmodx>
#include <amxmisc>
#include <engine>

#pragma semicolon 1
#define DEBUG 0

new bool:g_heardCounter[33][33];
new 
messageIDSayText;

#if DEBUG == 1 || DEBUG == 2
new filepath[64];
#endif

public plugin_init() 
{
    
register_plugin("Truechat""0.1""MaximusBrood");
    
register_cvar("truechat_version""0.1"FCVAR_SERVER);
    
    
register_event("SayText""catchSay""b");
    
    
messageIDSayText get_user_msgid("SayText");
    
#if DEBUG == 1 || DEBUG == 2
    
get_basedir(filepath63);
    
format(filepath63"%s/logs/trueLog.txt"filepath);
    
    new 
mapname[32];
    
get_mapname(mapname31);
    
log_to_file(filepath"--------Mapchange: %s"mapname);
#endif
}

/*
With the SayText event, the message is sent to the person who sent it last.
It's sent to everyone else before the sender recieves it.
We want to catch the last one because we have had everyone that was supposed to hear it 
Now we will pass the message through to dead people/admins who are originally not supposed to see it.
*/
new gtmp_message[64], gtmp_channel[32], gtmp_senderName[32];

#if DEBUG == 2
new bool:isAdmin false;
#endif

public catchSay(id)
{
    new 
reciever read_data(0);
    new 
sender read_data(1);
    
    
//Register that the current person heard the message
    
g_heardCounter[sender][reciever] = true;
    
    
//Don't continue if it isn't the last message
    
if(sender != reciever)
        return 
PLUGIN_CONTINUE;
        
    
//Get info about message
    
read_data(4gtmp_message63);
    
read_data(2gtmp_channel31);
    
get_user_name(sendergtmp_senderName31);
        
    
//Get players
    
new players[32], playerNumcurrPlayer;
    
get_players(playersplayerNum"c");
    
    
//Loop through all players
    
for(new 0playerNuma++)
    {
        
currPlayer players[a];
        
        
//If the player already got the message, don't check anything at all
        
if(g_heardCounter[sender][currPlayer])
        {
            
g_heardCounter[sender][currPlayer] = false;
            continue;
        }
        
        
//For normal players: See alive chat when dead
        //You need to not have recieved the message and be dead
        //Also, check if it isn't team chat.
        //We do this by looking if there is a _T or CT in the channel name
        // (#CSTRIKE_CHAT_CT[_DEAD] and #CSTRIKE_CHAT_T[_DEAD]
        
if(!is_user_alive(currPlayer) && contain(gtmp_channel"_T") == -&& contain(gtmp_channel"CT") == -1)
        {
            
displayMessage(currPlayersendergtmp_channelgtmp_senderNamegtmp_message);
            
g_heardCounter[sender][currPlayer] = false;
            continue;
        }
        
        
//For admins only. See all chat including team chat
        //You won't see anything double from previous query (the loop was continue'ed)
        
if(get_user_flags(currPlayer) & ADMIN_LEVEL_A)
        {
#if DEBUG == 2
            
isAdmin true;
#endif
            
displayMessage(currPlayersendergtmp_channelgtmp_senderNamegtmp_message);
            
g_heardCounter[sender][currPlayer] = false;
        }
    }
    
    return 
PLUGIN_CONTINUE;
}

new 
gtmp_authid[33];

displayMessage(targetsenderchannel[], senderName[], message[])
{
    
get_user_authid(targetgtmp_authid32);
    
    
//Check for fakeclients or users not connected
    
if(!is_user_connected(target) || !is_user_connected(sender) || equal(gtmp_authid"BOT"))
    {
#if DEBUG == 1 || DEBUG == 2
        
log_to_file(filepath"***: Fakeclient or disconnected user detected. Authid: "gtmp_authid);
#endif        
        
return;
    }
    
#if DEBUG == 2    
    
log_to_file(filepath"%s, %d, %d, %s, %s, %s"isAdmin "Admin" "Normal"targetsenderchannelsenderNamemessage);
    
isAdmin false;
#endif
    
    
message_begin(MSG_ONEmessageIDSayText, {000}, target);
    
write_byte(sender);
    
write_string(channel);
    
write_string(senderName);
    
write_string(message);
    
message_end();

Responder
#7
Dijiste que hace que los vivos lean a los muertos y eso ya lo hace el admin_chat_colors (creo) asi que no lo ocupas.
Todos los MODS VHL totalmente gratuitos  Descarga Aqui

Mis plugins:
STEAM: https://steamcommunity.com/id/Metrikcz/
FB: fb.com/rwoong
Venta plugins a pedido en México mándame MP
Responder
#8
Yo dije q los muertos pueden ver los mensajes de los vivos y los vivos no pueden ver los mensajes de los muertos para q no haya trampa..
Responder
#9
Quita esos dos plugins y prueba el All Chat , Los admins escriben en verded si quieres , y los muertos y vivos se leen a ellos te dejo el link
https://forums.alliedmods.net/showthread.php?t=56825
Responder


Salto de foro:


Usuarios navegando en este tema: 1 invitado(s)