Labor day activities
Posted on September 7th, 2010
Last night I went to bed idly thinking about the current project. Everything was in place and I was starting to get comfy under the covers when something clicked.

Back in mid-August I slammed hard into a major problem with Window's sound system. I'd made a little program that generates a sound file based on a string of numbers entered by the user. Basically it makes 8-bit sound effects. The problem was that the program was unable to play the sound once it was generated; some other program (Windows Media Player, soundrec32, FooBar2000 etc) had to play it. For some reason the code to play a sound file wasn't working. But here's the odd part: the same compiled code worked in Windows XP, but not in Windows 7. I tried several different approaches (including different languages) and it just wouldn't play the sound in 7.

This ugly fact came back to me last night. If I can't get sounds to play in Windows 7, the current project just got gutted. Naturally this meant I had to get up and troubleshoot it or I wouldn't be able to sleep.

So troubleshoot it I did. I didn't have a generated sound file ready, so I just snatched one of the sound effects from Windows XP's media folder, figuring one sound file is as good as another. I wrote the program and tested it: the sound played fine in both XP and 7! Note that the code had not changed: just the file being played.

I rummaged around and found the sound generation program, then ran it quickly. I then tried to have the new program play it, and again it worked only in XP. Thus it turned out that the problem wasn't Windows; it was the sound generating program. Which makes more sense, as 9 times out of 10 when something goes wrong with a program you've coded you've botched something.

Assured that the problem was simply a buggy generator and not the code that actually plays the sounds, I went back to bed.

To be woken up with a jolt this morning by a black cat that decided to MEOW in my nose.

Shortly thereafter I accompanied mom to our friend's home where we spent the morning and part of the afternoon looking at pictures and visiting. Two of her relatives arrived at the same time we did, and so all of us sat and chatted. They'd brought their puppy with them, and like any puppy it was full of energy and wiggling about -- then abruptly fell asleep like a switch had been thrown.

Probably the most juicy bit of news from there was that during the previous night there had been some unruly people visiting another apartment in the building. This resulted in a group of people buzzing everyone in the place in an attempt to get in without a key (or obviously, permission) and evidently fisticuffs or some other random act of violence -- there was blood splashed all over the walk and the foyer.

As we left we passed our friend's daughter, who was just arriving. We talked for a bit as she wanted my help with developing a website. I told her there wasn't much to making a site, said I'd help and gave her my email. She seems to have a pretty good idea of what she wants to do, just doesn't know how to go about it. Websites are actually pretty easy to make if you know what you want it to do and look like; you just need to avoid getting ripped off by the many many people that are ready to exploit ignorance. We parted ways and went home shortly thereafter.

Most of the day was spent in DFO as there wasn't much of an afternoon to do anything in and dinner was an event. Dinner was grilled steak, baked potatoes and a lot of low fat chips -- the Labor day cookout.

During DFO I made someone's day. I was simply walking through town going from one place to another when he asked for help with his Awakening in the general chat. Now Awakening is a major event in a DFO character's life; it's a rite of passage that only the most determined can make it through. It's very expensive in terms of time and gold, so not everyone manages to achieve it. If you succeed in Awakening your character they become something of a god in terms of power and ability.

He needed help getting Red Cubes and was asking for donations (either Red Cubes or Red Cube Fragments). I happened to have some Red Cube Fragments on me and so I gave them all to him. He was thrilled!

I decided to research this a little later. In addition to many other requirements, his character will need 10 Red Cubes (1,000 fragments). Note that Red Cube Fragments sell for 1,000 to 1,500 gold each; it'll cost over 1,000,000 gold for him to get enough fragments to fulfill that part of the quest. I only had 20 fragments on me, but that's a big help: 20,000 to 30,000 gold he doesn't have to spend now. Also, your average player only makes ~10,000 gold a day, so I probably saved him two or three days of work.

During the evening I looked up format specifications online and tinkered with my sound generator until the files it produces are playable everywhere. It turned out that part of the file's header wasn't being written correctly. According to some of the pages I found, corrupt sound files are a real issue, and some software (like XP) is designed with workarounds to compensate. One of the design goals of Windows 7 was to throw out the many, many workarounds and force developers to make their code correctly, hence why the broken files don't work on 7.

In other news, the link of the day is an interesting look at everyday woodlands.

MENU




- NAVIGATION -
Most recent posts
Previous Post
Next Post

- ARCHIVES -

2018
2017
2016
2015
2014
2013
2012
2011
2010
2009
2008
2007

- FOLLOW -

RSS
LJ Feed

Contact

List of UGuardian's Websites