Jump to content
  • Advertisement
Sign in to follow this  
sipickles

std::lists and WCHAR[128] or std::string

This topic is 4525 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hello! I was going to use this std::list<WCHAR[128]> m_output; to keep a list of text strings, but looks a bit weird! So I thought, why not: std::list<std::wstring> m_output; my text is coming in as WCHAR*s, is there a better way to do this? I wanna use lists so I can push_back and pop_front Thanks Simon

Share this post


Link to post
Share on other sites
Advertisement
Yeah I got that.... but my problems persist.

I wanna store the last ten text messages in my std::list, to display on screen.

When a new message is recieved, it is push_backed.

If list size > 10, then pop_front.


At render time, iterate thru the list, stringcchcat-ing the elements of the list into a new variable, then render the text.

Does that make sense?

Si

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

Participate in the game development conversation and more when you create an account on GameDev.net!

Sign me up!