AutoBroadcast

Sends randomly configured chat messages every X amount of seconds

Total Downloads: 7,212 - First Release: Oct 26, 2014 - Last Update: Feb 27, 2017

5/5, 19 likes
  1. Boostmeister

    Boostmeister Scavenger

    {
    "ExampleMessage": "One Week Wipe Cycle!",
    "ExampleMessage1": "/help to get command list!",
    "ExampleMessage2": "/vote to get free signals!",
    "ExampleMessage3": "/kit to see avaible kits!",
    "AnotherExample": "Have a suggestion? Talk to an admin,we're always looking to improve!"
    }


    thats my lang/en
     
  2. Wulf

    Wulf Community Admin Community Admin Oxide Developer

    Try making the ExampleMessage and ExampleMessage1 more different.
     
  3. Boostmeister

    Boostmeister Scavenger

    nope that doesnt work same error message.
     
  4. Xtadeus

    Xtadeus Shack Builder

    Wulf.

    I have put the cs in the plugin directory and I made a try :

    Here are my 2 files : ( config json ) and language json (under en directory). Can you tell me what is wrong ? Because in game I got the messages :

    This is another example, notice the comma at the end od the line above
    This is an example. Change it, remove it, translate it, Whatevers !

    Each time I make a change, and re upload on the FTP, I make a reload of the plugin : no error.

    Thx
     
    Last edited: May 12, 2017
  5. LimitedNight - Rich

    LimitedNight - Rich Naked Wanderer

    this is how mine would look if i used your writing... Hope that helps... if not Wulf is your man... dont froget to reload plugin once done..
     
    Wulf likes this.
  6. Wulf

    Wulf Community Admin Community Admin Oxide Developer

    I don't see anything wrong there, should be fine. Just make sure to reload the plugin as suggested.
     
  7. [YNPA] Fake Death

    [YNPA] Fake Death Wood Hoarder

    Plugin Not working after latest update oxide atleast i dont see my setted broadcast msg anymore

    Code (Text):
    (04:06:26) | Loaded plugin AutoBroadcast v1.0.8 by Wulf/lukespragg
    (04:06:26) | Failed to call hook 'OnServerInitialized' on plugin 'AutoBroadcast v1.0.8' (JsonReaderException: After parsing a value an unexpected character was encountered: ". Path 'Server15', line 18, position 2.)
    (04:06:26) | at Newtonsoft.Json.JsonTextReader.ParsePostValue () [0x00000] in <filename unknown>:0
      at Newtonsoft.Json.JsonTextReader.Read () [0x00000] in <filename unknown>:0
      at Newtonsoft.Json.Serialization.JsonSerializerInternalReader.PopulateDictionary (IDictionary dictionary, Newtonsoft.Json.JsonReader reader, Newtonsoft.Json.Serialization.JsonDictionaryContract contract, Newtonsoft.Json.Serialization.JsonProperty containerProperty, System.String id) [0x00000] in <filename unknown>:0
      at Newtonsoft.Json.Serialization.JsonSerializerInternalReader.CreateObject (Newtonsoft.Json.JsonReader reader, System.Type objectType, Newtonsoft.Json.Serialization.JsonContract contract, Newtonsoft.Json.Serialization.JsonProperty member, Newtonsoft.Json.Serialization.JsonContainerContract containerContract, Newtonsoft.Json.Serialization.JsonProperty containerMember, System.Object existingValue) [0x00000] in <filename unknown>:0
      at Newtonsoft.Json.Serialization.JsonSerializerInternalReader.CreateValueInternal (Newtonsoft.Json.JsonReader reader, System.Type objectType, Newtonsoft.Json.Serialization.JsonContract contract, Newtonsoft.Json.Serialization.JsonProperty member, Newtonsoft.Json.Serialization.JsonContainerContract containerContract, Newtonsoft.Json.Serialization.JsonProperty containerMember, System.Object existingValue) [0x00000] in <filename unknown>:0
      at Newtonsoft.Json.Serialization.JsonSerializerInternalReader.Deserialize (Newtonsoft.Json.JsonReader reader, System.Type objectType, Boolean checkAdditionalContent) [0x00000] in <filename unknown>:0
     
  8. Wulf

    Wulf Community Admin Community Admin Oxide Developer

    That is a JSON error from an invalid .json file. Validate it with a site such as www.jsonlint.com.
     
    [YNPA] Fake Death likes this.
  9. Xtadeus

    Xtadeus Shack Builder

    Strange then it did not display the messages I created. Anyway I decided to use TimedExecute instead to avoid adding an additional plugin.

    Thanks for the answer as usual Wulf.
     
  10. Louwwieee42

    Louwwieee42 Naked Wanderer

    Hi,

    I cant work this out what is wrong with my JSON?
    Code (Text):
    {
        "[BROADCAST]: Welcome to <color=cyan>Rusty Apple</color>, we hope you enjoy your stay!":
        "[BROADCAST]: Please take a moment to check out our forums at. <color=cyan>'[URL='http://www.RustyApple.x10.mx/forums'</color>']www.RustyApple.x10.mx/forums'</color>[/URL] <color=red>(In-Developement.)</color>",
        "[BROADCAST]: If you experience any issues in game be sure to let us know, either IG or on the Forums.":
        "[BROADCAST]: Our Administration Team will be more than happy to help you where possible, call in chat or use our discord channel.",
        "[BROADCAST]: Join us on Discord by navigating to. <color=cyan>https.//discordapp.com/invite/JRQDdbD</color>":
        "[BROADCAST]: Please ensure your stay here is a long and plesant one, by abiding by our rules.",
        "[BROADCAST]: Remember, you can place contacts (hits) on anyone of your choosing using <color=cyan>'/bounty.'</color>":
        "[BROADCAST]: Remeber to check out our clan related commands using <color=cyan>'/clan.'</color>",
        "[BROADCAST]: Kits are available on a cooldown for all players, check them out using <color=cyan>'/kit.'</color>":
        "[BROADCAST]: We have a safe trade system installed, check it out using <color=cyan>'/trade.'</color>",
        "[BROADCAST]: Please remember that we do have an anti-water log out system.":
        "[BROADCAST]: Be sure to modify your friends using <color=cyan>'/friend add / remove name'.</color>",
        "[BROADCAST]: We learnt from others, and have <color=red>not</color> got decay enabled!":
        "[BROADCAST]: Be sure to check out or live map by heading to <color=cyan>'Rust.IO'</color> and then searching for <color=cyan>'Rusty Apple'.</color>",
        "[BROADCAST]: We have a custom loot drop and spawn system!":
        "[BROADCAST]: You can earn some extra cash by farming, and killing animals <color=orange>(possibly some humans too!)</color>",
        "[BROADCAST]: Your cash can be converted, and spent on items and kits in our store. <color=cyan>(/s)</color>":
        "[BROADCAST]: Have you got a cooldown enabled for a kit? But you want it again, buy it in our store! <color=cyan>(/s)</color>",
        "[BROADCAST]: View your <color=green>kill</color> / <color=red>death</color> ratio, using <color=cyan>'/kdr'.</color>":
        "[BROADCAST]: Check your playtime, by using the <color=cyan>'/playtime'</color> command, or check the top other players by using <color=cyan>'/playtime top'.</color>",
        "[BROADCAST]: Did you refer your friend here? If so, you can both gain some extra cash by letting us know. <color=cyan>(/refer)</color>":
        "[BROADCAST]: Have you spotted a suspect <color=red>hacker</color> or <color=red>glitcher?</color> Report them using the <color=cyan>'/report'</color> command!",
        "[BROADCAST]: When using the <color=cyan>'/report'</color> command, all admins recieve a Steam PM with the report details.":
        "[BROADCAST]: Be sure to respect everyone on the server, not just the Administration Team!",
        "[BROADCAST]: If you have a complaint about a member of our Administration Team, or a Player be sure to let us know on our forums!":
        "[BROADCAST]: Did you know your levels increase faster during night time?",
        "[BROADCAST]: Have you invited someone here? Be sure to claim your reward using <color=cyan>(/refer)</color>":
        "[BROADCAST]: We have Sign Artist installed, be sure to check it out <color=cyan>(/sil)</color>",
        "[BROADCAST]: Be sure to check out our brand new store using <color=cyan>(/s)</color>":
         }
     
    Last edited by a moderator: Jun 10, 2017
  11. Wulf

    Wulf Community Admin Community Admin Oxide Developer

    You're missing a " after each key name, you have a : at the end of some when it should be a comma, and you aren't using unique key names (they can't all be [BROADCAST].)
     
  12. Louwwieee42

    Louwwieee42 Naked Wanderer

    Code (Text):
    {
        "[Rusty Apple]": Welcome to <color=cyan>Rusty Apple</color>, we hope you enjoy your stay!",
        "[Forums]": Please take a moment to check out our forums at. <color=cyan>'[URL='http://www.RustyApple.x10.mx/forums'</color>']www.RustyApple.x10.mx/forums'</color>[/URL] <color=red>(In-Developement.)</color>",
        "[Feedback]": If you experience any issues in game be sure to let us know, either IG or on the Forums.",
        "[Administration]": Our Administration Team will be more than happy to help you where possible, call in chat or use our discord channel.",
        "[Discord]": Join us on Discord by navigating to. <color=cyan>https.//discordapp.com/invite/JRQDdbD</color>",
        "[Rules]": Please ensure your stay here is a long and plesant one, by abiding by our rules.",
        "[Bounty]": Remember, you can place contacts (hits) on anyone of your choosing using <color=cyan>'/bounty.'</color>",
        "[Clans]": Remeber to check out our clan related commands using <color=cyan>'/clan.'</color>",
        "[Kits]": Kits are available on a cooldown for all players, check them out using <color=cyan>'/kit.'</color>",
        "[Trade]": We have a safe trade system installed, check it out using <color=cyan>'/trade.'</color>",
        "[Anti-Water Log]": Please remember that we do have an anti-water log out system.",
        "[Friends]": Be sure to modify your friends using <color=cyan>'/friend add / remove name'.</color>",
        "[Decay]": We learnt from others, and have <color=red>not</color> got decay enabled!",
        "[Live Map]": Be sure to check out or live map by heading to <color=cyan>'Rust.IO'</color> and then searching for <color=cyan>'Rusty Apple'.</color>",
        "[Loot]": We have a custom loot drop and spawn system!",
        "[Cash]": You can earn some extra cash by farming, and killing animals <color=orange>(possibly some humans too!)</color>",
        "[Store]": Your cash can be converted, and spent on items and kits in our store. <color=cyan>(/s)</color>",
        "[Kit /Store]": Have you got a cooldown enabled for a kit? But you want it again, buy it in our store! <color=cyan>(/s)</color>",
        "[KDR]": View your <color=green>kill</color> / <color=red>death</color> ratio, using <color=cyan>'/kdr'.</color>",
        "[Playtime]": Check your playtime, by using the <color=cyan>'/playtime'</color> command, or check the top other players by using <color=cyan>'/playtime top'.</color>",
        "[Refer]": Did you refer your friend here? If so, you can both gain some extra cash by letting us know. <color=cyan>(/refer)</color>",
        "[Reporting]": Have you spotted a suspect <color=red>hacker</color> or <color=red>glitcher?</color> Report them using the <color=cyan>'/report'</color> command!",
        "[Report]": When using the <color=cyan>'/report'</color> command, all admins recieve a Steam PM with the report details.",
        "[Respect]": Be sure to respect everyone on the server, not just the Administration Team!",
        "[Complaints]": If you have a complaint about a member of our Administration Team, or a Player be sure to let us know on our forums!",
        "[Levels]": Did you know your levels increase faster during night time?,
        "[Store]": Be sure to check out our brand new store using. <color=cyan>(/s)</color>"}

    Should this now be okay?
     
  13. Wulf

    Wulf Community Admin Community Admin Oxide Developer

    You're missing a " in the first line still, check using www.jsonlint.com.
     
  14. Louwwieee42

    Louwwieee42 Naked Wanderer

    I don't see where I am missing one, sorry im new to these JSON files.

    I also have another urgent issue here.
     
  15. Wulf

    Wulf Community Admin Community Admin Oxide Developer

    First line, right before Welcome. You're actually missing it at the start of each from the looks of it. The 2nd from last line also is missing a " before the comma at the end.
     
  16. Louwwieee42

    Louwwieee42 Naked Wanderer

    Thanks alot Wulf, the issue has been resolved.
     
    Last edited: Jun 10, 2017
  17. StedHead

    StedHead Naked Wanderer

    when i put this on my server it only plays 1 message it wont cycle through any idea?
     
  18. Wulf

    Wulf Community Admin Community Admin Oxide Developer

    What does your oxide/lang file look like?
     
  19. StedHead

    StedHead Naked Wanderer

    Last edited: Jun 15, 2017
  20. Wulf

    Wulf Community Admin Community Admin Oxide Developer

    I'd recommend naming the keys something more unique, not 1, 2, 3, etc. Also, make sure to reload the plugin after your changes.