How to code a Discord Bot step by step in JS

This guide will teach you step by step to make a Discord Bot that does some cool commands and stays online 24/7! This process is pretty easy for anyone to understand!

Before you start…

This guide sounds like a mouthful, but it’s really simple and allows anyone to create a bot! You don’t need to pay anything either since everything is totally free! You will also learn some JavaScript along the way! You will require:

  • A working Computer (This cannot be done on a mobile device)
  • A Verified Discord Account
  • Some basic JavaScript knowledge. (Take a look at some coding tutorials!)

If you have all of that, your all set! Let’s start by creating the bot!

Section I – Creating a Discord Bot

This first part is the easiest by far! First you must navigate to the discord website at https://discordapp.com/! Once your there, head to the developer portal by clicking Developers and then Developer Portal!

You’ll be brung to this Applications Page, click the new Application Button which should be in reach! After clicking it, put in a name! I’ll call this one Tutorial Bot for sake of the tutorial.

Once you’ve created it you’ll be brung to a whole new page! Note the app icon won’t actually show on the bot. Speaking of that, let’s create the bot! In the section on the left, click the Bot button! Now click the newly made “Add Bot” button! This’ll turn your application into a bot! You’ll see a lot of buttons!

You can see your bot already has a discord tag, at this point you can add an icon by clicking on that discord icon! Now that the bot is set up, keep this open as you will need two important things that you’ll need to invite the bot and to start it up in the code!

Section II – Invite the bot to a test server

Now that our bot is created, we can invite it! We’ll create a test server to test some stuff! Open discord in your browser or start up the discord app if you haven’t already, make a new server by clicking that plus button. If you don’t know how to get into the discord app in your browser just click the “Open” button on the discord website!

Now that you’ve made a new test server, it’s time to invite the bot! You’ll have to make a link yourself, heres a template:

https://discordapp.com/oauth2/authorize?client_id=CLIENT_ID&scope=bot&permissions=PERMISSIONS

Replace CLIENT_ID with the client id from your bot! Go back to “General Information” and click the copy button and paste that into the link. Then Replace PERMISSIONS with the permissions integer. You can find one back in the bot section and scroll down. I’d recommend checking Administrator so you can have access to all features, but if you want to just use some features then just click the ones you want. Now that your link is ready, press Enter!

Now just invite the bot like you would with any bot! Select the server and make it the server you just created or whatever server you plan to test in.

Click Authorize, do the Captcha, and then your bot has been added! Currently your bot is offline though, time to add some code!

Section III – Setup the coding enviorment

In this tutorial we will be using Glitch.com, it’s completely free and quite useful in creating bots! It also gives you 200MB to play around with data and there is friendly staff if you get stuck.

Head over to https://glitch.com/ and sign in! You have to use an existing account like Google, Facebook, Email or Github to sign in.

Click the New Project button, then you’ll want to click “hello-express” as we’ll be using the Node.js plugin. We can also add the packages we need later.

Now that you’ve created a project you should see something like this:

It looks like a lot, lets keep going.

There are a lot of unneeded files however, delete the client.js, style.css and index.html files as we do not need those. Then change the README to whatever you want. To delete a file, just click on it, then click the arrow and click delete.

Now in the “server.js” file, replace all the code with this:

const http = require('http');
const express = require('express');
const app = express();
var server = require('http').createServer(app);
app.get("/", (request, response) => {
  console.log(Date.now() + " Ping Received");
  response.sendStatus(200);
});
const listener = server.listen(process.env.PORT, function() {
  console.log('Your app is listening on port ' + listener.address().port);
});
setInterval(() => {
  http.get(`http://${process.env.PROJECT_DOMAIN}.glitch.me/`);
}, 280000);

It’s a little more efficient and sets up a port. We will have to install discord.js next. Go into package.json and click the Add Package button, search up discord.js and just click it. It will now install discord.js. I’d also open up Tools > Logs, so you can see whats going on. Now that discord.js is installed. We can start to add the code for this bot!

Section IV – Basic Bot Code

Now everything is installed. We can start by adding some bot code! Let’s start by putting in our secret token back in the developer portal. It’s in the bot section. Warning: Anyone who has this token has access to make your bot do different things! Don’t share it with anyone! Go into your .env file and replace the SECRET and MADEWITH code with TOKEN=

Then Copy the token from the developer portal and paste it right after the equal sign and no semicolons!

Go back into the server.js file add add these first few lines after all the current code.

const Discord = require('discord.js');
const client = new Discord.Client();

What this does is it gets the Discord library we installed a bit ago and creates a new client. Now we’ll need these two lines after the code you created:

client.on('message', message => {
  
});
client.on('ready', () => {
  
});

We have two client functions for when the client is on. One for when the bot sees a new message and the other for when the bot is ready. We’ll need one more line before we can do anything:

client.login(process.env.TOKEN);

The process.env.TOKEN is the token you put in the .env file a bit earlier. One cool thing about .env files is that no one can see inside it unless you have given them permission to edit your program! If you go back to the discord app in the server. The bot has been turned on! It does nothing at the moment but it’s better than nothing!

Let’s put a console.log in both functions

client.on('message', message => {
  console.log("\"" + message + "\" has been posted by " + message.author.id);
});
client.on('ready', () => {
  console.log(client.user.username + " is ready!");
});

So now every time someone posts a message, the bot will post it to logs and it will show the message and the creator. It will also post to logs when the bot is turned on! At this point your code might look something like this:

app.use(express.static('public'));
app.get('/', function(request, response) {
  response.sendFile(__dirname + '/views/index.html');
});
const listener = app.listen(process.env.PORT, function() {
  console.log('Your app is listening on port ' + listener.address().port);
});

const Discord = require('discord.js');
const client = new Discord.Client();

client.on('message', message => {
  console.log("\"" + message + "\" has been posted by " + message.author.username);
});
client.on('ready', () => {
  console.log(client.user.username + " is ready!");
});
client.login(process.env.TOKEN);

Try typing in some messages! Speaking of messages, let’s set up a basic command! How about a coin flipping command?

After the console.log line in the message function, let’s add an if statement to check for a prefix.

  var Message = message.toString();
  if(Message.startsWith("!")){
    var fullCmd = Message.slice(1);
    if(fullCmd.startsWith("flip")){
       coinFlipCommand(message);
    }
  }

First we check if the message starts with an !. If so it will create a new variable called fullCmd which is equal to message, without the first letter (Which in that case would be !). Then we check if the full command starts with "flip", and if so then we would call our flip function which doesn’t exist yet. So let’s create one!

Go before the message function but after the client variables and create a function called coinFlipCommand();

var coinFlipCommand = function(message){
    //command here
};

Then we’ll call the function back in that if statement

if(fullCmd.startsWith("flip")){
   coinFlipCommand(message);
}

You might have noticed that we have a parameter called message, this gets the message variable so we can send a message back in the function. To send a message back, go into the function and you would use:

message.channel.send();

But since it’s a coin flip command, we’ll need to decide if the coin lands on heads or tails.

  var coinside = Math.floor(Math.random()*2);
  if(coinside === 1){
    message.channel.send("Your coin landed on Tails!");
  }
  else{
    message.channel.send("Your coin landed on Heads!");
  }

Make sure those lines are in the function. If your project seems to have no errors. Go ahead and type in !flip! If the code was written correctly, the bot will either tell you Heads or Tails! If you look back in the function, Programming starts at 0, so that’s why we used 1 instead of 2 in our if statement! Let’s just set up one more thing and your basic discord bot is done!

Section V: Setting up the 24/7 uptime

Glitch projects will shut down if nothing is looking at it after 5 minutes, so we’ll need something free to ping the project so it stays up! Thankfully Uptimerobot exists! It’s useful, you can have up to 50 pingers without having to pay anything and Glitch suggests it themselves!

Head over to https://uptimerobot.com/ and create an account! Then log in with it and you’ll be brung to the dashboard! You’ll want to create something that’s called a Monitor. Click the “Add New Monitor” button! Click the Monitor Type dropdown and select “HTTP(s)”, put a nice name such as “Tutorial Bot Pinger”. For the url, go back to your Glitch project and click Show App, put it in a new window and then grab the URL when it’s loaded! Don’t worry about the error there, it’s just the HTML things that we deleted, and no one will actually see the page. It also won’t stop our bot unlike some errors which you may discover in the future.

Go back to the Uptimerobot on where your setting up your Monitor. Paste the URL on where the URL box is and leave the monitoring interval at 5 minutes. You’ll also want to check the email that you’ve attached so you can get emails if your Monitor is down. Don’t worry about the advanced settings. Click Done and wait just a minute to see if it works! Reload the page and if it says “Monitor Up”, then you’ve successfully set it up! Try closing the tab of your glitch project, wait a few minutes, play with it in discord, and see if it still works! The finished code is right here:

const http = require('http');
const express = require('express');
const app = express();
var server = require('http').createServer(app);
app.get("/", (request, response) => {
  console.log(Date.now() + " Ping Received");
  response.sendStatus(200);
});
const listener = server.listen(process.env.PORT, function() {
  console.log('Your app is listening on port ' + listener.address().port);
});
setInterval(() => {
  http.get(`http://${process.env.PROJECT_DOMAIN}.glitch.me/`);
}, 280000);

const Discord = require('discord.js');
const client = new Discord.Client();

var coinFlipCommand = function(message){
  var coinside = Math.floor(Math.random()*2);
  if(coinside === 1){
    message.channel.send("Your coin landed on Tails!");
  }
  else{
    message.channel.send("Your coin landed on Heads!");
  }
};

client.on('message', message => {
  console.log("\"" + message + "\" has been posted by " + message.author.username);
  var Message = message.toString();
  if(Message.startsWith("!")){
    var fullCmd = Message.slice(1);
    if(fullCmd.startsWith("flip")){
       coinFlipCommand(message);
    }
  }
});
client.on('ready', () => {
  console.log(client.user.username + " is ready!");
});
client.login(process.env.TOKEN);

Section VI: Grow your bot!

After your coin flip command, there is much more you can do! You could add more commands like a dice roll! Just copy and paste the if statement and make another function! You can look at the discord.js documentation!
In the future I’ll have more posts and video tutorials on how to make certain things for your bot, such as:

  • Make older commands work better
  • Turn your bot into a Music Bot
  • Make your bot store data
  • Bring your bot to Discord Bot List
  • Turn your bot into a leveling bot
  • Turn your bot into an RPG!

You can do many things yourself too! If you ever get stuck, Google is your best friend! You can even collab with others to make even better bots! Keep on coding and you’ll get better!

Thanks for checking out this tutorial! If you want you can check out my bot The Kepler Bot: The Kepler Bot | Discord Bots
Or Subscribe to my YouTube Channel: https://bit.ly/2KiMqZ5

That’s all for now!

The Adventures of Coding a Discord Bot

Me starting to write the basic code of my own mining discord bot!

Everyone uses Discord, right? No? Well, quite the majority do. So I’ve decided to turn my game into a Discord Bot! Creating a Discord Bot seemed like a good way to spread my coding influence, so I started creating one!

The Beginning

I wanted to start quickly and add a lot of stuff! I asked some people around Discord for tutorials and one pointed me towards Dapper Dino’s Bot Tutorials. I watched thru majority of them not understanding much, but my bot was set up and I could flip coins and roll dice.

That wasn’t enough so I followed a few more and added the music part to The Kepler Bot, then I wasn’t sure where to go from here. Until one day on my “Recreating Discord Miner into a Game” video, someone commented or DM’ed me, I can’t remember anymore. But they suggested that I turn my Miner Game back into a Discord Bot. Then I started to think…

The Completion

So I soon realized I was programming in Node.js, which was real similar to what I was used to programming in. Known as processingJS, which was linked to JavaScript, which is also what Node.js was also linked to, basically a lot of the stuff I knew could be used here too, which I thought was pretty neat. I soon figured my way thru Custom Emojis with some help from the mighty SpongeJr, who has also created a bot that acts like a role-play game!

I started using for loops, if statements, variables, math commands (well those were a little different but I still got used to them) and a lot more! Obviously rect(); or ellipse(); wouldn’t work as I was dealing with Discord.js and that was made completely of text and emojis, so I had to think a little creative if I wanted to create a mining scenario. Soon enough there were a lot of files in a lot of folders and it was hard to get around. But there was a working mining system, inventories, multiplayer mining, regeneration of land, and plenty more! But I soon realized that the basic code that Dapper Dino provided plus my code didn’t work too well, and things got easily confused like there were two help pages and classes everywhere which I currently don’t understand but I assume they are similar to functions (Which they probably are not :/), so I decided that it was time for a full rewrite of the entire code! Well I’d still have the data separate so there wouldn’t be a thousand lines to scroll thru if I wanted to add something new. The reason I wanted to rewrite the code is I was trying to access the Client (Known as bot in code) variable from the main file, but the other files were in a big folder. So it would be hard to access a file outside of the folder. I spent half an hour figuring it out but no luck.

The Rewrite

Thru the day I added the necessary basics like for when the bot turns on, the message function, and the commando classes. The rewrite was going great! Everything was working out! I created functions for each of the commands, everything would sync a lot better than before because they could access the same variables which saves a lot of code! I decided not to keep the music functions as I don’t see my bot as a music bot, more of a fun and helpful bot! All of the commands work fine and the command I got stuck on one point now will work much better!

And even today I’m still working on the rewrite and adding more commands! Like finishing up the top list command, adding support to check each others inventories, trading, bonuses and possibly moderation commands! I’ll put the link down here to the second and third videos when they are released, but for now, stay tuned!

Don’t forget to subscribe!: https://www.youtube.com/channel/UCocmE7xT6REn0p1kBEgmz2Q

Or follow my instagram!:
https://www.instagram.com/thekeplerteddy/

Thanks for reading! Or watching if you watched the videos!

New Years Plans!

Hello! Here are my plans for the start, middle and rest of the new year; 2019! I’ve got stuff for Khan Academy Community, YouTube and my apps! Starting with KACS!

Khan Academy Community:

First off, Monument Food II, lets get that out of the way! I will be working on it at least 15 minutes – 30 minutes every day if possible, I will also be doing 1 Hour Live streams every now and then where I code this game.

Next, I will be entering a lot of contests because I like contests, I won’t be too active on here, nor inactive, sorta in between for majority of the year, I will probably go hard cold inactive around summer as I’ll be spree coding my huge game in Unity.

That’s basically it, I’ll try and release some good games like MF II or Mesh Dance and some remakes though.

YouTube:

If you have followed my instagram, you probably have gotten a post on my January Youtube Schedule. And if you subscribed to my YouTube then you would’ve seen this video above all of this text! If not, shame on you, here are links for my Instagram and Youtube

Things I explained in my YouTube is that I won’t be doing too many ProcessingJS tutorials anymore but a variety of tutorials for different things! Also Minecraft and Gaming are returning to my channel so expect to see some Minecraft!

I also want to thank you for 300 views on my video, Discord Miner! That’s pretty awesome! Be sure to watch more of my videos and subscribe! That’s it for YouTube, onto the last big subject:

Apps and Unity:

Whew, here we go. First off, once I get this privacy policy working (which will appear on this website), City Dashz 1.2 will be out for iOS which currently is only for Android as of right now, a follow up bug-fixes update will arrive soon enough as City Dashz 1.2.1 and could be out Late January or earlier, which will fix glitches like not able to buy heads. Stick with bodies for now, it will still probably take you a while 😉

Soon enough in February or March, Tumbl3 will get some Music and a port to iOS! Very exciting! Also we have 30 downloads of City Dashz across all platforms! Tell your friends about the game! 😀

If you want more apps, you’re in luck, my next game: Impact, is another dodge game where you have to dodge balls, collect power-ups, buy characters, shaking terrors and more! It should be out around May! You can play the Khan version here: https://www.khanacademy.org/computer-programming/impact-103/6272456781529088

Another app I’ll be making which will arrive in September is Farmee! A simple game where you harvest crops, grow your farm, fish, sell, cook special food, sell that, cook even more special food, sell that. Yeah that’s basically it, just an awesome farm game!

I possibly might make one more app around December 2019 called Snowboarderz, which is a game where you snowboard, do challenges, championships and if I figure out, you just might be able to play with other players online :O

I might also be making a Online Multiplayer Shooter called Planetz.io (which I probably should reserve the domain, gulp! If someone takes it I’ll be quite mad :P) Where you collect resources to build weapons and fight other players with ship fights, lazer fights, galactical adventures and galactical disasters! With multiple modes, this game sure will be fun! This game will be Website based obviously, and will probably most likely make it in 2020, but you never know, I could finish it for Summer 2019! 😀

Lastly, this is the big game I’m working on, called Monument Food: Shards of Hope, which is an Adventure/RPG, you can do 2 player co-op, intense battles and awesome story! This will also be coming out of the end of the year, I will be sharing the progress of all stuff on my Instagram!

Whew, that’s a lot of stuff! Also, I might be building a PC! Hope you enjoyed this blog post and now you have the stuff to look forward too!

Recreating Mitcoin!

MITCOIN!

Ah, Mitcoin, what a peaceful way to make mon- AHHHH THE GRAPH IS GOING DOWN, NOO, I WANT IT TO GO UP! Oh, sorry! Mitcoin isn’t all peaceful when the graph doesn’t want to do what you want! Say, how about I recreate this fascinating bot! I’d recommend watching the video first!

So what is Mitcoin? Well its like Bitcoin, but if you don’t know what that is, its where you can buy a currency or trade it in for money, but there is the Mitcoin to money conversion, which is a graph that has its ups and downs!

We can create it pretty easily with the noise function, and making it change every second, an interesting thing is the graph doesn’t change if you restart it, it will change if you reload the page, I could’ve tried using randomSeed, I also could’ve added a save code! Maybe I’ll do that right now!

You can play the project right here!

What fun! Thanks for reading!

The Top List

Ah, the top list, the list which every single program is on, except that it is sorted by votes, which means 99.99% of them are at the bottom! Anyway, the top list has had many achievements, and a page is 30 programs each, the first page of the top list hasn’t changed, let’s observe.

We can see that the top three were created in 2013 then a lot of them were 2014 and 2015, there is only one 2016, 2012 and 2017 programs, there are no 2018 programs… One more thing I want to show you is the future of the top list! 😀

The Top list one year from now, unless another program gets banned!

What do you think? Obviously, the list couldn’t be more wrong, as even though the time-frame of the survey was 81 days, which the programs got this much in that time-frame:

Khanemon: 252
Doodle Jump: 242
Minecraft: 229
Mini Putt: 182
Escape Plan: 114
Duck Life: 102
Lava: 97
I saw Her Standing: 93
Mario: 88
Planes: 84
The Legend Of Zelda: 76
Terra Magma: 70
Infinity Hall: 67
Planetoid: 63
FIFA: 63
Cubix 2: 62
Cut The Rope: 60
Its a Big World: 58
Crate Ninja: 58
Doodle Dodge: 55
Transcolors: 55
MINI STIX: 53
iPhone: 48
sphere: 40
Flappy Bird: 33
Falling Pixel: 33
Zombie Invasion: 32
Redball: 31
HuskyCraft: 11
Flappy Bird (Kevin23): 11

As you can see, some programs have gotten more attention than the others, for example, three of the top five are on the top five themselves while the other two are programs that people really like because of the time spent on them, while on the bottom, Like simple programs or another version of a program that is placed higher on the list so this program doesn’t get as much recognition, as people are more likely to pick the first one. The top list has changed a lot, as programs go up and down, the farther down you go, the more difference there is over the days because the vote count of those ones are more similar

I think that is it! Be sure to subscribe to my blog and YouTube as I’ll start recreating some programs! 😀 

Recreating Discord Miner!

Hello! Welcome to Keplerteddy! And here is a post about my latest video, “Creating Discord Miner with code!” As you probably saw, it was mainly time lapse 😛 But there is more to it than you think! Get ready for some bonus content!

The start of mining, wooden pickaxes and according to code, graphics.

What I did add: Wooden, Stone, Iron, Gold, Diamond Pickaxes. Digging with different speeds. Levelling, Material Count.

What I added but never used: Material Graphics.

What I didn’t add: Redstone, Lapis, Emeralds, More Pickaxes, Bonuses, Enchantments, Long Term Saving, Trading, Money!

That’s all I’ve done on the game, I spent 1½ hours making this, and the graphics were made from 24 Hour Minecraft, saving me at least 15 minutes. Obviously, you probably want to try out the project for yourself! Just click this link to go to the Miner. You just hold to mine, pretty simple concept, let’s go thru the code to get a better understanding! Those 418 lines of code are just far too confusing!

Alright, the first few lines of code are mainly graphics, I store the information in string arrays:

{ //STONE
    d: [
        "001220",
        "011110",
        "020020",
        "002111",
        "111200",
        "001010",
    ],
    cs: [color(156, 156, 156),color(160),color(150),],
},

It checks the values in the array and will output the colour required, for example, 0 could be transparent, 1 could be yellow, 2 could be blue! you can add up to 10 values (0 – 9), You could put letters in too, but you’d need some conversion function. 


var Bs = function(block){
    strokeWeight(0.01);
    if(block === 0){
        // AIR
    }
    else{
        noStroke();
        for(var i = 0;i < 6;i ++){
            for(var j = 0;j < 6;j ++){
                var C = floor(BCs[block-1].d[i][j]);
                fill(BCs[block-1].cs[C]);
                rect(j*10, i*10, 10, 10);
            }
        }
    }
};

Then we have to store the images of the blocks. So instead of putting hundreds of rectangles every single frame,  we can store it in an image and it would just paste the image once every frame. It’s transparent too, Make sure you make a transparent background first, this is the best way to create images and then display them after:


var BGs = [];
var Block = function(){
    for(var i = 0;i < BCs.length+1;i ++){
        noStroke();
        background(0, 0, 0, 0);
        Bs(i);
        BGs.push(get(0, 0, 60, 60));
    }
    return{draw: function(x, y, w, r, block) {
        w = w || 60;
        pushMatrix();
        translate(x, y);
        rotate(r);
        image(BGs[block], -w/2, -w/2, w, w);
        popMatrix();
    }};
}();

Now we can easily call the blocks like this without any lag!

        Block.draw(30+i*60, 30+120+j*60, 60, 0, Bs[i][j].t+1);
This mining game wouldn’t work without the game-play and mining itself!

Now we want to focus on the gameplay! We want to focus on drawing the blocks first! This first piece of the for loop consists of increasing the alpha on the block so it shows, or technically it’s actually the other way around as we are just making the box that seems to be part of the background’s alpha decrease. We also display the box in between

/** DRAW THE BLOCKS **/
for(var i = 0;i < Bs.length;i ++){
    for(var j = 0;j < Bs[i].length;j ++){
        Bs[i][j].a +=1/180;
        Bs[i][j].a = constrain(Bs[i][j].a, 0, 1);
        Block.draw(30+i*60, 30+120+j*60, 60, 0, Bs[i][j].t+1);
        fill(64, 64, 64, 255-Bs[i][j].a*256);
        rect(i*60, 120+j*60, 60, 60);

The other bit is kind of confusing, first we check if the alpha is whole or otherwise we won’t let the cracks show nor will we let the player dig. If the alpha is 1, we will check another if statement if the broken amount is more or equal to one which then we will show the cracks.

We will have another if statement if the alpha conditions apply. It checks if the mouse is being pressed and if the cursor is in the boundaries of those positions. If not, then it will reset the break state, removing all progress.

Otherwise, the break speed will increase by the pickaxe level divided by 60. Which is the frames per second as well! it will check if the break amount is past one, which means it will do the very complex function of: Picking an amount of the material varying on the pickaxe; spawning particles with very well set instructions; Resetting the Alpha so the block completely disappears; Resetting the cracks and lastly, Changing the block to a different type. Whew, that’s a lot, 

        if(Bs[i][j].a === 1){
            if(floor(Bs[i][j].b*6) >= 1){Break.draw(i*60, 120+j*60, 60, 60, constrain(floor(Bs[i][j].b*6-1), 0, 5));}
            if(mouseIsPressed && mouseX > i*60 && mouseY > 120+j*60 && mouseX < 60+i*60 && mouseY < 60+120+j*60){
                Bs[i][j].b +=pickaxe/60;
                if(Bs[i][j].b >= 1){
                    var am = floor(random(1*pickaxe, 5*pickaxe));
                    for(var a = 0;a < am;a ++){
                        Ps.push({p:new P(60-15+i*60+random(-10, 10), 60-15+120+j*60+random(-10, 10), random(12, 30), "moveto", {gx: 300+Bs[i][j].t*50+15+random(-10, 10), gy: 35+15+random(-10, 10), r:0,rs:random(-5, 5), sp: 0, g:1+Bs[i][j].t})});
                    }
                    Bs[i][j].a = 0;
                    Bs[i][j].b = 0;
                    Bs[i][j].t = GetBlock(pickaxe);
                }
            }
            else{
                Bs[i][j].b = 0;
            }
        }
    }
}

Those are basically the main components, I won’t go thru and detail everything though! Because this would get too long and I’m already having so much fun playing this game! Speaking of Discord Miner, you can add the official (not mine) bot to your discord server using this shiny piece of text here! 

However the post isn’t over yet! I give you some challenges! Be sure to spin off my project and take a shot at these!

  • EASY: Add a delay between the appearance of the blocks!
  • MEDIUM: Add Emeralds to the game!
  • HARD: If you know code from the ups and downs, try creating an efficient bot that mines itself. (For example, make it look out for the ores like Diamond or Gold)

Good Luck! Hope you enjoyed this post! Be sure to leave a comment and a like on the post! 😀

What is it like to code 24-Hour Minecraft?

Now, you are probably wondering on 24 Hour Minecraft. What are you adding next, are you really coding 24 hours straight and will you even finish it in the end? All questions answered here.

Capturea.PNG

 

First off, What is being added next? Well, in the most recent second episode which you can watch here. I added AI, Crafting, Fixed Terrain, Bug Fixes, Tool Usage and more Survival:

I’d watch the video if you have time. In the Third Episode, from 12 to 18 hours, I hope to finish:

  • Mob Graphics, I only made the Sheep, Zombie and Skeleton Graphics. I still have to make the Player, Spider and Creeper Graphics.
  • Water, It will spread like in the actual Indev.
  • Farming, this is gonna be a hard one. I have to create planting, tilling, water checking, growth, and harvest! Uugh! XD
  • Background and Nighttime, The mobs are spawning in the day? No way! Better fix that with the Sun and Moon.
  • Menu and Settings, being able to cap off certain parts of the game to make it playable for all computers.
  • Death, the player must DIEEEEE! Because he doesn’t when he either, Gets hit to death, falls to death, or falls into the Void!
  • Lighting, this might not be too much of the challenge. Oh, have I forgotten about placing torches? Great.
  • Furnace, This will be a challenge.
  • Chest, An even greater challenge.

Probably after the third episode, if That gets all finished, then it might actually be playable. And I’ll add some extra things in the last episode. I’ll reveal when the blog post for the third episode comes out.

Captureb

Second, am I doing it for 24 hours straight? Definitely not! Might’ve broken some record though. But I would be very sick after and I wouldn’t be able to do much on here for an entire WEEK! So, No, I take breaks and get sleep. Like any programmer does. If it was 1, 2 or maybe even 3 hours. I could do a Jam perhaps.

Last, Will I even finish it in the end? Hopefully, I will, I cannot tell the future, but I at least think we will be able to add extra features like Alpha 1.2 or Beta 1.8 stuff in total. But that is if I do well.

Also, I will be doing a modding contest, where you, yes you! Get to make a mod for the game, and top three mods win!

Thanks for Reading (And Watching),

Ted.

P.S: I didn’t forget about Monument Food II, I’m still slowly working on it.

P.S.S: I’m also learning more Unity to make my next two apps, Ninja Bus and T/-d5 |E, whoops glitched out! (It is secret!) Also, Tumbl3 will be out with an update and for apple soon as well! Bye!