Tuesday, May 25, 2010

Coding coding coding

I am building a turn-builder tool for a role-playing game called Midgard. Each turn has up to 30 actions. Each action has up to six values, and up to now a big problem has been players submitting turnsheets with tons of mistakes (values in the wrong fields, missing required values...). The turn-builder only shows you valid options for the choice you made in the first field, and then only valid options for what you chose in the second field, and so on, until you have enough valid stuff for the action to be ready to submit.

The second through sixth values for an action may need a text box, a number stepper, a picklist, a  combo box (that's a picklist where you can add something you don't find in the list), or a checkbox. That's a max of 3125 combinations of controls, and then sometimes the values are required and sometimes they are optional.

I need to say this from time to time to remind myself why I need to write so MANY lines of code. Thank you for listening.

Monday, May 17, 2010

Getting a useful view of a project

I am a big fan of mind mapping. I usually start working out what's going to be involved in a project in a mind-mapping tool like Mindomo. I have even tried to track a project (what is complete, who owns what needs to be done, how done is it) using a mind map...with pretty poor success. A mind map node doesn't know anything about the state of its children, except that they are there, so there was a lot of repetitive bookkeeping for me in updating how done things were.

I am working on a project right now for a great old turn-based game called Midgard. It's a sort of medieval-with-some-magic political-struggle game where you start out with a couple of friends and a couple hundred retainers and try to make something of yourself in a huge and often hostile world. You are asking, why play a game when I can get that at home for free, and it's a valid question. Which I can't really answer right now, but I will return to it in a future post.

Anyhow, one of the painful aspects of Midgard is entering your actions on the turn sheet in the correct syntax. You can use as many as 30 actions per turn, and each action can have as many as five arguments. "City - Warehouse - Load - [warehouse #] - [quantity] - [item]" and actions like it are very easy to set down in the wrong order.

So I am building the Midgard Turn Builder. Basically, what you choose as the first part of each action governs what the Turn Builder will let you choose or enter for all the other arguments. When this finally gets working, it should reduce blood pressure readings all across the player community, and probably cut the turn processing time dramatically.

I will post again about the Turn Builder as it develops (you are free to go visit now, but the turnsheet screen is only partially hooked up. Come back June 1), but right now I want to show you how I am keeping track of everything I have to do.

I started with a mind map, as is my wont. Here is what it looked like at an early stage:

All the little branches represented things I thought of and tried to organize by some sort of logical method. But how to track what was done, and what needed doing next?

I recently found Goalscape, and it is proving a huge help in tracking the project. Goalscape displays the project as circles within circles. The innermost circles are the general categories, and their 'children' are the tasks within those categories:
The parents know about the status of their children, so as you record progress on a child task, the parent task gets proportionately colored in.

See that orange little thing? I can zoom in on it and see all those little children in a readable way:


Looks like I have some work to do on the code that handles the action arguments!

There are features I am not using yet, because this is a one-person project; however, Goalscape lets you assign deadlines and task owners. It is a young tool, so I bet cool additions are coming soon.

If you have a tangled project, consider flattening it out with Goalscape.

Tuesday, March 16, 2010

Problematic penitence

My Lenten penance so far this year has been to listen to the spring training games of the Washington Nationals. I follow this team because they used to be the Montreal Expos, and I was living in Montreal when that franchise began playing, back at Jarry Park. I have hardly ever been in Washington, and have never seen a Nationals game live, but they are my team.

And this spring they have started off with 11 straight losses, following the tradition of the last two full seasons when they have lost more than 100 games each time.

Ah, but now, today, they played two split-squad games and won both of them. Will I have to root for single-payer health-care reform from now on?

Friday, March 5, 2010

Harsh realities

The less I pay attention to Canadian politics, the pleasanter my memories of it. We have been out of Canada for five years on this current stint (just got the notice saying we are being dropped from the voting lists because of prolonged absence), which has allowed me to pretend that Canadian politicians, base their fervent disagreements and maneuverings on high principles and a shared concern for the well-being of all citizens.
But I have been following events a little more closely over the last few months, and my rose-coloured lenses need to be set aside.
The Conservative government shut down Parliament around Christmas time to choke off an investigation into mishandling of prisoners in Afghanistan, and to try to defuse a confrontation where the government is refusing to provide documents which Parliament claims it has the right to see. The shut-down in itself was cheesy and petty, and underscored that the dispute over the documents seems to be because they would be embarrassing to the government, not because they would reveal matters damaging to national security.
And this week the government's budget proposals came out (Summary article by a former Conservative staffer: http://rabble.ca/blogs/bloggers/ericmang/2010/03/conservatism-and-economic-incompetence). More tax cuts for those who have already had tax cuts. Retrenchment on efforts to help people out of the disastrous recession. A more militant military. Much much less for the arts.
The government has the principles of its dogmatic base at heart, but not the needs of the generality of Candians. Why, they are almost acting American (Bush-era) in their arrogance and disdain.
I much preferred the rosier view I had built up. Wish I was in a position to do anything about the current situation.

Wednesday, February 17, 2010

Tribal knowledge

At my day job, I keep running into word-walls, where the evident meaning of the words is not what the text is trying to convey. So, we have an "application accelerator" that does not accelerate the application. Evidently, it accelerates the process of creating the application, and what happens after that is up to the developer. We have an "autogenerated" modal window that turns out not to be autogenerated, or not in the sense I would understand that term. I still have to tell it what I want in the window and how I want it to look.

Probably what I am running up against is the speed of development of our product. It had its cranky places in times past, and you had to have a large chunk of "tribal knowledge" in order to make it work at all. And now it is much more simple and straightforward for anyone who ever used the older versions. But I did not. I am only seven months here, so my baseline is what everyone else things of as this huge advance over the past. What they want to trumpet as wonderful improvements, I see normal or almost-normal software behavior.

This would be funny if it did result in my wasting so much time tracking down where my understanding does not match the expectations of the team with good tribal knowledge.

Saturday, February 6, 2010

Ugly face

Jack Layton is the leader of the Canadian New Democratic Party, has been for the past seven years. He is an energetic fighter for his party's position, and also a stylish leader who does a good job of eviscerating opponents' positions and actions without sticking knives into their guts.

Jack announced on Friday that he has prostate cancer, which is scary but likely treatable. His dad had prostate cancer almost 20 years ago and fought it successfully. I am a great Jack Layton fan, but even if I were not I would wish him the greatest success in this battle. As Gilles Duceppe, leader of the rival Bloc Quebecois, tweeted, "Cher Jack, ton dynamisme et ta détermination viendront à bout de cette épreuve. Bon courage."

I found remarkable, though the quality of comments left on Canadian news sites as the rumor mill churned before Mr Layton's press conference...and even after. People found the most hateful, irrelevant things to say about someone they probably have never met and who arguably thinks benevolently of them. I understand that people who don't get out much and can't keep friends tend to lurk and the world of comment-posting, but still I have clung to a romantic image that this would be Something Canadians Just Don't Do.

I am wrong, of course. Canadians are as trashy as are any other people, and ever have been. I remember now sitting as a poll observer for the NDP in a Halifax riding where the great Muriel Duckworth was our candidate, the first woman to run for a seat in the Nova Scotia legislature. Observing for one of the other parties was a college-aged troll who kept up a non-stop flow of disparaging commentary of all things that were not of his party. But he didn't really know all that much, so his commentary was mainly about how ugly or stupid or lame various prominent figures looked--his chief target was Stanley Knowles, MP, labor activist, and clergyman (who, even his friends would agree, could look a bit like a long-legged bird). I remember wondering at the time, "What planet does this kid think he is on? Why does he think what he's saying has merit?"

It didn't have merit, of course; but as these past decades have shown us, meritless speech poured through a megaphone can have great power. So I guess he was a harbinger of what we now experience.

Speedy healing, Jack!

Friday, February 5, 2010

Home on the prairie

I dashed home from work last night and went off to the nearest AMC theater complex to see a simulcast of Garrison Keillor's radio program, "A Prairie Home Companion". I thought I might be all alone in the theater, but the audience eventually got up to about 150 folks. Most of us were geezers, but not all.
Do you know this show? It has been broadcasting almost forever on Saturday nights on public radio: two hours blending inane skits, local acts, big-name stars, a classy house orchestra, and news from the imaginary town of Lake Wobegon, Minnesota.
The concession booth had no Powder Milk Biscuits or ketchup, two of the supposed sponsors for the show, but aside from that the evening was perfect. We laughed and applauded and held our breaths at the virtuoso music and sound effects. Elvis Costello was the big name of the night, but he had good company.

That was some fun. I hope they broadcast the radio show this way at regular intervals. I will never get to the Fitzgerald Theater in St. Paul, Minnesota; but this was almost as good.