Jump to content

Send a chat message as the player


onlyhtml

Recommended Posts

I'm looking for a way to send a chat message as the player would when he presses "t". I'm not looking to send a message to the player, I'm looking to send a message AS the player. Please don't suggest player.sendChatToPlayer or player.addChatMessage. Does anybody know how to do this? Thanks!

Link to comment
Share on other sites

If you are trying to tell ALL the people on the server (like a fake chat message), cycle through all the players and have a translatable message that takes the player's username/display name as a parameter. That would be a way of doing it.

-Mitchellbrine

 

Minecraft can do ANYTHING, it's coded in Java and you got the full power of Java behind you when you code. So nothing is impossible.

It may be freaking fucking hard though, but still possible ;)

 

If you create a topic on Modder Support, live by this motto:

I don't want your charity, I want your information
Link to comment
Share on other sites

You should've mentioned that first. That wasn't really clear.

 

- - -

 

You should create a bot for IRC and have it relay messages. This is sort of the concept of EiraIRC (which is open-source if you need help with your code).

-Mitchellbrine

 

Minecraft can do ANYTHING, it's coded in Java and you got the full power of Java behind you when you code. So nothing is impossible.

It may be freaking fucking hard though, but still possible ;)

 

If you create a topic on Modder Support, live by this motto:

I don't want your charity, I want your information
Link to comment
Share on other sites

Sokaya, no. He is talking about sending a message as the player to an IRC channel, not to the server. Yes, that would work if we were sending a message as the player to the server, but not if we were trying to relay a chat message to IRC.

-Mitchellbrine

 

Minecraft can do ANYTHING, it's coded in Java and you got the full power of Java behind you when you code. So nothing is impossible.

It may be freaking fucking hard though, but still possible ;)

 

If you create a topic on Modder Support, live by this motto:

I don't want your charity, I want your information
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Announcements



×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.