Boy was I up late last night. I was chasing the ability to read letters in a word, and I was so close for so long that I kept on hounding it. Now, I have it. It’s not all the way built yet, but enough parts are dancing that I can get the code to summon up an enemy based on what the letter (or character) is.
Still haven’t figured out how to load the thrice damned things from a separate text file, but I’ve got it handled well enough to move on and start prototyping. Basically, each level will be made up of several lines of text, great big words that’ll summon up everything in the game. A short sample may look like this :
“……<..>
See, that doesn’t look like anything. But the computer knows better. So after a set period of time I’ll ask the computer, “What’s the next character in the Word?”
“It’s a ‘.'” it’ll reply.
“So what do we do with periods?”
“Nothing, cause they are empty sky.”
Then I’ll congratulate the computer and give it a cookie.
Eventually I’ll ask and it’ll say, “There’s a ‘
So over the course of the level the system will do this a couple of hundred times if not more. Always move to the right and propagate the levels will all kinds of Class Based wonderment. If I add a little thing that makes all the “stationary” stuff go to the left slowly, I’ve created a scrolling environment. It’s a very good thing.
– I’m discovering that knowing enough about C# to be dangerous is only half the story, if not less. For some time the system kept telling me that files aren’t where I said they were, and I told the system that it was a liar. Other software that I look at for guidance (and the occasional reverse engineering) referenced the files the same way I was. The system, was simply wrong.
Turns out, I wasn’t being polite. Or rather, I was making some kind of formal / informal faux pas. There’s some little command that I could add to a file set, that would allow me to reference stuff relatively. So instead of C:/ProgramFiles/CSharp/Loot/stuff.text I could just say Loot/stuff.text. If I went through the right hoops. It also gave me rage when it demanded that I do something special so it wouldn’t get confused by the ‘/’s.
The thing is, this comedy of manners only exists because the things are too basic to ever talk about. It’s assumed that if you are a programmer, you should just know these things. It creates a certain kind of unease. I mean I add things, small things, and compile the code just so I know I didn’t make a mistake. It makes for slow going.
Eventually, I’ll be fluent if not at least conversational.