Alexander Seto

An Adventure in Game Design

Posted on 11/29/2015

Recently in class we have been going over C++. I've decided to finally start making the text adventure game that I originally wanted to make 5 years ago.

When I first tried making a game years ago, the scope of the game grew rapidly, and before long, I realized I wouldn't be able to do it in the way that I had planned. I had hardcoded the story with while loops for each room in the game, and dozens of bools to keep track of certain conditions. This worked fine for the first portion that was fairly linear, but not when the game branched out. I can't quite remember how far I got, but I remember it didn't last long.

Now, five years later, I finally think I'm prepared for the challenge. Instead of hardcoding the story and the various game elements, I've decided to implement an engine independently of the story. The engine reads a file and creates the game world based on that file. This means that I can make changes to the story without having to reimplement code. As of right now, the engine has the ability to navigate the options menu, start new games and view old game saves (no loading quite yet). I still have to finalize the design for the game-world files, but I want to make sure I'm not missing any functionality before I continue.

Posted under: code

Clean URLs

Posted on 11/19/2015

I finally got around to adding clean URLs via .htaccess. Instead of canonical urls such as:

    http://alexanderseto.com/portfolio.php
    http://alexanderseto.com/blog.php?page=2
    http://alexanderseto.com/blog.php?post=2015-11-18-hello-world

Webpages are now served at:

    http://alexanderseto.com/portfolio
    http://alexanderseto.com/blog/2
    http://alexanderseto.com/blog/post/2015-11-18-hello-world

Posted under: code, website

Hello World!

Posted on 11/18/2015

I finally got around to updating my website to something a little more usable. I've gotten rid of the wordpress instance at /blog/ and instead opted to build everything myself to make things a little more consistent.

The first thing I did was separate my navbar and footer into header and footer php files so that I can update them from one place. I then changed some code so that all my pages use the same CSS file.

For the blog, I was tempted to use a pre-existing solution, but decided against it, instead, opting for a light-weight flat-file blog structure using PHP and a library called Parsedow. I'm using the PHP glob function to read files from a directory, then using Parsedown to parse them into html. To keep track of pages, I'm using array_slice.

Posted under: code, website

Test Post Please Ignore

Posted on 11/17/2015

This is a markdown file.

Header 1

Header 2

Header 3

Header 4

Header 5
Header 6
    Tilde code block
    regular code block

Posted under:

Copyright 2019 © Alexander Seto. All rights reserved.