ProgrammingWriting Your First Discord Bot [Tutorial]
Posted:

ProgrammingWriting Your First Discord Bot [Tutorial]Posted:

module
  • Resident Elite
Status: Offline
Joined: Mar 13, 20168Year Member
Posts: 266
Reputation Power: 31
Status: Offline
Joined: Mar 13, 20168Year Member
Posts: 266
Reputation Power: 31
Would recommend downloading visual studio code.

Step 1: Create A Project Folder & Open CMD.
https://gyazo.com/9d32eccd893300d734728b72ae397fd9.png

Step 2: Browse To The Project File & Install Dependencies
cd {PATH TO PROJECT}

https://gyazo.com/b503e953ad50dadf4c7645a5bb8b92b4.png

Now let's install what we need..
npm install nodejs
npm install discord.js
npm install


Step 3: Adding The Bot Code, Open Visual Studio Code
Start off with creating 2 files: index.js, botconfig.json
  • package.json - add this code

https://gyazo.com/8503e148a0574c997f07a40d6b9bf99f.png

  • index.js - add this code

https://gyazo.com/66cd432bb69736a6e5e69da0b65c49e2.png

Step 4: Bug Testing, Let's See If It Works!
Unminimize the CMD window and type:
node index.js


Should start up no problem. If you need help feel free to ask, this is an easy tutorial on a quick bot.

Need hosting for your bot? Just send me a message.


Last edited by module ; edited 1 time in total

The following 5 users thanked module for this useful post:

0101010101010101 (11-01-2020), NightFyre (10-19-2020), Rob (10-11-2020), CriticaI (10-11-2020), spf (10-02-2020)
#2. Posted:
DPR
  • Vantage
Status: Offline
Joined: Mar 18, 201212Year Member
Posts: 1,061
Reputation Power: 2685
Status: Offline
Joined: Mar 18, 201212Year Member
Posts: 1,061
Reputation Power: 2685
Great tutorial!
#3. Posted:
module
  • Resident Elite
Status: Offline
Joined: Mar 13, 20168Year Member
Posts: 266
Reputation Power: 31
Status: Offline
Joined: Mar 13, 20168Year Member
Posts: 266
Reputation Power: 31
Vlog wrote Great tutorial!


Thank you, I hope people actually use it.
#4. Posted:
spf
  • Winter 2021
Status: Offline
Joined: Jan 09, 201410Year Member
Posts: 873
Reputation Power: 175
Status: Offline
Joined: Jan 09, 201410Year Member
Posts: 873
Reputation Power: 175
Thanks for this, been looking for a tutorial that isn't written in Python for a while now.
#5. Posted:
CriticaI
  • Shoutbox Hero
Status: Offline
Joined: Nov 05, 201311Year Member
Posts: 2,753
Reputation Power: 452
Status: Offline
Joined: Nov 05, 201311Year Member
Posts: 2,753
Reputation Power: 452
Thanks for the tutorial! I would love to see more of these!
#6. Posted:
Rob
  • Shoutbox Elite
Status: Offline
Joined: Jan 29, 201113Year Member
Posts: 1,599
Reputation Power: 23816
Status: Offline
Joined: Jan 29, 201113Year Member
Posts: 1,599
Reputation Power: 23816
Informative tutorial. +Rep
#7. Posted:
module
  • Resident Elite
Status: Offline
Joined: Mar 13, 20168Year Member
Posts: 266
Reputation Power: 31
Status: Offline
Joined: Mar 13, 20168Year Member
Posts: 266
Reputation Power: 31
Thank you guys for all of your support, if you have any questions or tutorial requests please feel free to post or send me a message.
#8. Posted:
module
  • Resident Elite
Status: Offline
Joined: Mar 13, 20168Year Member
Posts: 266
Reputation Power: 31
Status: Offline
Joined: Mar 13, 20168Year Member
Posts: 266
Reputation Power: 31
With discord v12, rich embed codes were changed, I will be updating the code in a couple minutes.
Users browsing this topic: None
Jump to:


RECENT POSTS

HOT TOPICS