Jump to content

  • Log In with Google      Sign In   
  • Create Account

We're offering banner ads on our site from just $5!

1. Details HERE. 2. GDNet+ Subscriptions HERE. 3. Ad upload HERE.


Making a typeable for ingame name


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • You cannot reply to this topic
1 reply to this topic

#1 BaneTrapper   Members   -  Reputation: 1243

Like
0Likes
Like

Posted 04 October 2012 - 11:22 AM

Hello.
Currently i am working on "Turn based,2d Rpg" with c++ and sfml2.0 libs,
and i reach stage i got no idea how to manage.

After a user presses a "New Game" i move him intro a screen where he picks a character,
He needs to chose following:
1:Name
2:Character type
3:Stats

Character type and stats i control with collision detection, but how do i manage the name input?
After he presses inside the "Type name here" box, i should turn on a special loop in "class that handles event"
anything that he types i push intro. And each loop i print what is in string intro the "Name box"


Questions:
Is there a premade library for handling this kind of stuff for c++ or at sfml2.0?
If you read above, is it efficient or should i look intro it better?
How do i know when the user finished typing in his name, check if he clicks anywhere away from the "Type name here" box? tips please.

Current projects:
The Wanderer, 2d turn based rpg style game

www.gamedev.net/topic/641117-check-up-the-wanderer/


Sponsor:

#2 BeerNutts   Crossbones+   -  Reputation: 2997

Like
1Likes
Like

Posted 04 October 2012 - 02:33 PM

There isn't anything premade in SFML to handle this, but there are some GUI's you can use.

In the SFML 1.6 tutorials, he shows how to integrate SFML with QT (again, it's SFML 1.6, so API is slightly different).

Or you can look at some of the SFML GUI's available now, although in different states of completeness:
TGUI
or
SFGUI

Good Luck!
My Gamedev Journal: 2D Game Making, the Easy Way

---(Old Blog, still has good info): 2dGameMaking
-----
"No one ever posts on that message board; it's too crowded." - Yoga Berra (sorta)




Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS