Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Newcomers DBPro Corner / Making underlines back into the strings

Author
Message
Towelie
20
Years of Service
User Offline
Joined: 21st Apr 2004
Location:
Posted: 5th May 2004 14:51
Alright well I almost finished my hangman program now the only thing I have to do is make the text that I turned into underlines turn back into strings, and the hanger (which I know how to do don't need help with that)

I've already got it to find where the letter is in the quote I really need soemthing like a find position of cursor command

I also need to know how I would make that underscore disapear when it did this
CattleRustler
Retired Moderator
21
Years of Service
User Offline
Joined: 8th Aug 2003
Location: case modding at overclock.net
Posted: 5th May 2004 14:57 Edited at: 5th May 2004 15:15
we have a bunch of string functions in our Plugin that may help you. Give it a look. You can download the plugin and documentation by clicking the logo below


* DBP_NETLIB_v1 - PLUGIN FOR DBP * Click LogoMooooooo!
the_winch
21
Years of Service
User Offline
Joined: 1st Feb 2003
Location: Oxford, UK
Posted: 5th May 2004 18:44 Edited at: 5th May 2004 18:45
You need to change the way the IfChoosenInString: gosub works. The letter may appear several times in the quote. With the way you have it now if the quote was.
"hello"
the user would have to guess "l" twice as you return from the gosub when you find the first "l" and the second one would remain as an underscore.



I would change it to something like this


For that to work you will need to put the extra spaces in the quote like

and not put them in in the ConvertQuoteToUnderscores: gosub

i won't see you in the pit

Login to post a reply

Server time is: 2024-09-22 08:45:08
Your offset time is: 2024-09-22 08:45:08