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

ds-discord test #5

Draft
wants to merge 12 commits into
base: main
Choose a base branch
from
Draft

ds-discord test #5

wants to merge 12 commits into from

Conversation

harfely
Copy link
Member

@harfely harfely commented Feb 10, 2022

Copy link
Member

@EmptyWork EmptyWork left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Masih ada beberapa hal yang harus diubah.

Selain itu file maju.html harus di hapus juga.

.vscode/launch.json Outdated Show resolved Hide resolved
.vscode/workspace.code-workspace Outdated Show resolved Hide resolved
main.py Show resolved Hide resolved
Comment on lines +28 to +44
if message.channel.name == 'general':
if user_message.lower() == 'hello':
await message.channel.send(f'Hello {username}!')
return
elif user_message.lower() == 'yourname':
await message.channel.send(f'MY Name is DS-DISCORDBOT#8284, {username}!')
return
elif user_message.lower() == 'bye':
await message.channel.send(f'see you later {username}!')
return
elif user_message.lower() == '!random':
response = f'This is your random number: {random.randrange(1000000)}'
await message.channel.send(response)
return
if user_message.lower() == '!anywhere':
await message.channel.send('This can be used anywhere!')
return
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Mungkin bisa tambahkan fitur untuk kelolah isi message

Karena pake discord.ext bisa ubah ke bentuk fungsi, mengikuti tutorial ini

main.py Show resolved Hide resolved
Comment on lines +51 to +52
client.run('OTM0NDM2NzMwNzcyMjkxNTg0.YewEBQ.Y-mKAQVp63S2wtJdJymPmthJtJw')

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
client.run('OTM0NDM2NzMwNzcyMjkxNTg0.YewEBQ.Y-mKAQVp63S2wtJdJymPmthJtJw')
client.run(BOT_TOKEN)

Gunakan lib dotenv untuk BOT_TOKENnya.

@EmptyWork EmptyWork self-assigned this Feb 13, 2022
@EmptyWork EmptyWork added documentation Improvements or additions to documentation enhancement New feature or request labels Feb 13, 2022
@harfely
Copy link
Member Author

harfely commented Feb 14, 2022 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants