ID:165422
 
I decided recently to try making some small games out of boredom and to learn more of the language.

So far I have already managed to do most of it, but what Im really stuck at is the visuals. I want it so that when you guess a letter, it appears on the screen, what i cannot do is set each empty tile to one of the letters from the word.

Here is some what I have so far:
var/list/Words = list("Apple","Orange","Grape")
var/active_word = ""
var/activated = 0

mob/verb/Guess_Letter()
set name = "Guess Letter"

Set_Word()
src.GuessLetter()



proc/Set_Word()
if(activated) return

active_word = pick(Words)
activated = 1



mob/proc/GuessLetter()
var/guess = input("Enter a letter please") as text|null

if(length(guess)==1)
if(findtext(active_word,guess))
src<<"You got the letter <font color=red>[guess]</font>!"
sleep(10)
switch(alert("Which would you like to do now?","Hangman","Guess Letter","Guess Word"))
if("Guess Letter")
src.GuessLetter()
if("Guess Word")
src.GuessWord()
else
src<<"Better luck next time! ([active_word])"
return
else
src<<"You may only enter one letter."
return


I'd appreciate any help, thanks.

Zythyr ++
Bump, still stuck on this guys, any help would be appreciated.
What is the 'activated' flag for? You can just check the 'activated_word' var to see if the game begun already or not.

On the letter-drawing, you'll want to check out hub://LummoxJR.DmiFonts