i'm still tryin, the entry$() is not workin right. so i will just stick with the input command. I was looking at a hangman program in the code base, and then many others in the code base and found that they don't really do much documentation of what they are doing in the code so it's really hard to understand for a newbie like moi. here's what i have so far, it's still a bit buggy; the part where the new blank$ is printed. :
randomize timer ()
`declare the states
dim state$(10)
state$(1)="arizona"
state$(2)="georgia"
state$(3)="alaska"
state$(4)="mississippi"
state$(5)="florida"
state$(6)="virginia"
state$(7)="texas"
state$(8)="california"
state$(9)="arkansas"
state$(10)="kansas"
`pick random word
rndstate$ = state$(rnd(10))
`return amount of letters in word
statelen = len(rndstate$)
dim state(1,statelen)
`makes an `*` for a blank
blank$ = ""
for n = 1 to statelen
blank$ = blank$ + "*"
next n
`display
text 500,10, rndstate$
text 500,25, blank$
set text opaque
`main loop
do
set cursor 10,10
input "Pleae choose a letter "; guess$
for letter = 1 to statelen
if mid$(rndstate$,letter) = guess$
print "Correct!"
blank$ = left$(blank$,letter-1) + mid$(rndstate$,letter) + right$(blank$,letter-1)
text 500,25, blank$
else
print "Incorrect!"
endif
next letter
sync
loop
wait key