Deathmatch of Doom Chat :?

My current project, Deathmatch of Doom, is coming along great. Its a 3d multiplayer first person shooter with a server-client implementation and its really sweet so far. Today I just started writing the server code and it is really nice.

I wanto make it so players can chat amongst themselves. What would be the best way to get these messages and display the messages of other people like Quake 3 does or Half-life. I need to project the messages and the partially completed messages onto my 3d plane neatly. Any suggestions for a nice library that will do the trick or something of that nature?

PS: I will NOT use GLUT.

I’m looking for an alternative of DoRasterString();

Hi,

You want to draw some text? If so, put the characters in a texture and draw them using quads.

-Ilkka

Definatly not cool :stuck_out_tongue:

Isn’t there a printf() of OpenGL somewhere??

Actually I think printf() is NOT cool

Or use some function like wglUseBitmapFonts (raster pos) or wglUseOutlineFonts (translate, rotate, etc) or look at fonts in the FAQs section which has a few links to libraries for fonts.

Only way I know of that you will be able to use printf for text is if you create a console window. Not what you want.

I tried doing the wgl deal but it didn’t work. Does anybody know a place that can explain using Microsoft’s text functions that are within wgl? Thanks

fontBase = glGenLists(255);
err = glGetError();
if (err)
DoError();
SelectObject(m_hdc, GetStockObject(SYSTEM_FIXED_FONT));
if (!wglUseFontBitmaps(m_hdc, 0, 255, fontBase))
DoWinError();

OR

GLYPHMETRICSFLOAT agmf[255];
HFONT fontol = CreateFont(-1, -1, 0, 0, FW_THIN, 0, 0, 0, ANSI_CHARSET, OUT_OUTLINE_PRECIS, CLIP_DEFAULT_PRECIS, DEFAULT_QUALITY, DEFAULT_PITCH | | FF_ROMAN, “Arial”);
SelectObject(m_hdc, fontol);
BOOL font = wglUseFontOutlines(m_hdc, 0, 255, 1000, 0.0f, 0.1f, WGL_FONT_POLYGONS, agmf);

if (!font)
DoWinError();
glListBase(1000);

[This message has been edited by shinpaughp (edited 04-20-2003).]

Thanks a lot! I’ll try that out ASAP but for now because, necesito dormir pero, tengo escuela manana.