The Daily Click ::. Forums ::. Klik Coding Help ::. Custom names in dialog
 

Post Reply  Post Oekaki 
 

Posted By Message

-Liam-

Cake Addict

Registered
  06/12/2008
Points
  531

Wii OwnerIt's-a me, Mario!Hero of TimeStrawberry
11th November, 2007 at 07:32:33 -

I'm making a game where the main characters have default names but can be changed by the player when they are first introduced into the game, like in your average RPG. I think/hope it should be relativly simple, how is it done?

Thanking you

 
Image

Tell 'em Babs is 'ere...

Del Duio

Born in a Bowling Alley

Registered
  29/07/2005
Points
  1078

GOTW WINNER CUP 1!GOTW WINNER CUP 2!GOTW WINNER CUP 3!GOTW WINNER CUP 4!Evil klikerHasslevania 2!The OutlawSanta Boot
11th November, 2007 at 07:52:19 -

Hmmm, sounds as easy as assigning the player's name to a string value, and when it comes time to have some text display, do something like:

Change alt string to "Wow, our village has been waiting for you " + (your string value for the player's name) + " for over a month now. What kind of hero ARE you anyways!?"

If that's what you mean,, that's one way to do it.

 
--

"Del Duio has received 0 trophies. Click here to see them all."

"To be a true ninja you must first pick the most stealthy of our assorted combat suits. Might I suggest the bright neon orange?"

DXF Games, coming next: Hasslevania 2- This Space for Rent!

-Liam-

Cake Addict

Registered
  06/12/2008
Points
  531

Wii OwnerIt's-a me, Mario!Hero of TimeStrawberry
11th November, 2007 at 07:54:33 -

EXACTLY what I wanted to hear, thank you Del Duio!

 
Image

Tell 'em Babs is 'ere...

Del Duio

Born in a Bowling Alley

Registered
  29/07/2005
Points
  1078

GOTW WINNER CUP 1!GOTW WINNER CUP 2!GOTW WINNER CUP 3!GOTW WINNER CUP 4!Evil klikerHasslevania 2!The OutlawSanta Boot
11th November, 2007 at 07:55:51 -

Oh good, I thought I had read it wrong. Good luck!

 
--

"Del Duio has received 0 trophies. Click here to see them all."

"To be a true ninja you must first pick the most stealthy of our assorted combat suits. Might I suggest the bright neon orange?"

DXF Games, coming next: Hasslevania 2- This Space for Rent!

-Liam-

Cake Addict

Registered
  06/12/2008
Points
  531

Wii OwnerIt's-a me, Mario!Hero of TimeStrawberry
11th November, 2007 at 08:18:32 -

Oh, one more thing.... =|

To make it permanent, I'd use the ini object, right? I havrn't delt with saving values after closing an application since the first TFG. Any new ways introduced since MMF2?

 
Image

Tell 'em Babs is 'ere...

Del Duio

Born in a Bowling Alley

Registered
  29/07/2005
Points
  1078

GOTW WINNER CUP 1!GOTW WINNER CUP 2!GOTW WINNER CUP 3!GOTW WINNER CUP 4!Evil klikerHasslevania 2!The OutlawSanta Boot
11th November, 2007 at 10:02:51 -

Sure, you could use the ini file, I don't see why not. And it's not like a character's name is exactly sensitive information should the user open the file up and look around. It might be cool, you could always edit your name in case you were farting around and typed it in as "dA_dEmOn_No1!"

But they'd probably just change it to Maxim, one of the most overused RPG names in all of history.

 
--

"Del Duio has received 0 trophies. Click here to see them all."

"To be a true ninja you must first pick the most stealthy of our assorted combat suits. Might I suggest the bright neon orange?"

DXF Games, coming next: Hasslevania 2- This Space for Rent!

DaVince

This fool just HAD to have a custom rating

Registered
  04/09/2004
Points
  7998

Game of the Week WinnerClickzine StaffHas Donated, Thank You!Cardboard BoxDos Rules!
12th November, 2007 at 05:32:46 -

Keep the names in global strings, and ONLY get them out of the INIs when you load up the game (just store them into the global strings). Else, you might alter the INI in-game and immediately affect gameplay, and that is not what you might want.

 
Old member (~2004-2007).
   

Post Reply



 



Advertisement

Worth A Click