Tao of the Machine

Programming, Python, my projects, card games, books, music, Zoids, bettas, manga, cool stuff, and whatever comes to mind.

On alchemy

This is the first post in a new category, "esoterica". This basically covers everything skeptics don't like, including (but not limited to) astrology, tarot, I Ching, runes, oracles, UFOs, etc.

And alchemy. I don't know too much about it (chemistry is not my forte), but it was (and probably still is) based on the notion of four elements: fire, earth, air, and water. Not coincidentally, western astrology works with these elements as well.

Back in high school, alchemy was cursorily brushed over in the introductory chapter of our chemistry textbook, and the authors happily debunked the system of four elements. Earth is a vague description of something that consists of many chemical elements, water (H2O) consists of two elements, air of multiple elements as well, and fire isn't a chemical element at all.

No, no, no. That is not what the four elements stand for. Consider this list:

  • earth stands for matter in a solid state.
  • water stands for matter in a liquid state.
  • air stands for matter in a gaseous state.
  • fire stands for energy.

If I recall correctly, these look suspiciously like the four states of matter, as known in modern physics. Seen in that light, the ancient ideas of alchemy do not seem so backward at all.

(braces himself for flames from skeptics, physicists and chemists emoticon:sweatdrop)

Posted by Hans Nowak on 2003-07-04 23:45:44   {link}
Categories: esoterica

Thursday roundup

Picking other people's brains weblogs and mails...

1. Guido on Jef Raskin's The Humane Interface. (via Fredrik Lundh)

Interesting, that LEAP key. I wonder if the Ctrl key could be used for that, on a regular keyboard? Probably not; IIRC, pressing Ctrl+<key> often generates a different key code altogether. But maybe it's worth a try.

2. Moshe Zadka: Networking for non-programmers (and a conclusion). Contains some useful basics, also for programmers who don't know networking... A few years ago, I had my MCSE, but that doesn't necessarily mean that you know how a network works. emoticon:smile

3. Via Kyle Cordes: a video of an interesting talk by a computer language researcher. Supposedly he also likes Python. (I haven't been able to watch the video myself yet; I think my Media Player is somehow broken, it only shows a black screen.)

Posted by Hans Nowak on 2003-07-03 20:46:34   {link}
Categories: programming, Python, linkstuffs

Hey, I know that snake...

This one, to be precise... I used to have it, or one very similar, back in the Netherlands. Sadly, I couldn't bring it with me to Florida.

In other pictures: looks like somebody farted... emoticon:smile And, why did the photographer take a picture of somebody's foot? emoticon:loveit (Extra points if you know who it is.)

Also (old EuroPython 2002 notes) (Q = audience, A = Guido):
Q assignment inside expressions?
A no, never (scattered applause)
Q so why is it used in the C source to Python?
A oops, we've run out of time

(same page:) I wonder who said "Cannot find Python developers"... they can always hire me, then.

Posted by Hans "from the useless-fact-of-the-day department" Nowak on 2003-07-02 21:29:05   {link}
Categories: Python, Nederland

The Legend of Zelda: Wind Waker

I really hate games that make you do a lot of stuff and then, when you die, make you start all over again from the beginning.

That said, it's really hard to hate Zelda: Wind Waker (for the GameCube). This is a very rich game, full of quests, subquests and sub-sub-quests, full of nice goodies, effects and cool ideas.

The quest starts out simple enough. You are on your island, and after exploring it (which serves as a tutorial to get used to the controls and such) somebody gets kidnapped by a huge bird. After rescueing her, your sister gets kidnapped, and it won't be so easy this time to find her and set her free. Thus, you set out on a pirate ship, to the Forbidden Fortress. After inspecting the fortress in and out, it turns out that things are even more complex than they seemed, and you will have to visit several islands and solve numerous subquests in the process.

I already pointed out (what I perceive as) the major flaw of the game. There are several dungeons, full of enemies, traps and the like. In other words, you die a lot. If you just lose some life, you can try again from a point not too far away from where you were. However, if you lose all your life, or you save the game and come back later, then you will have to start at the very beginning of the dungeon again. You will still have the items you collected, and some puzzles will remain solved (e.g. doors you unlocked), but the gist of it is, that you will have to find (and fight) your way through again. A little annoying when you died on level 4 of the dungeon.

To make things worse, some puzzles and situations are devious, and by dying you'll find out that the solution you tried is not the correct one. Take the floating disc somewhere on the Dragon Roost Island dungeon, for example. It is attached by three ropes. When you cut one, the disc topples and you fall off, into the lava. Ouch. The correct way is to cut all three ropes at once, using your spinning move, but that's not obvious until you die. (And even then...)

That, and the camera (which is sometimes hard to control) are the only flaws I could find so far. Fortunately, there's lots of good stuff. Z:WW paints a rich world, with islands full of interesting characters. I especially liked the part where you go from the Windfall Island to Dragon Roost Island. A boat with a talking dragon's head urges you to find a sail. That isn't so difficult, although there are many little quests on that island that will slow you down (and some of them cannot be solved until you've been to other islands). So, you put the sail on the boat, steer the boat in the direction of the arrow (indication the wind), and after a while, you arrive at your destination. Here, the boat/dragon gives you the Wind Waker, some kind of magic wand that uses series of notes for spells. (Kind of like Loom! Yay! emoticon:loveit) You cast a spell by conducting the wand, using up, down, left and right. The first one you learn allows you to change the direction of the wind, which is very useful for going to other islands.

The game is full of interesting puzzles, and interesting tools to help solve them. You get a grappling hook, for example. There are bombs to blow up rocks and other things that are in the way. There are platforms, ladders, narrow edges, hidden doors, bridges... A lot of interaction with the environment is possible as well. Frequently, you get to break things, throw them, burn them, climb on top of them, pull them...

All in all, this is a great game, in spite of the drawbacks. It will keep you busy for hours and hours. (Days and days is probably more like it, or maybe weeks and weeks, in my case?) It isn't easy -- some puzzles are simple, but others really aren't obvious, so getting the strategy guide is probably a good idea.

Let's see how far I can get before I have to hand over the GC to my daughter, in 10 days or so. :-)

Posted by Hans Nowak on 2003-06-30 17:13:50   {link}
Categories: games

A simple upload script

Nothing fancy, but here's a simple script that can be used to upload files. As such, it is mostly for newbies, especially those on Windows. I added it to the right-click menu (I'm using Win2K) so I can upload a file quickly by right-clicking it and selecting 'Upload'.

First, create a script like this:

import ftplib
import os
import sys
import traceback

print "Files:", sys.argv[1:]

print "Logging in..."
ftp = ftplib.FTP()
ftp.connect(host, port)
print ftp.getwelcome()
try:
    try:
        ftp.login(login, password)
        ftp.cwd(some_directory)
        # move to the desired upload directory
        print "Currently in:", ftp.pwd()

        print "Uploading...",
        fullname = sys.argv[1]
        name = os.path.split(fullname)[1]
        f = open(fullname, "rb")
        ftp.storbinary('STOR ' + name, f)
        f.close()
        print "OK"
        
        print "Files:"
        print ftp.retrlines('LIST')
    finally:
        print "Quitting..."
        ftp.quit()
except:
    traceback.print_exc()
        
raw_input("Press Enter...")

Save it as upload.py or something. As said, it's nothing fancy, just a script that takes a file on the command line, and uploads it to the desired location.

Now, on Win2K (and probably XP), go to a window's menu, select Tools, then Folder Options. Click the File Types tab, then find the entry for zip file (or whatever file you want to use) and select it. Click the Advanced button. Click New..., type "Upload" in the Action bar, and in the application bar something like c:\python22\python.exe c:\path\to\upload.py "%1" %*. Click OK, OK, OK. When the changes take effect, zip files should show a new menu item 'Upload' when you right-click them.

Posted by Hans "hey, I gotta write about *something*" Nowak on 2003-06-29 22:35:27   {link}
Categories: Python

Sextile 0.4.2 is available

Find it here. Don't forget to read the docs first.

Posted by Hans Nowak on 2003-06-29 22:27:13   {link}
Categories: Python

Misc

  • Hikaru No Go has been licensed. (For the non-manga-otakus, that means that some US publisher is going to do the American release, making scanlations on the Net pretty much illegal.) Fortunately, MangaReaders still has a number of chapters that TW didn't release. (If that link doesn't work, go to mangareaders.com, log in (maybe after registering), and go to the download section.)
  • I'm writing this using Sextile. It's quite usable, I only need to add a few more features, like lists. Combined with macros, it's really quite powerful, and it doesn't get in my way.
  • I registered my weblog at Artima buzz. Apparently they just added all my posts to the top, so the whole first page of "latest posts" consists of my writings. emoticon:bloos So far, Pyblagg has far more weblogs, though.
  • The number of Google hits for "luna lovegood" are increasing daily.
  • Occasionally I find myself thinking "gee, this programming problem would have quite an elegant soluton in Lisp". The dark side beckons...
  • Currently reading: Harry Potter and the Order of the Phoenix (OK, I finished it, but maybe I'll do a reread, like the hardcore fans :-); Orson Scott Card: Seventh Son.
  • Currently listening to: In Extremo, Osdorp Posse, Clawfinger, Dawn Penn, H-Blockx, Puhdys, A Split Second, Bloodhound Gang, Gotcha!
  • Currently hacking on: Firedrop2, Sextile

Posted by Hans Nowak on 2003-06-28 15:05:25   {link}
Categories: general, manga, programming, Python, books, music

--
Generated by Firedrop2.