Raised This Month: $56 Target: $400
 14% 

Simple Chat Processor


Post New Thread Reply   
 
Thread Tools Display Modes
Author
Antithasys
Moderator
Join Date: Apr 2008
Plugin ID:
2572
Plugin Version:
1.0.1
Plugin Category:
Technical/Development
Plugin Game:
Any
Plugin Dependencies:
    Servers with this Plugin:
    94 
    Plugin Description:
    Provides global forward for chat messages.
    Unapprover:
    Reason for Unapproving:
    Spams errors, ignored by author.
    Old 09-20-2011 , 14:04   Simple Chat Processor
    Reply With Quote #1

    Simple Chat Processor

    Description:
    Provides global forward for chat messages allowing other plugins to manipulate the display of chat messages.
    Currently this only supports SayText2 usermessage.
    Console Variables:
    None.
    Installation:
    Place the simple-chatprocessor.smx in the /sourcemod/plugins dir.
    Place the appropriate phrases file in the /sourcemod/translations dir.
    Changelog:

    Quote:
    1.0.1
    ! Fixed memory leak on no action

    1.0.0
    Release
    Include File

    PHP Code:
    /**********************************************************************
     * When a player types a chat message
     *
     * NOTES:
     * Use MAXLENGTH_  constants above for formating the strings
     * Do not rely on the recipients handle to exist beyond the forward
     * Do not start another usermessage (PrintToChat) within this forward
     *
     * @param         author        The client index of the player who sent the chat message (Byref)
     * @param         recipients    The handle to the client index adt array of the players who should recieve the chat message
     * @param         name          The client's name of the player who sent the chat message (Byref)
     * @param         message       The contents of the chat message (Byref)
     * @noreturn
     **********************************************************************/
    forward Action:OnChatMessage(&authorHandle:recipientsString:name[], String:message[]);



    /**********************************************************************
     * Gets the current flags for the chat message
     * Should only be called within OnChatMessage()
     *
     * @return        The current type of chat message (see constants) 
     **********************************************************************/
     
    native GetMessageFlags(); 
    Notes:

    This plugin by itself does nothing. This plugin is the core plugin for the following other plugins:

    Simple Chat Colors
    Simple Chat Filter
    Simple Chat Responses
    Simple Chat All Dead
    Simple Chat Me

    If you want to use any of the above plugins you will need this plugin as well.
    Of course, anyone else is free to use this for their own plugins too!

    SVN (or Beta Links)

    If you want the latest version on the SVN you can use the links below. The release version of the plugin is attached.

    Source | Include | Plugin | No Config | Phrases

    Enjoy!
    Attached Files
    File Type: inc scp.inc (3.8 KB, 8972 views)
    File Type: txt scp.cstrike.phrases.txt (977 Bytes, 8979 views)
    File Type: txt scp.l4d.phrases.txt (752 Bytes, 2492 views)
    File Type: txt scp.l4d2.phrases.txt (752 Bytes, 3033 views)
    File Type: txt scp.tf.phrases.txt (709 Bytes, 17926 views)
    File Type: sp Get Plugin or Get Source (simple-chatprocessor.sp - 23192 views - 13.7 KB)
    __________________
    [my plugins]

    When you think about asking a question... consider what have you tried?

    Last edited by Antithasys; 09-21-2011 at 13:49.
    Antithasys is offline
    Antithasys
    Moderator
    Join Date: Apr 2008
    Old 09-20-2011 , 14:05   Re: Simple Chat Processor
    Reply With Quote #2

    Reserved.
    __________________
    [my plugins]

    When you think about asking a question... consider what have you tried?
    Antithasys is offline
    micazoid
    Veteran Member
    Join Date: Oct 2010
    Location: Munich - Germany
    Old 09-21-2011 , 13:22   Re: Simple Chat Processor
    Reply With Quote #3

    Will this work for Day of Defeat Source also?

    I am asking because there is no translation file for dods

    EDIT: OkeylyDokely

    It will not work

    Quote:
    18:24:40 [simple-chatprocessor.smx] [SCP] Recognized mod [Day Of Defeat].
    18:24:40 [simple-chatprocessor.smx] [SCP] Translation file is not present
    18:24:40 [SM] Plugin encountered error 25: Call was aborted
    18:24:40 [SM] Native "SetFailState" reported: Translation file is not present
    18:24:40 [SM] Displaying call stack trace for plugin "simple-chatprocessor.smx":
    18:24:40 [SM] [0] Line 140, /home/groups/alliedmodders/forums/files/3/6/9/5/4/92887.attach::OnPluginStart()
    __________________

    Last edited by micazoid; 09-21-2011 at 13:25.
    micazoid is offline
    Antithasys
    Moderator
    Join Date: Apr 2008
    Old 09-21-2011 , 13:29   Re: Simple Chat Processor
    Reply With Quote #4

    The short answer... no.

    Unfortunately DOD:S doesn't support saytext2. I was going to add saytext but it didn't seem like a helpful option, since it could cause more problems than it solves. DOD:S does the translation very differently than the other OB games, and colors are determined by engine itself.
    __________________
    [my plugins]

    When you think about asking a question... consider what have you tried?
    Antithasys is offline
    micazoid
    Veteran Member
    Join Date: Oct 2010
    Location: Munich - Germany
    Old 09-21-2011 , 13:35   Re: Simple Chat Processor
    Reply With Quote #5

    hm thats not good

    Is there any chance, that the Tag functions of simple chat colors may work somehow?
    __________________
    micazoid is offline
    Antithasys
    Moderator
    Join Date: Apr 2008
    Old 09-21-2011 , 13:46   Re: Simple Chat Processor
    Reply With Quote #6

    Quote:
    Originally Posted by micazoid View Post
    hm thats not good

    Is there any chance, that the Tag functions of simple chat colors may work somehow?
    I have not seen, nor could I find, an SDK for DOD:S that shows how the client functions process the saytext usermessage. I also do not have a server to test variations against. If you want to offer your help, I can try to do something, but it would require some back and forth.

    EDIT:

    The SDK's here are for OB, which includes DOD:S, but for some reason the client hud is not processed as this SDK would indicate.
    __________________
    [my plugins]

    When you think about asking a question... consider what have you tried?

    Last edited by Antithasys; 09-21-2011 at 13:51.
    Antithasys is offline
    micazoid
    Veteran Member
    Join Date: Oct 2010
    Location: Munich - Germany
    Old 09-21-2011 , 13:56   Re: Simple Chat Processor
    Reply With Quote #7

    I am not a programmer. The only help I can offer is:

    First this

    And a server for testing.

    BTW:
    I am not looking for chatcolors. The only thing I am looking for is to give certain admingroups certain tags (and maybe colors XD ). I have in mind to set up a VIPsystem, with different ClanTags.
    This Plugin does have a "automatic add a Tag"-function but only for one group of admins.

    Maybe I can do more to help, that I cant see atm.
    Just ask, I will help werever I can to do this.
    __________________
    micazoid is offline
    Antithasys
    Moderator
    Join Date: Apr 2008
    Old 09-21-2011 , 14:13   Re: Simple Chat Processor
    Reply With Quote #8

    Since you are not really looking to have this processor support DOD:S I think the correct line of action for you is to get that plugin you linked to work in the manner you want. Maybe post it in Plugin Requests and a description of how you want it modified. This is really just a processor to supply forwards, and all I could do here is support saytext, and like I said, that is problematic.
    __________________
    [my plugins]

    When you think about asking a question... consider what have you tried?
    Antithasys is offline
    micazoid
    Veteran Member
    Join Date: Oct 2010
    Location: Munich - Germany
    Old 09-21-2011 , 14:21   Re: Simple Chat Processor
    Reply With Quote #9

    oki. Thank you.

    And there is no chance, that you can rip the Tagfunctionality out of that=

    I do not want to get on your nerves, I am just thinking, that the code is already there

    If not, then I will request this.

    Thanks for your fast replies. And I almost forgot. Good work. This is very interesting stuff you wrote there
    __________________
    micazoid is offline
    adrianman
    Senior Member
    Join Date: Sep 2010
    Old 09-23-2011 , 05:49   Re: Simple Chat Processor
    Reply With Quote #10

    the l4d translation files are named incorrectly if you get the game folder name,should be left4dead instead of l4d and left4dead2 instead of l4d2
    adrianman 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 13:39.


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