Coder Social home page Coder Social logo

Comments (9)

Mumfrey avatar Mumfrey commented on July 18, 2024

I think it's entirely possible that the overloads on Player.sendMessage() may go since they're redundant. Message already implements Iterable<Message> anyway and the String overload doesn't really make sense anyway since it just forces the server to wrap the String in a Message object internally. If anything, Player.sendMessage should be unified with Game.broadcastMessage()

from spongeapi.

nightpool avatar nightpool commented on July 18, 2024

@Mumfrey so things like player.sendMessage("Hi! Welcome to our server");
shouldn't work? That sounds like its introducing another layer or
complexity where it really doesn't need to be to me...

On Mon, Dec 15, 2014 at 11:40 AM, Mumfrey [email protected] wrote:

I think it's entirely possible that the overloads on Player.sendMessage()
may go since they're redundant. Message already implements
Iterable anyway and the String overload doesn't really make
sense anyway since it just forces the server to wrap the String in a
Message object internally. If anything, Player.sendMessage should be
unified with Game.broadcastMessage()


Reply to this email directly or view it on GitHub
#287 (comment)
.

from spongeapi.

Soren025 avatar Soren025 commented on July 18, 2024

@nightpool that would be player.sendMessage(Massages.of("Hi! Welcome to our server")); without the overloads

from spongeapi.

nightpool avatar nightpool commented on July 18, 2024

@Soren025 Right, but that's another API to learn and another Class' javadoc
to look at. Seems like a pointless change that makes things harder on API
consumers to me. What's the problem with maintaining a sendMessage
overload? (and making a comparable broadcastMessage one of course)

On Mon, Dec 15, 2014 at 9:00 PM, Soren025 [email protected] wrote:

@nightpool https://github.com/nightpool that would be player.sendMessage(Massages.of("Hi!
Welcome to our server")); without the overloads


Reply to this email directly or view it on GitHub
#287 (comment)
.

from spongeapi.

Zidane avatar Zidane commented on July 18, 2024

...because Minecraft's chat system doesn't work like this anymore. The API should serve to teach the plugin developer that yes there is formatting, styles, etc. Instead of masking it behind the scenes by having the server make the message object.

from spongeapi.

nightpool avatar nightpool commented on July 18, 2024

@Zidane but that's what the overload is there for?

Okay anyway it doesn't matter THAT much I'm not looking to start a religious war over this.

from spongeapi.

JonathanBrouwer avatar JonathanBrouwer commented on July 18, 2024

I think the best is to have both a sendMessage for String, and Message

from spongeapi.

Sannholm avatar Sannholm commented on July 18, 2024

I agree with Zidane and think there should only be a sendMessage for Messages. And people can make their own helper methods for Strings, if they need to.

from spongeapi.

maxov avatar maxov commented on July 18, 2024

Closing in favor of #425

from spongeapi.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.