X-Sight Development Diary
Wednesday, November 19, 2008
09:45:23 AM
After checking the Klango survey I conducted last Monday, I finally write a program which will generate an HTML file with the date and time the entry was saved in addition to what I write in the main interface.
I will be switching from one FTP to another - my website FTP, to upload the first diary entry and to link to it on the main home page. Yeah, I know, I could probably make a PHP script to do the same thing, but as I'm not as experienced in PHP as I am in VB, that can wait.
At the moment, until I learn how to do this in PHP, I'm having to use a standalone windows executable to write the thing and manually upload it.
10:47:31 AM
Sheesh! Converting every audio related project to use PBStreamway can be a pain, especially if such audio projects turns out to be more than half of them!
With 4 music related projects, 2 DLL's, 2 conversion utilities that use audio, 2 audio simulations, an internet utility, a system related program, a text editor, a clock/timer (Talking Timepiece), and over 50 games, converting from DirectX to Streamway will probably take a good few months. It could possibly mean a complete rewrite for some, as understanding code that is either months/years old, or someone else's, is pretty hard.
Mike is supposed to be helping us out, but obviously programming muds has made him more adventurous on the programming front, and he wants to switch to C++.
However, until I understand how to use C++ properly, I'm for the moment stuck with VB, which, I will admit, I still do have a lot to learn about, especially on the object-oriented side.
So for the moment, I am, it seems, alone. Having converted Number Challenge to use PBStreamway, and also my extremely naked game library, I once again attempt to look for my missing word games.
I also managed to find my Blind Man's Bluff code, but, remembering with dismay that I no longer have the SAPI 5.1 SDK, it will have to be held off until I can get it.
04:59:08 PM
Since my last entry I've been thinking a lot about this game library I'd like to make.
A nice DLL with menu functionality, a basic set of cassino algorithms, including a wheel spinner and the cunningness of a modern day fruit machine, simple functions that you'd almost expect any game to carry out, such as randomising and playing audio, audio menu creator, player, enemy and item classes and, of course, scores, with record saving capabilities both for your machine and a score server, obviously including a number speaker.
I've been sitting here working on the menu class, which will create a blank menu that you must link options and background ambiences to, and then I thought, how would that work with my PBStreamway licence? The owner of Streamway already informed me that I wouldn't be allowed to release a simple wrapper, but a game library?
07:13:16 PM
After speaking with Leonard de Ruijter, one of the members of Playing in the Dark, I finally set out to provide the third release candidate of TopSpeed2 Utility Pack, whose first RC was bundled with the first RC of TopSpeed2.1.
RC3 of the pack would add a new feature into the server selection utility, just as long as it didn't keep either freezing my system, or crashing the pack. The ability to check a server's status, I.E. whether it is currently hosting a game or not, was suggested to me a couple of days ago by Sean Randall, a TopSpeed fan.
He himself already wrote a few useful utilities for TopSpeed2, which is what gave me the idea.
When I first wrote this feature, it checked while you were navigating the server list. This froze my whole system, possibly because of the lengthy time it takes to attempt to connect to a server, whether on or offline.
Now here comes the new and improved version of the feature, where you set an initial timeout value, and you have to press a button to check the status. This easily improved the old system. It doesn't freeze my whole computer any more, it only freezes the program, which means you close it down, and you get one of those fancy "This program is not responding" messages. You press End now, and you get another fancy "TS2Pack1.0RC3 has encountered a problem and needs to close".
Therefore I spent what little remaining time I had left to complete RC3 on updating the documentation. The change log and the translation reference now have all the relevant information required ready for this new feature, which I hope I won't have to throw in the dustbin. However, if I do, God forbid, I still do have the original code, so reverting back to RC2 won't be a pain in the ass.
07:33:41 PM
After improving the checking server feature by ceasing to be a dumb idiot (setting the timer for the timeout option to actually take some form), it now recognises a server that is down. However it still crashes when a server is connected, as I found out while testing Leonard's server.
11:46:12 PM
Wow! So I've completed the menu component of my game library!
Well, that's all well and good, but only if VB6 stops giving me errors about bad DLL calling conventions just for looping ambience sounds!
I will have to approach other Streamway testers and of course the developer himself to find out what the possible causes are here.
Thursday, November 20, 2008
12:37:34 PM
OK, so I find out today that I wouldn't be allowed to release this library using Streamway as an audio interface.
I'm gonna have to look around for a different library for making libraries. Like the sound of that phrase. LOL.
Saturday, November 22, 2008
06:59:02 PM
Well well well. I attempt to code more of the TS2Pack today, but find to my utmost horror that half of the code I can no longer test, due to the absence of HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\{00406195-B30C-45C6-87A3-0142A2BDC9ED}_is1.
For people who don't know what this is, this is a key in the registry that contained all the installation information for TopSpeed2, including its location, version, author's information, publish/install date, etc.
Because of this, when I try so much as download a package now, I get a nice "run-time error 5 invalid procedure call or argument" message, because it's trying to truncate null characters from a string that has no characters in it at all.
Just marvelous. I wonder if Inno Setup produces some random code on installation, or whether it bases its code from something else, although I can't seem to find any installation information for TopSpeed2.1 at all now.
This means, for the inconveniences of everyone, that I am currently unable to test the new multiple selection listbox now provided by the package downloader.
Saturday, November 29, 2008
10:48:45 AM
Well, for the past three hours this morning, and some five hours last night, I have finally got the main interface sorted out for my virtual pet. Having now found a way to warn the user if they are about to close the program without the darn thing just quitting on me even when I said no, I am now trying to figure out an equally tricky piece of programming known as hiding to the system tray.
However, I've got the basic concepts of the pet code written and working, when you navigate the list you get the beeping, as if you were pressing buttons on a handheld virtual pet, you get different beeps for the letters so you can hear its name being called, and various sounds and beeps to indicate how your pet is currently feeling.
Also, the obstacle of computers being either left on or switched off has been tackled. If you won't be looking after your pet for a while, you simply take it to the kennels, like you would an ordinary dog.
If you forget to do that, depending on how long your pet isn't loaded for, your pet will die.
The main pet's functions aren't yet coded, for example eating, drinking and sleeping, however it can and will bark at you from time to time.
Also, in time, I plan to add more pets to it. When I have a stable pet class, it should be easy to simply add new pets to the list, because all I'll have to do is add a new sounds directory and new increment/decrement rates depending on the animal that is chosen.
However, as I am relying on the use of VB timers to increase/decrease, and not a formula, this is currently not possible.
Although it's strange that now I've written this comment, I've just had an idea that I could possibly use a time for the rates, for example number of seconds to increase/decrease depending on what the action is.
Whatever happens anyway, there will be more pets to go for.
At the moment, however, it's just a pure old plain sold dog.
01:34:04 PM
Hi again.
After attempting to write an online "live diary", I failed. Why?
- PHP. PHP's file and text processing functions aren't the same as VB. As a result, I end up with a HTML file with multiple HTML headers and footers, line breaks where there shouldn't be, both textually and in the HTML code, and uses of the same date aren't yet being filtered out properly.
- Dates and times. Our website is based in the United States, which means that any times that show up in the diary are five hours earlier than they should be. Can you retrieve the hour as a plain number in PHP so you can add on five and possibly take off 12 where necessary?
- Security. Yes, before anyone asks I wrote a login system. However, if a hacker, or even a standard user for that matter, guessed the filename of the scripts that make the diary (they aren't named in fancy code or anything), it would be just as easy to bypass the login and get straight to the updater.
So yes. I've failed. I may be a failure like so many people both on and offline are telling me. I dunno.