Raised This Month: $105 Target: $400
 26% 

How do I clean up console code?


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
msbeden
Junior Member
Join Date: Jan 2020
Location: Turkey, Eskisehir
Old 01-10-2020 , 10:44   How do I clean up console code?
Reply With Quote #1

Hello friends, there is too much code on the console screen. I want to clean them up. I just want the player messages to appear. I have a plugin. But it can do some operations. I don't know what variables to use. Can you help me?

Code:
#include <amxmodx>

public plugin_init() {
    register_plugin("Gereksiz Mesajlar", "1.0", "msbeden")

    register_clcmd("radio1", "Clcmd_Radio")
    register_clcmd("radio2", "Clcmd_Radio")
    register_clcmd("radio3", "Clcmd_Radio")

    register_message(get_user_msgid("TextMsg"), "Message_TextMsg")
}

public Clcmd_Radio(id)
{
    return 1;
}

public Message_TextMsg(msgid, msgdest, id)
{
    static msg[23]
    get_msg_arg_string(2, msg, charsmax(msg))
    if(equal(msg, "#Game_teammate_attack") || equal(msg, "#Game_unknown_command") || equal(msg, "#Killed_Teammate") || equal(msg, "#Game_connected") || equal(msg, "#Game_disconnected")) return 1;
    if(get_msg_args() == 5)
    {
        static msg2[18]
        get_msg_arg_string(5, msg2, charsmax(msg2))
        if(equal(msg2, "#Fire_in_the_hole")) return 1;
    }
    return 0;
}
Examples I want to clean:

GAMER dropped
GAMER died
GAMER killed GAMER with awp
GAMER killed GAMER with a headshot from aug ***

Last edited by msbeden; 01-10-2020 at 10:50.
msbeden is offline
msbeden
Junior Member
Join Date: Jan 2020
Location: Turkey, Eskisehir
Old 01-13-2020 , 11:22   Re: How do I clean up console code?
Reply With Quote #2

Up Up
msbeden is offline
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 22:18.


Powered by vBulletin®
Copyright ©2000 - 2020, vBulletin Solutions, Inc.
Theme made by Freecode