Reincarnation

2019-07-15 - Reading time: 4 minutes

I don't have a link to it, but I remember reading about how some people essentially "reinvent" themselves multiple times over the course of their lives. They are constantly learning new things and switch careers to some other focus every decade or so, in an attempt to live a rich, varied life free of stagnation.

An interesting idea, if you can pull it off. After all, typically, people are married and have a family to take care of. And if not for a family, one's own finances need to be secure.

Now, I'm not planning on quitting my job any time soon, mind you (I love it quite a bit), but I think the basic idea could at least be applied to one's hobbies...

Since I was in high school in the 90s, I've always had a thick interest in game development. Skipping past the boring self-analysis, I came close to doing it professionally a couple times in the last decade, but otherwise it's mostly stayed a hobby. But it was one I actively participated in during my off hours... I could cite various reasons, but suffice it to say that despite my dreams of 'going pro', it never took off.

Other, recent events have soured the milk on game development even further. It was probably for the best, though. All it ever did was remind me of unfinished projects, and planning for a future that wasn't going to exist. Never mind the increasing number of horror stories from inside the industry, as people begin to feel safe about opening up about corporate abuse and general misery.

So, over the last couple months I've decided to pack up my game development hobby and put it into a little box in the closet. Sure, I'll still keep tabs on industry news and people's fun indie projects and stuff, but it's no longer a primary interest.

What will fill the void?

Well, over the last couple years I've been, off and on, attending the B-Sides information security conferences along the east coast. I always had fun, but felt a bit weird going to them. It wasn't my field. I felt like an outsider, even though it was stuff I could potentially apply to my day job. But as time went on, the wheels of further interest started turning...

Network security has always been a major weak point in my computer education. Compiler internals, hardware, software development? Sure, I love that stuff. But network administration? Server security? Subnet masks? OSI layers? I've had, more or less, only a scattered, surface level understanding. (No worries -- I had a good handle on what to do, and what not to do, when it comes to security when working on software projects, so no worries there at least ...mostly. I mean, as far as I know. Oh god, now I'm paranoid.)

So, I've been taking courses. I'm going all-in on educating myself about all of it. Taking part in CTF challenges. Pentesting my own internal network. Breaking into vulnerable virtual machines. (Already taught me a ton about WordPress security. Cough.) And I've been taking extensive notes as I go.

And you know what? I'm addicted. This is seriously fulfilling stuff. And my interest has only increased the further in I get. It's like an infinite box of puzzles that keeps my brain active.

So now I have a primary hobby that is not only good for me, good for helping others, but also helps my day job.

I don't want to say it's goodbye forever to game development, but it's going to be a long time, if ever, before that flame is reignited. And hey, maybe I'll write up some more educational stuff here and there to help others, like me, along the way. I'd be down for that. 😎


Pico-8: Lines Screensaver

2019-01-22 - Reading time: 2 minutes

Okay, so it's not really a screensaver in this instance, but it's the art from inside one. You recognize it. You've seen it before. But here it is... much lower res than usual. ;)

Source: https://gist.github.com/Fortyseven/a4e2d5d3105ed86e0916d162a1a4d466

pico-8 cartridge // http://www.pico-8.com
version 16
__lua__
-- lines (classic)
-- by fortyseven

SPACING = 4
SPEED = 1

function buildPolyVerts()
    local verts = {
        x=rnd(128),
        y=rnd(128),
        xvel= SPEED,
        yvel= SPEED
    };
    if (rnd(1) > 0.5)  verts.xvel = -verts.xvel
    if (rnd(1) > 0.5)  verts.yvel = -verts.yvel
    return verts;
end;

-------------------------------------------------------------
poly = {}

function poly:init(i, color)
    self.color = color
    self.verts = {}

    -- ensure we use the same seed for each poly object, so it will always
    -- create the same intial x/y/velocity directions

    for i = 1, 4 do
        verts = buildPolyVerts()
        add(self.verts,verts)
    end

    -- run the update a couple times to space them out

    for i = 1, i*SPACING do self:update() end
end

function poly:update()
    foreach(self.verts, function(vert)
        vert.x += vert.xvel
        if ((vert.x >= 128) or (vert.x <= 0)) vert.xvel = -vert.xvel
        vert.y += vert.yvel
        if ((vert.y >= 128) or (vert.y <= 0)) vert.yvel = -vert.yvel
    end)
end

function poly:draw()
    for i = 1, 3 do
        color(self.color);
        line(self.verts[i].x, self.verts[i].y, self.verts[i+1].x, self.verts[i+1].y)
    end
    line(self.verts[4].x, self.verts[4].y, self.verts[1].x, self.verts[1].y)
end

function poly:new(o)
    self.__index = self
    return setmetatable(o or {}, self)
end

-------------------------------------------------------------
polyCluster = {}

function polyCluster:init(col_array)
    self.objects = {}
    seed = flr(rnd(1000))

    -- generate three unique polys
    for i = 1, 3 do
        srand(seed)
        local o = poly:new()
        o:init(i, col_array[i])
        add(self.objects, o )
    end
end

function polyCluster:update()
    foreach(self.objects, function(obj)
        obj:update()
    end)
end

function polyCluster:draw()
    foreach(self.objects, function(obj)
        obj:draw()
    end)
end

function polyCluster:new(o)
    self.__index = self
    return setmetatable(o or {}, self)
end

-------------------------------------------------------------
clusters = {}

function _init()
    local c = polyCluster:new()
    c:init({2,8,14})
    add(clusters, c)

    c = polyCluster:new()
    c:init({1,6,12})
    add(clusters, c)

    c = polyCluster:new()
    c:init({13,6,7})
    add(clusters, c)
end

function _draw()
    foreach(clusters, function(c)
        c:update()
    end)
end

function _update()
    cls()
    foreach(clusters, function(c)
        c:draw()
    end)
end

Fantasy consoles?!

2019-01-05 - Reading time: ~1 minute

Been really enjoying playing with Pico-8 lately. If you're not familiar, it's essentially a so-called 'fantasy console' that you can code against. It has all kinds of restrictions as far as code size, memory, graphics, etc. But that's the point: coding within restraints. Old-school style before entire trucks full of gigabytes and gigahertz were dumped on our doorstep.

The consoles include code, music, and art editors inside the app, so you can do everything in one place. It's possible to edit these things externally, too, if that's your bag. Personally, I've been using VSCode along with an appropriate extension.

My first attempt was recreating the classic demo-scene fire effect, which has popped back into the mainstream consciousness thanks to this post.

As you can see, it runs pretty great in a web browser!

There's other 'fantasy consoles' besides Pico-8, including TIC-80 which has an Android port for coding on-the-go!

Not only is it a good exercise coding down to restrictions, it's very convenient to just pick up and go to sketch out gamedev ideas.

Give it a go!


Elsewhere...