Jump to content
IGNORED

Intle: Wordle for Intellivision


cmadruga

Recommended Posts

Came across a minor bug.

The check to prevent keypad #0 from being used if the word was already chosen:

 

            IF try_number = 0 AND #backtab(CUR_BTAB_POS) <> HYPHEN AND \
               word_chosen = 0 THEN
 

ran afoul of a quirk in IntyBASIC's macro processing and operator precedence.

After expanding CUR_BTAB_POS, the generated code performed the first AND

operation as if written (try_number = 0) AND HYPHEN ...

The result was that subsequent pressing of keypad #0 could replace the

chosen word with empty characters, leading to an unplayable game.

I've notified @nanochess

 

The work around, and general take away, is to be very excessive with use of parentheses

in complex conditionals, e.g.:

 

            IF (try_number = 0) AND ((#backtab(CUR_BTAB_POS)) <> HYPHEN) AND \
               (word_chosen = 0) THEN

 

The fix, v5.1, is attached.

 

I also took the opportunity to add some comments around the packed words,

for example changing

 

    PACK_WORD("A", "B", "A", "T", "E")

to
    PACK_WORD("A", "B", "A", "T", "E")   ' "ABATE"

 

for easier grepping of words (used only for curiosity sake,

and never, ever, to help play the game!)

 

Ideally we could write PACK_WORD("ABATE"), but then we would

need a substring or charAt feature in order to access the individual

letters.  Perhaps IntyBASIC already supports that and I'm unaware?

 

Finally, I encountered one of my more interesting games when testing this out,

in the attached gif.  Perhaps we need to rate this game "M for Mature".

 

funnyintle.thumb.gif.8aeff2e539a1ac6f5554cc67223a79a0.gif


 

intlev5.1.rom intlev5.1.bas

  • Haha 1
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...