Information Announcer

Join/leave messages, rules, broadcasts & custom commands

Total Downloads: 2,609 - First Release: May 5, 2015 - Last Update: May 23, 2015

4.73333/5, 15 likes
  1. Error

    Code:
    Error while compiling Announcer.cs(206,37): error CS0246: The type or namespace
    name `Player' could not be found. Are you missing `Oxide.Game.Rust.Libraries' us
    ing directive?
    
     
  2. Wulf

    Wulf Community Admin

    This plugin is for Reign of Kings only.
     
  3. I'm new to this whole thing and I am trying. I just don't know what I'm doing wrong. After I input all my rules and changes, I save it, I restart the server, and as soon as I reopen Announcer.json it switches back to the default.
    Code:
    {
      "BroadcasterSettings": {
        "Enabled": true,
        "Interval": 30,
        "Messages": [
          "You can visit our forums at [URL='http://www.oxidemod.org']www.oxidemod.org[/URL]!",
          "Don't forget to bring your friends!",
          "Type /rules to see our server's rules!"
        ],
        "ShowChatPrefix": true,
        "ShowInRandomOrder": false
      },
      "BroadCasterSettings": {
        "BroadcastMessages": [
          "Go and build crazy and unique shit!",
          "Don't forget to bring your friends!",
          "Type /rules to see our server's rules!"
        ]
      },
      "ConnectionSettings": {
        "Enabled": true,
        "ExcludePlayers": [],
        "Log": true,
        "ShowChatPrefix": true,
        "ShowJoinMessages": true,
        "ShowLeaveMessages": true
      },
      "CustomCommands": {
        "Commands": {},
        "ShowChatPrefix": true
      },
      "Messages": {
        "PlayerJoined": "{0} has clocked in for business.",
        "PlayerLeft": "{0} is calling it a day."
      },
      "RulesSettings": {
        "Enabled": true,
        "Rules": [
          "1. Do not cheat on our server.",
          "2. No Exploiting!",
          "3. Do not harass other players!",
          "4. Do not Kos! This is an RP Server.",
          "5. Do not build around resources to prevent other players from acquiring them!.",
          "6. Do not be a dick!",
          "7. English is the primary language of this server. Please try to speak it in chat or use google translate.",
          "8. Have an appropriate RP name. Be original with it.",
          "9. Repect the players who just want to be peaceful RP builders/farmers/fisherman/etc. Act like they are NPCs that you can't hurt but can interact with.",
          "10. Respect all the admins and mods. They just want to build and RP too.",
          "11. No skybridging to get into bases. No breaking blocks to get into bases. However, lockpicking your way into a base is perfectly acceptable.",
          "12. You must have a valid RP reason to go to war. "They were mean to me" is not a valid reason. Give the RP some effort or no war for you!",
          "13. Do not be a dick!",
          "14. You must be level 10 in order to be King.",
          "15. The king may not tax over 3%. Doing so may result in any sort of punishment depending on the admin.",
          "16. Admin word is final. We are chill people. We just want everyone to have fun. Fuck with that and you are in trouble. Enjoy!",
          "Not complying with these rules may result in a ban at any given time."
        ],
        "ShowChatPrefix": true
      },
      "Settings": {
        "ChatPrefix": "Server",
        "ChatPrefixColor": "950415"
      }
    }
     
    Last edited by a moderator: Apr 1, 2017
  4. Wulf

    Wulf Community Admin

    That happens when you do not edit it correctly. It needs to be valid JSON, which you can check with a site such as JSONLint - The JSON Validator.. According to it, you're missing some \ to escape quotation marks inside one message.
     
  5. Thank you so much. That helped me fix it.
     
  6. Hello i need help with adding rules i just started it and no idea what to do. Need help asp because ive just made a server. How to add the rules. i cant seem to find the default rules. Anyway ive looked so may times. NO IDEA. Please can someone help me! REPLY BACK ASP!
     

  7. Mayby( !",) its not right? Test (!.",).not sure if that help.not see any other reason why its reset that default
     
  8. how do i make it popup window instead in chat ? anyone know how
     
  9. Hi, I'm struggling to get the rules working! I've editted the original Announcer.txt and it either shows deault rules on the server or not at all.
    Please could you help! Thanks
     

    Attached Files:

  10. Wulf

    Wulf Community Admin

    Your edits are not valid; make sure to follow the same format as the default config and add any commas where necessary. You can check to see where your errors are by using a tool such as www.jsonlint.com. When you have made valid changes, simply reload the plugin.
     
  11. Thanks! I've editted it and used the checker. Only error was the first line but not sure why and nothing would resolve it
     
  12. Wulf

    Wulf Community Admin

    Edit the messages, not the plugin itself.
     
  13. Sorry to sound so stupid lol, but how do I do that?
    Thanks so much for your patience!
     
  14. Wulf

    Wulf Community Admin

    oxide/config/Announcer.json
     
  15. I can't open or edit the .json. It only lets me rename it or download it but the download button doesn't actually do anything.
    Sorry!
     

    Attached Files:

    • json.jpg
      json.jpg
      File size:
      130.5 KB
      Views:
      40
  16. Wulf

    Wulf Community Admin

    Download, open in Notepad++ or similar editor, edit, save, upload, reload plugin.
     
  17. When I put in the .cs file, it does not make a .json file. At first, I thought this was an issue with my text that I added, but when I put in the regular file downloaded straight from here, it's still doing so.

    Does anyone have a fresh .json file that I can edit with the server rules in it? Or perhaps someone might know a solution to this issue that I am having?
     
  18. Wulf

    Wulf Community Admin

    Are you trying to install it on a game other than Reign of Kings? Also, check your oxide/logs for errors. If the plugin isn't generating the config, the plugin most likely is not loading.
     
  19. I only use this for Reign of Kings thankfully. I noticed this in the eror file: "8:08 AM [Error] Plugin filename Announcer(72310171).cs must match the main class Announcer (should be Announcer.cs)"

    I've since saved the file as 'Announcer.cs' which just names it 'Announcer'. Somehow, this fixed the issue -.-

    Thank you for pointing me in the right direction, Wulf. You have my appreciation.
     
  20. Wulf

    Wulf Community Admin

    If the filename does not match what it says (Announcer.cs), it will not compile.