It shouldn’t be this difficult. Why am I having so much trouble? All I want to do is create a variable that can change over time. I mean, all I want is a variable that works. It’s a counter. It’s seriously just a counter. I came up with the following code, which works in my head, but for some reason doesn’t work in Inform 7:

    Before going somewhere: increase hour_count by 1.
    if hour_count is greater than 5;
    decrease hour_count by 6.

What this should do is have a counter that resets once each time a character enters an area. I haven’t even gotten so far as having this change the time of day because I can’t get it to count anything.

edit: I had a freaking breakthrough. The problem is a combination of several things. First of all, I needed to think about each of these items as being completely separate. “Before going … increase counter by 1” should be a line by itself. If I can’t get a “simple” function to work, I shouldn’t try to make it fancy. The second line should read: “Before going … if hour_count is greater than 5;” and so forth, more like this:

    Before going somewhere:
    if hour_count is greater than 5 begin;
    decrease hour_count by 6;
    end if.

I’m going to have to play with this more before it makes complete sense. >_<