Code in my life: A chronicle part 3

This post is a continuation of part 2

After my computer broke, I was devastated. But the devastation did not last that long. In 2014, for my 10th birthday, I received a small Android tablet as part of a bundle deal my parents got. Unlike my previous computer, this one came with a SIM card and a small monthly data allowance.

With that access, I almost immediately got my parents to purchase and install the original Minecraft Pocket Edition for me.

Initially I was content with just playing it, but soon my friends started talking about “mods”. While they played computer minecraft, I wanted in on the action. I soon discovered Block Launcher, and MCPE Universe, and I played with mods for the first time.

I was not content with just that, though, and soon curiosity took over. Realizing that the files I downloaded were .zip files I could extract was my catalyst.

Soon I was decompressing every mod I could find, trying to make sense of the code, and Frankensteining it together to make my own mods.

My first mod took months to create, but I was incredibly proud of it. The idea was to create a mod that made TNT more powerful, but I only knew how to make blocks that did nothing. It was a simple mod, adding a new block that looks exactly like TNT, but is not. I thought it would be the perfect prank, placing TNT in front of your friend, lighting it and nothing happens. In late 2014, I posted it on MCPE Universe with a screenshot of myself holding flint and steel next to a burning TNT block.

Soon thereafter, someone reached out. Another young coder asked in the comment section of my TNT mod if I’d be interested in working together.

A more than a decade old interaction between a young me and another young coder

What I find fascinating is that our security mechanism was that he would email me the name of my mod, “so I know it’s him.” Someone could just as easily impersonate him reading the exchange… If only I knew about Diffie-Hellman Key exchange back then!

We started communicating via email, and started making mods together. The pinnacle of our modding career had us making a mod called CrAZy MoD. Here is the full original code, preserved as-is in its entirety for your enjoyment!

(I have changed the name of the other person to Wolf42 to preserve their privacy, the rest of the code remains as-is.)

//Mod By Wolf42 and Louis999
//Do Not Distribute Without Wolf42's and Louis999's Permistion
//Have Fun and be Crazy!

/*Mod History:
V1-The "megga", "lol", and "dumie" blocks were added by Louis999!

V2-Louis999 added Wolf42 to the mod helper list and they became friends!

Also Wolf42 added "The Stick Of Truth" item and the Beggining Chat when you enter a world, also he added the commands!

V3-Louis999 added the "Cow" command!
   Also Wolf42 Did a full mod Rewrite! and added a load more commands!*/
   
//Variables
var PX = Player.getX();
var PY = Player.getY();
var PZ = Player.getZ();
   
//newLevel
function newLevel(){
clientMessage("Welcome Its Time to be CrAzY!");
clientMessage("Type /help for help!");
clientMessage("or Type /creator for The Crazy Mod Creators Information!");
}
   
//Blocks
//megga
Block.defineBlock(252, "megga ",[["gold_block", 0], ["gold_block", 0], ["iron_block", 0], ["iron_block", 0], ["iron_block", 0], ["iron_block", 0]]);
Block.setDestroyTime(252, 1.0);
Item.addCraftRecipe(252, 1, 0, [1, 1, 1,  1, 1, 1, 1, 1, 46]);

//lol
Block.defineBlock(254,  "lol",[["cauldron_inner", 0], ["piston_inner", 0], ["mob_spawner", 0], ["piston_top_normal", 0], ["destroy", 9], ["cauldron_top", 0]]);
Block.setDestroyTime(254, 1.0);
Item.addCraftRecipe(254, 1, 0, [1, 1, 1,  1, 1, 1, 1, 1, 1]);

//dumie
Block.defineBlock(255, "dummie",[["diamond_block", 0], ["mob_spawner", 0], ["diamond_block", 0], ["piston_top_sticky", 0], ["tnt", 0], ["destroy", 0]]);
Block.setDestroyTime(255, 1.0);
Item.addCraftRecipe(255, 1, 0 , [1, 1, 1, 1, 1, 1, 1, 1, 1]);

//Items
//The Stick Of Truth
ModPE.setItem(511,"blaze_rod",0,"The Stick Of Truth");
ModPE.setFoodItem(510,"blaze_powder",0,-20,"Pizza");

//Comands
function procCmd(command)
{
var cmd = command.split(" ");
if (cmd[0] == "help")
{
clientMessage("Item IDs 500");
clientMessage("Block IDs 252, 254, and 255");
clientMessage("type /lol for more help");
clientMessage("or type /cow for page 2!");
}
if (cmd[0] == "lol")
{
Player.setHealth(0);
clientMessage("LOL!");
clientMessage("You Should of Got the Hint With the word lol");
}
if (cmd[0] == "troll")
{
Player.addItemInventory(510, 1);
clientMessage("TROLL!");
Player.setHealth(10);
}
if (cmd[0] == "info")
{
Player.setHealth(1);
clientMessage("WE LIKE TROLLING!");
}
if (cmd[0] == "cow")
{
clientMessage("Type /troll for A Great big Troll!");
clientMessage("Type /info for info about this mod!");
}
if (cmd[0] == "creator")
{
clientMessage("Type /cw23 to learn about Wolf42");
clientMessage("Type /l999 to learn about Louis999"); 
}
if (cmd[0] == "cw23")
{
clientMessage("Wolf42 is a YouTuber and a modder, as you see here.");
clientMessage("He Also is the one who wrote what your reading right here, lol");
}
if (cmd[0] == "l999")
{
clientMessage("Louis999 is a basic modder and mod creator, he thought of this mod and created it!");
}
//Wont Work Properly
/*else{
clientMessage("That Command Isnt Real D:");
}*/
}

The humor of a 10-year-old me captured in full glory! What I find fascinating is the copyright notice at the top and the chronicle of our modding history together. I loved how I called myself a “basic” modder. Another interesting detail is that we clearly wanted a fallback if commands fell through, but we did not know how else and if else worked.

A few other funny things:

  • Typing /lol kills you
  • /info sets your health to 0
  • Blocks with basically random faces
  • Eating the pizza item would subtract 20 from your hunger, meaning it would effectively set your hunger to 0. Looking at the texture, I guess that makes sense!
The pizza item texture, badly drawn pixel art.

But, as with all good things, we both moved on quite quickly. The tablet era was short, chaotic, and full of half-understood JavaScript. But when I got my dad’s old work laptop in early 2015, things changed. That was when I really started getting into programming…

This post will continue in part 4