Filing Away Another Post

Computers.

It’s the 21st century, computers are all around us, and explaining them can yield to some pretty interesting blog content.

If you have used a computer you’ve used or at the very least heard of a file, and you have probably seen many different file extensions (.png, .wav, .docx, .txt).

“What makes them different?” You might ask.

Formats.

To a computer a file looks exactly like any other file. Strings of binary, rows upon rows of 0’s and 1’s. A computer has no notion of a, b, c, unless we tell them something like 001 is a 010 is b and 100 is c. So that’s what we do. And to make it more readable we turn 8 bits (each digit in binary) into a more compressed byte (which is 2 digits in hex). This is turning 10001010 (base-2) into 8a (base-16).

This means that different files are just different ways of reading those bytes. Some files have strict formatting rules and some have no rules at all.

There are essentially two different kinds of files, even though all files are really just bytes. Human-readable and binary. Binary files are files that aren’t really intended on being read by humans, while human-readable is exactly what it sounds like.

.txt files are human-readable, if you open one up and readily convert the bytes to characters without following any formatting rules then you’ll get a file that you should be able to read.

.csv files are also human-readable but have a common formatting they have commas separating all of the variables. These are common for spreadsheets.

stuff,stuff,stuff
a,b,c
1,2,3

On the opposite end, things like .docx, the document used to hold your Microsoft Word document, is binary. It sounds confusing, but .docx is capable of holding pictures and formatting and colors and so many things that a conventional .txt couldn’t hold.

Another binary file could be something like .png which can display cool images given the proper program to read it, but also looks like this when you open it in a hex editor.Screen Shot 2018-03-26 at 3.17.23 PM.png

The right side shows what the byte values on the left look like as character, and is what it will look like if you try to open a .png in a text editor (like notepad). If you didn’t have a program to interpret it (like paint) you wouldn’t be able to get an image.

A couple of thing are worth noting here though. Notice “IHDR” on the first line?Screen Shot 2018-03-26 at 3.17.23 PM.png

That indicates to a .png reader that it is the first chunk of the .png. It has to be there and all the future data is interpreted based off of that chunk.

On the flip-side “IEND” indicates the last chunk of the .png. This lets the .png reader know to stop reading the file, since it won’t get anymore information about the image.

Screen Shot 2018-03-26 at 3.24.34 PM.png

This means that you could shove a ton of data at the end of a .png file and it won’t be read. For example: The entire Bee Movie Script.

LOL_BEE_MOVIE_SCRIPT.png

While retaining a completely normal .png image of Barry from the Bee Movie, you can actually put the entire Bee Movie Script by Script-o-rama.com on the end of it. That said, if you download that image right now it won’t have it on there, because the image reader for WordPress actually will chop it all off after only reading what is needed for the image.

If you did decide to open up a text editor and try it yourself, it would look something like this, and the image would look exactly the same, when you opened it up.

Screen Shot 2018-03-26 at 3.28.52 PM.png

Speedgaming and Far Cry

Starting about a year ago I found a Twitch streamer named BounceyBoy. I wasn’t big into watching livestreams or watching speedrunners until I saw him play Super Mario Sunshine. The movement of that game was beyond anything I ever saw in a videogame, and after a little bit of practice I realized it was completely possible to do some of the tricks.

It was the most fun I’ve had in a while playing Super Mario Sunshine jumping around like a speedrunner. I never would be able to get good enough to speedrun a game like that but I figured it would still be fun to find a game to speedrun.

A little while later I thought of Far Cry, it’s a fun game that I even enjoy playing hours upon hours. So I looked at Far Cry 2, only a couple of speedruns are listed, but most of it is just driving, which is my biggest gripe about that game. If I’m spending 3 hours just driving then I’m not going to have that much fun.

So I thought of Far Cry 3, looked up the speedrun times and it clocks at like 4 hours, I think I might try it, but I’m still not sure.

Far Cry 4 is a little bit of the same as 3, about 4 hours of probably just driving around.

So I did what any fame hungry speedrunner would do. I made up my own category.

The most fun part about Far Cry 4 is the arena. The rest of Far Cry is just the arena with more driving in between and more fetch quests.

The arena has 4 different game types but the most notable one is the weapon challenges.

There are 39 weapon challenges, one for each gun in the game. Each challenge consists of 5 waves of enemies. It is one of the most fun things to do in the game since it only consists of the satisfying combat of Far Cry 4.

And so I decided to make that my speedrun, completing all 39 weapon challenges. And I have to say it was a blast, my first run was a solid 3 hours and 22 minutes of action. And then I realized I missed one of the challenges. My next run was a true 39 weapon run, I was also able to shave off 6 minutes. That run is right here.

I plan on doing this run until I get a run that I have no deaths on and around 4 minutes on every challenge, which would be a 2 and a half hour run.

So with that, I’ll end this blog post saying that I am now in fact a world record holder (until somebody more competent tries the run).