Solved How to define a message in a server broadcast

Discussion in 'Plugin Development' started by Whomp54, Jun 28, 2013.

Thread Status:
Not open for further replies.
  1. Offline

    Whomp54

    So im working on a plugin (barely has any code so im not even going to post it) where the goal is for a person to type a command ex: /isay <message> and the message will be broadcasted to the whole server. What is the code for getting the message from the player? I know how to do the rest.
     
  2. there is already that command in essentials.
     
  3. Offline

    Whomp54

    Sorry totally spaced on that... I meant like /isay But still... How do i do that?

    Fixed the question :p

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: Jun 2, 2016
  4. Offline

    Ivan

    getServer().broadcastMessage("message")
     
  5. Offline

    Whomp54

    I know how to do that Ivan, but when I do that, the message i type after the command doesnt show up. How do I add the message?

    never mind i figured it out. Just took a little googling power :p It just took the right words to find it.

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: Jun 2, 2016
  6. Offline

    Techy4198

    for all you other guys who were no help, he was basically looking for this:
    getServer().broadcastMessage(args[0]);
     
Thread Status:
Not open for further replies.

Share This Page