Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug with handling chat #3582

Open
1 task done
Rilliat opened this issue Feb 12, 2025 · 0 comments
Open
1 task done

Bug with handling chat #3582

Rilliat opened this issue Feb 12, 2025 · 0 comments
Labels
possible bug Stage1 just created by someone new to the project, we don't know yet if it deserves an implementation / a f

Comments

@Rilliat
Copy link

Rilliat commented Feb 12, 2025

  • The FAQ doesn't contain a resolution to my issue

Versions

  • mineflayer: 4.26.0
  • server: paper 1.21.1
  • node: 22.13.1

Detailed description of a problem

If message is sent by someone playing with Geyser (his nickname starts with "."), if I log his username in function, the dot in the beginning disappears.

What did you try yet?

I tried to log all args that come in the function and in "complete chat message" that dot exists, but in username it doesn't.

Your current code

from javascript import require, On, Once
from config import bot_config

mineflayer = require('mineflayer')

bot = mineflayer.createBot(bot_config)


@On(bot, 'chat')
def onChat(username, *args):
    print(username)
    print(args)

Expected behavior

username argument has the dot in the beginning

Additional context

Image
Image
Image

@Rilliat Rilliat added possible bug Stage1 just created by someone new to the project, we don't know yet if it deserves an implementation / a f labels Feb 12, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
possible bug Stage1 just created by someone new to the project, we don't know yet if it deserves an implementation / a f
Projects
None yet
Development

No branches or pull requests

1 participant