The Daily Click ::. Forums ::. Klik Coding Help ::. TGF Displaying a string and a counter value in an alterable string
 

Post Reply  Post Oekaki 
 

Posted By Message

Rick (AntiMatter Entertainment)

Possible psychotic

Registered
  18/10/2002
Points
  814

VIP Member360 OwnerWii Owner
27th March, 2006 at 12:54:26 -

I'm making a game where I require an alterable string to display some text followed by a value that it retrieves from a counter object. For example, when the player highlights the Lives icon I want the status bar text to say,
"Lives left: " + value("Lives")

So if the player had 20 lives, the string would read, "Lives Left: 20".

However, when I try to do this TGF says that I'm mixing values and strings in the same calculation, and won't go further. Is there any way to do this in TGF?

 

Radix

hot for teacher

Registered
  01/10/2003
Points
  3139

Has Donated, Thank You!VIP MemberGOTW WINNER CUP 1!GOTW WINNER CUP 2!GOTW WINNER CUP 3!GOTW WINNER CUP 4!
27th March, 2006 at 13:25:23 -

In MMF you'd convert the value to a string with str$().

 
http://www.klikscene.com

axel

Crazy?

Registered
  05/02/2005
Points
  4766

Game of the Week WinnerYou've Been Circy'd!
27th March, 2006 at 13:36:01 -

It's the same in TGF.

"Lives left: " + str$(value("Lives"))


 
n/a

Rick (AntiMatter Entertainment)

Possible psychotic

Registered
  18/10/2002
Points
  814

VIP Member360 OwnerWii Owner
29th March, 2006 at 02:04:47 -

Thanks, Axel.

 

Rick (AntiMatter Entertainment)

Possible psychotic

Registered
  18/10/2002
Points
  814

VIP Member360 OwnerWii Owner
29th March, 2006 at 02:46:15 -

I would have said the same about you several times in the past, but I'm more tasteful than that. Call me what you will, but nobody knows anything until they ask, and I've just never asked about that or had the need for it before. And here I was thinking that you were becoming decent and/or tolerable.

 

David Newton (DavidN)

Invisible

Registered
  27/10/2002
Points
  8322

Honored Admin Alumnus
29th March, 2006 at 09:40:05 -

Rick speaks the truth.

 
http://www.davidn.co.nr - Games, music, living in America

axel

Crazy?

Registered
  05/02/2005
Points
  4766

Game of the Week WinnerYou've Been Circy'd!
29th March, 2006 at 13:43:13 -

That\'s a very rude thing to say.

Image Edited by the Author.

 
n/a
   

Post Reply



 



Advertisement

Worth A Click