BetterChat

Moved

Total Downloads: 26,143 - First Release: Apr 21, 2015 - Last Update: Jan 12, 2018

4.9898/5, 98 likes
  1. yes i did in chat : /reload BetterChat
    Code:
    [
      {
        "GroupName": "admin",
        "Priority": 1,
        "Title": {
          "Text": "[ADMIN]",
          "Color": "Red",
          "Size": 15,
          "Hidden": false,
          "HiddenIfNotPrimary": false
        },
        "Username": {
          "Color": "Lime",
          "Size": 15
        },
        "Message": {
          "Color": "white",
          "Size": 15
        },
        "Format": {
          "Chat": "{Title} {Username}: {Message}",
          "Console": "{Title} {Username}: {Message}"
        }
      },
      {
        "GroupName": "default",
        "Priority": 0,
        "Title": {
          "Text": "[Player]",
          "Color": "#55aaff",
          "Size": 15,
          "Hidden": true,
          "HiddenIfNotPrimary": true
        },
        "Username": {
          "Color": "#55aaff",
          "Size": 15
        },
        "Message": {
          "Color": "white",
          "Size": 15
        },
        "Format": {
          "Chat": "{Title} {Username}: {Message}",
          "Console": "{Title} {Username}: {Message}"
        }
      },
      {
        "GroupName": "vip",
        "Priority": 2,
        "Title": {
          "Text": "[vip]",
          "Color": "#red",
          "Size": 15,
          "Hidden": false,
          "HiddenIfNotPrimary": false
        },
        "Username": {
          "Color": "#87EFFF",
          "Size": 15
        },
        "Message": {
          "Color": "white",
          "Size": 15
        },
        "Format": {
          "Chat": "{Title} {Username}: {Message}",
          "Console": "{Title} {Username}: {Message}"
        }
      },
      {
        "GroupName": "vip1",
        "Priority": 3,
        "Title": {
          "Text": "[vip]",
          "Color": "#FEB5FD",
          "Size": 15,
          "Hidden": false,
          "HiddenIfNotPrimary": false
        },
        "Username": {
          "Color": "#FEB5FD",
          "Size": 15
        },
        "Message": {
          "Color": "white",
          "Size": 15
        },
        "Format": {
          "Chat": "{Title} {Username}: {Message}",
          "Console": "{Title} {Username}: {Message}"
        }
      }
    ]
     
  2. Code:
    [
      {
        "GroupName": "admin",
        "Priority": 0,
        "Title": {
          "Text": "[ADMIN]",
          "Color": "Red",
          "Size": 15,
          "Hidden": false,
          "HiddenIfNotPrimary": false
        },
        "Username": {
          "Color": "Lime",
          "Size": 15
        },
        "Message": {
          "Color": "white",
          "Size": 15
        },
        "Format": {
          "Chat": "{Title} {Username}: {Message}",
          "Console": "{Title} {Username}: {Message}"
        }
      },
      {
        "GroupName": "default",
        "Priority": 1,
        "Title": {
          "Text": "[Player]",
          "Color": "#55aaff",
          "Size": 15,
          "Hidden": false,
          "HiddenIfNotPrimary": true
        },
        "Username": {
          "Color": "#55aaff",
          "Size": 15
        },
        "Message": {
          "Color": "white",
          "Size": 15
        },
        "Format": {
          "Chat": "{Title} {Username}: {Message}",
          "Console": "{Title} {Username}: {Message}"
        }
      },
      {
        "GroupName": "vip",
        "Priority": 2,
        "Title": {
          "Text": "[vip]",
          "Color": "#red",
          "Size": 15,
          "Hidden": false,
          "HiddenIfNotPrimary": false
        },
        "Username": {
          "Color": "#87EFFF",
          "Size": 15
        },
        "Message": {
          "Color": "white",
          "Size": 15
        },
        "Format": {
          "Chat": "{Title} {Username}: {Message}",
          "Console": "{Title} {Username}: {Message}"
        }
      },
      {
        "GroupName": "vip1",
        "Priority": 3,
        "Title": {
          "Text": "[vip]",
          "Color": "#FEB5FD",
          "Size": 15,
          "Hidden": false,
          "HiddenIfNotPrimary": false
        },
        "Username": {
          "Color": "#FEB5FD",
          "Size": 15
        },
        "Message": {
          "Color": "white",
          "Size": 15
        },
        "Format": {
          "Chat": "{Title} {Username}: {Message}",
          "Console": "{Title} {Username}: {Message}"
        }
      }
    ]
    Here this should work. I believe you set the priorities wrong.
     
  3. Thank you very much @LaserHydra, works great now !
     
  4. thank you so much ! .. yes its working good now :D
    i have to edit the vip Priority too now ..
     
  5. I think it's because RustAdmin made a specific handler for BetterChat messages because default chat messages type wasn't sent before this update (That's excalty what i've done for manage BetterChat message in my app before update: https://i.imgur.com/0VKbuhB.png)

    So now, there are two message handlers on RustAdmin (one for default messages and one for BetterChat message), that's why you see 2 messages.

    RustAdmin should remove the BetterChat specific handler now that BetterChat respect the chat type.
     
  6. Thanks for your answer!

    I liked the old method better though. All we need is for it to show up in the "Chat" tab, so it don't spam the Console tab :p
     
  7. Yes. Thats correct.
    [DOUBLEPOST=1505841525][/DOUBLEPOST]
    0 > 1 for Priorities

    So admin = 0
    player = 1
    [DOUBLEPOST=1505841733][/DOUBLEPOST]
    This update should have made it easier for RCON tools developers to make it show up in chat.
     
  8. When that string is printed into console it gives this: System.Collections.Generic.List`1[System.Object]

    Any ideas?
     
  9. The only problem with that is that the developer of RustAdmin is no longer maintaining it / really inactive ;)

    Do you have a copy of the old version before this one? I would like to go back.. :)
     
  10. See the version history here: Better Chat - Version History | Oxide and take the version 5.0.12.
     
  11. Yes, because its a List<object> lol.
    Its a list of all groups the user is in.
     
  12. Riiiight... And how would i go about making it so it puts out all the groups?
     
  13. You could use JObjects for example to extract information about the groups, or as said, if you require BetterChat, just cast them to "BetterChat.ChatGroup"
     
  14. Is there any way to get betterchat to display in rcon.io/chat?
    Thanks
     
  15. It works for me (tested with BetterChat 5.0.13).

    EDIT: Ok i'm wrong, the history doesn't works for me. I can see messages sent by BetterChat in real time when i'm on the chat page, but messages are not persisted in the history.
     
    Last edited by a moderator: Sep 20, 2017
  16. I'm using the same version and if I change tabs the chat disappears.
     
  17. yes just see this right now

    Does it works better with the previous version (5.0.12) ?
     
    Last edited by a moderator: Sep 20, 2017
  18. Ok I investigated and I think I know what goes wrong with the chat history.

    Rcon.io use the RCON command "chat.tail 200" to get the 200 latest messages sent to the server (output example: https://i.imgur.com/5JXAr7m.png).

    But only regular messages are returned (messages sent without BetterChat). It means BetterChat messages are not stored in the server memory when they are sent.

    To make this feature works, @LaserHydra must manually insert BetterChat message in this memory to persist them as regular messages, but I really don't know if it's possible.
     
    Last edited by a moderator: Sep 20, 2017
  19. I think I saw that line, though the attribute was private. I could access it using reflection though, if required.