Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Counting Sprite Occurances on the Stage

Status
Not open for further replies.

Dazza203

Technical User
Dec 3, 2003
28
GB
Hi,

This is quite difficult to explain but I'll try my best. I have created a simple hangman game but at the beginning of each game I want to display the number of letters that are containing in the word on the stage. This should be simple but I am quite new to Director and lingo and I can't work this out. The game works by chosing a word from a list stored in a text box in the cast at random and displaying that number of dash images on the stage depending on the number of letter in the word, surely there must be a simple way of just displaying the number of letters contained in the word on the stage in a text box or something? I have uploaded the entire Director file here: to you should be able to see what I am talking about. If this doesn't work for anyone private message me or reply to this message and I'll be happy to email it to you. I know what I want to do must be quite simple I just can't figure it out. Any help would be appreciated because I'm stuck with this.

Thanks,
 
length will give you the number of letters in a string.
--
put "Word".length
-- 4
--
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top