I strung together a lot of PHP this summer.
This one kinda got away from me.
This little bit of random code I wrote over the last few weeks started out as a proof-of-concept thing and has snowballed into a weird little web application that, while pretty much useless, is interesting enough that I thought I would share for my more geekily inclined readers.
I’ve been thinking about procedurally generated content lately.
Essentially, this is content that is created on-the-fly by the computer based on calculations and randomizations.
InfiniteRooms started out as a game add-on for that other web project I have been working on, but when that didn’t pan out I reskinned it and went a slightly different direction. Waaaaaay far in a different direction. But you may be interested to click around and explore it.
The site is an endless maze of rooms that is generated as the user explores it. The rooms are all unique. The stuff that materializes in rooms is all unique. Everything is an object in the system. The world it creates is persistent, so any changes made by visitors — moving stuff around, writing notes — stays around forever in the rooms for anyone else to find, or until someone else changes it. But as it get’s explored, it grows. Right now there are about 500 rooms and about 2000 objects, but that could expand, theoretically, to millions.
And for now that’s about it… useless, but cool (with a few quirks and bugs, I know.) But it seems like it could be the foundation for something even more interesting, and maybe even a little less useless… if I feel like adding to it. Stay tuned.
June 30 – Something You Want To Share
aka. Post 30 of Those 30 Posts in June Blog-Every-Day Posts
I’ve been building to this all month because I’ve been working on and thinking about and scratching away at it all month with the intention of posting about it on the last day of the month. So, without further adieu…
My daughter, age not-quite-nine, is interested in current events.
If you’ve been reading along you may have noticed a theme in my posts: I’ve been writing about the news itself, wondering aloud why we even bother with following the news, thinking about kids and how they read or listen to the news, pondering ideas for dealing with complex stories and young minds, and considering unique ways of engaging a young, distractable audience.
So this is my project: thinkdrop.ca …and it’s just barely getting started.
I have a laundry list of ideas of where I want to take this thing, and I’m just starting to check off the first few items.
Thinkdrop (though Claire suggested I call it “KidzNewz” specifically spelled with multiple Zs) is a news “explainer.” At least that’s how I’ve described it on the site. It’s not “for kids” or any specific age group or target group: I’m simply writing it so that Claire could understand the stories and learn more about current events.
Simple language (though that is easier to say than to actually write) and short “drops” of information.
So far, I’ve created this all from scratch: I’m building my own content management software in PHP & SQL with a web application approach. I’ve built a content model. I’ve designed a brand with logos and a style approach. I’ve written about a half dozen articles. I’ve created a secondary support/supplementary content model. I’ve recruited a willing and able live-in beta-tester (who works for room & board.) And I’ve started (lightly) promoting it on social media… to the twitter equivalent of a few interested glances and words of encouragement.
I’m not an expert, but I’ve got about four or five years of “simplifying” it for my kid experience.
I have some lofty add-on goals, too. I’m hoping to publish at least 3 articles per week (for now). I have a development plan with version updates & enhancements (and some important deficiency filling) mapped out for at least another two sub-version updates. And I’m working on a submission/editorial model (probably for around version 0.5) for if this thing starts to grow wings and (big, BIG IF) I can find someone(s) else who might be interested in playing along.
Then, as I alluded to above, this is just the core of a much bigger idea that, as much as I’d like to share it with you it’s… y’know… well, we’ll call that bit proprietary IP at the moment. Company secrets. A plan yet to be unveiled… because I don’t want some random reader to pinch it and wander off to build it themselves.
With that, I conclude this crazy month of blogging and step into something probably crazier. From one idea to the next…
June 27 – Something You Want To Win
aka. Post 27 of Those 30 Posts in June Blog-Every-Day Posts
Ok, so strictly speaking it’s not a competition or anything that I can actually “win” per se in the proper, strict, absolute definition of the word “win.”
But in the sense that “winning” is an attitude and an objective, I think it counts… at least for today’s topic.
Now, I’m pretty sure to many of you this is going to be very dry and very boring. It’s the nerd aspect of my life, geekiness to the infinite degree poking out from the corners of my hobbies and making itself known. I’ve been thinking about something, and thinking about that thing has led to me to start writing about that thing, and writing has led me to working on it as an actual thing, and as these types of things are wont to do, working on it has escalated into an actual something that I’m actually putting effort into.
But I’m not going to tell you about it quite yet.
I’ve been coding, in fact.
I was pondering this idea that been bobbling around in my head for about six months, brewing and stewing, and then the other day I started poking at that mess of stewy idea-ness and there it was, an actual project. So I wrote a bit. Tweaked a bit. Deleted the whole thing. Twice. Then started over and…
Well, I’ve been coding.
I started simply. A little chunk of a database turned into a few files and that turned into a lightweight and basic content management toy and that has blossomed into the alpha version of a website. It’s php and mysql and a few little picture. And when I say that I want to “win” what I really mean is that I’m taking the development seriously, making versions and a task log and tracking bugs and tweaks and improvements. I have a spreadsheet and everything.
I’m not going to tell you about it. Not yet. Soon. But not yet.
But I’ve been coding, nurturing the dribs and drabs of code into something awesome, and the first few pokes at showing it, sharing it, giving it some air have been very positive. So you’ll see it… soon. Really.
Oddly enough, writing code… which I rarely find time for anymore.
A “Hackable Me” post is a few words on incremental personal self-improvement: a personal hack to better myself. I’m actually very skeptical when it comes to the kind of DIY, fixer-upper, read-this-book-to-change-your-life sort of self-improvement one normally thinks about. On the other hand I tend to consider that (a) publicly scrutinized goals and (b) introspective evaluation of those goals through words tends to lead to making me a better person. This is just a thing to do with that.
A couple years ago when I started this whole idea of “Hackable Me” (and yes, I still track a lot of things with regard to this little self-improvement initiative) I had the idea of automating a key component of that system, specifically the public accountability side.
See, in the spirit of the project, the whole point of tracking and gamifying your personal effort towards a goal is (a) to quantify that effort to make it easier for your brain to comprehend your success (or failure) in moving towards that goal, (b) to link that effort to real-world results, and (c) to add a level of public accountability so that to successes (and failures) can be a motivating factor to always trying to improve.
Most people balk at the public accountability part. But, for better or worse, you’ve probably already figured out that I’m not most people.
So when I started using this little system (admittedly, off and on over the past two years) the part about public accountability simply meant that I would keep track in a spreadsheet and then occasionally report my results. I’ve tried to keep my running tallies up-to-date, but the rest of it… that’s a lot of little numbers to always be updating.
But over the past few weeks (and after a couple long evenings of sitting in front of the television watching the Olympics and writing PHP scripts) I’ve finally got a version one (beta) of my Hackable Me Console which allows (a) simplified tracking system for a number of the key data points I’ve been recording, (b) a mobile-friendly (at least for my phones) website for inputting my data on-the-go and wherever, and (c) a graphical output for both the app-site and which I can embed in the side-bar of this blog.
You can explore — and as always I continue to tweak this system — but the simple tool lets me track points-based positive efforts around four factors: food (red), fitness (blue), mental (yellow) and lifestyle (green) and displays a graph of the same for the day of the year (###) and the total points for that day too.
And, with almost everything I make, there is no such thing as a finished product: so (it that’s the sort of thing that interests you) watch for improvements, additions, and as time goes on. And remember to yell at me if you start seeing too many zeros on my little graph!
8: I’ve been experimenting, lately. Truth be told, I’ve been going through something of a phase of general self-refinement. You know how it goes: things are changing and it’s time to pick sides on matters of eclectic preferences moral, creative, and substantive. Really, the truth be told, I’ve got far too many hobbies, and at thirty it’s become obvious that I’m a jack of many, master of none. This includes such formal realizations as: (a) extra cash should go to photography equipment and like creative materials, (b) writing and fictitious workings should be more handily focused on genre and goals than abstractions, and (c) remedies in the category of media interests should be matured towards new, yet worthwhile, prospects.
Funky Pig: Obviously… No really. I have no idea where you are going with this.
8: It’s a deeper look into the nuances of the eclectic hobby-set. I’m far too jittery. One day I’m coding pointless php toys, the next I’m painting clay, the next I’m cooking, the next I’m snapping photos, and then I’m speculating on business models for life-changing projects. It’s all quite…
Funky Pig: …random?
8: …lacking focus. It’s not about retreating. It’s about prioritizing. Mastering something coincides with a significant investment of resources: time, money, or energy. None are unlimited. All are becoming significantly more rare, in fact.
Funky Pig: So, where to start? Are you giving up the uncountable hobbies? Are you retreating?
8: Nay. Refocusing. Picking a genre. Immersing.
Funky Pig: You are not making much sense. Even to me — and I’m your subconscious. So… it’s almost as if you are completely confusing yourself here.
8: These things are abstract for a reason. Ah, well. It is confusing isn’t it? Alright. Let’s take a step back and try again.
Funky Pig: Okay. Go!
8: I’ve been experimenting, lately. Truth be told, I’ve been going through something of a phase of general self-refinement.
Funky Pig: You said that already.
8: Right. But that self-refinement is not so much a retreat from any preferences moral, creative, and substantive but rather a targeted approach to those preferences. For example, I don’t simply want to be a “creative” person. I want to be creative towards a goal: such as I am not simply a “writer” or a “photographer.”
Funky Pig: What are you then?
8: I am within the construct of a genre. I am a “writer of _________” or a “_________ photographer.” Fill in the blank. Instead of just being a guy who snaps photos or wastes time trickling words out on the page, I specialize. I will be the come-to guy on _________, whatever __________ happens to be.
Funky Pig: You really want to limit yourself so much?
8: Is it really limiting? The people who stand out in society are those who have excelled in a targeted goal. Tinkers of all trades, they dabble. Masters excel.
Funky Pig: And your focus? This had better be good.
8: I know what it is. Really. It was an epiphany moment, and one that is broad and interesting enough to explore for a very long time. That’s enough for now. We’ll get into it more later, but I just had to put it out there. The blank has been filled, and it’s probably not something you’d think.
Funky Pig: My breath is baited. No, really. Yeah, uh…
I found this neat little PHP script to play Risk in your browser. Basically you make an account, give it your email, and when enough players sign-up the game starts. You get an email when it’s your turn, and as long as you take it within the time limit (2 or three days, maybe more or less depending on how it’s set up) then you get to play. I installed it a couple days ago, and if anyone wants to open an account and try it out: http://www.8r4d.com/games/risk/. Let me know if you encounter any problems by leaving a comment here.
I was motivated by a series of influential factors, for which I am not entirely willing to divulge for fear of personal ridicule and scorn, to put some code to file and write a few lines of PHP for general dissemination to the public. That is, a somewhat professional requirement opted me towards an ultimatum of confrontation versus the spirit of just-do-it-yer’self-ness. The results have been a chain reaction of mild amusement — and perhaps even a compulsion to see things further along.
Those who know me, also know that I’m anything but a programmer. I dabble, yes. I speak software as well as your average Canadian might fumble through FranÃƒÂ§ais on a vacation to Quebec. That is, I can survive, get by, eat, sleep, and get a taxi to the airport, but don’t take me to a Trois-RiviÃƒÂ¨res poutine shop in my swimming trunks and ask me to explain myself.
Yet, while some have quipped at my lack of posts lately, I’ve been busy on some random coding. Last week about this time I quietly released a beta version of a plug-in for WordPress, a few files worth of code appropriately engineered to amalgamate with the software that runs this blog and bless it with the burden of new features. The story leading up to that moment is a long and dull one, reeked with googles of fruitless results and sketchy abstraction. But last week I unleashed a few lines of code of my own labours, enamoured with the morally-grey function of installing survey functionality into the WordPress system. It worked. For me, it worked. It fulfilled it’s purpose, and it was free to the world now.
And the odd part is… I didn’t even install it HERE. It’s for another project entirely.
I sighed a relief, I ate, I slept. A day passed, and loaded my release site to check the stats. And this, my dear readers, is where I understood the clichÃƒÂ© of youth: “If you build it, they will come.” So what to do next, I ask. Where do we go from here?
I realized (after the fact) that this was a recovery weekend. No travel. No visitors. No expectations. We spent some quality time with Sparkle. A few hours (and dollars) were spent at West Edmonton Mall where the hoards had reduced to a tolerable level post-holidays. We took the tree down, sad as it was, tossing it (literally) to the curb, and putting the vacuum to good work. And watched a couple odd movies, neither of which were bad, but not worth deeper analysis either.
Geeks as we are, Karin and I implemented the “alpha test” of our new meal planning software this weekend. We decided, for both convenience and monetary reasons, that we needed to spend more time planning meals in advance. A scheme to buy an extra calendar turned into a scheme to build a spreadsheet with codes which turned into a bigger scheme to build a database which (this weekend) turned into a grand scheme to build a piece of open source software using PHP and MySQL. I coded a handful of wierdly cool functions to do neat things like organize recipes, generate shopping lists, and do cost analysis of grocery spending. Ultimately, what started out as a bit of a nerdy project has turned into an ÃƒÂ¼berg33k project that (quite frankly) I should be (socially) ashamed to write about. I’ll keep the progress up to date as we move forward (slowly now) that we have a semi-functioning alpha-product.
Sparkle found the warm spots at our feet during all of this, though I don’t think she is quite aware of the adventure that awaits her over the next few days. I’m still a little chaotic in my own brain about the whole thing. Arg.
I’ve been pondering games.
I’m working on a mini-persistent game program, building it in PHP and MySQL to add some level of interaction here. There is going to be a finite-size game board with different levels of concept interaction. I’ve been drawing inspiration from a variety of sources, including but not limited to:
- Settlers of Catan
- Trade Wars
The concept is linked around the MOBIOS story-threads that I’ve been working on, and temporarily plugged-in here.
If nothing else, it gives me a small project to work on.
And, if that doesn’t interest you at all, you can always look at the 119 Saskatoon wedding photos that I uploaded the other day.
Coding innumerable lines of PHP last night forced my fuzzing eyes to veto the monitor for nearly an hour. Muddy bits occupied the gaps in my soles, but so what? Camera and I caught the next flight of stairs to street-level and went for a walk around the neighborhood. Eight o’clock was just hanging there in the sky, dwindling into the dusk. Camera was shy at first. But the plentitude of buggies tucked into the gaps and temporarily forgotten brought his lens to bear. We snapped four new subjects, and then later acquired a copy of the new mag Dose from a geometric box on Jasper.