How do I write text to the screen with C#?[SOVLED!!!]

If you are a new Irrlicht Engine user, and have a newbie-question, this is the forum for you. You may also post general programming questions here.
Post Reply
Galaxy613
Posts: 20
Joined: Wed Jun 01, 2005 12:46 am
Location: USA, VA
Contact:

How do I write text to the screen with C#?[SOVLED!!!]

Post by Galaxy613 »

This is getting really really frustrating!! I can't find out how to write to the screen in C#. In C++ I could just add static text, but GUI does not work in C#! And when I try to do "IGUIFont fnt = new IGUIFont(null);" so I can do "fnt.Draw("Hello World!",new Position2D(32,32),new Color(0,255,200,200));", it gives me an error "Pointers may only be used in unsafe code." and I don't see one damn pointer there!!! :evil:

Help? :(

|EDIT|

YEY!!! I found out how to print stuff to the screen! :D I'll sohw everyone!

Code: Select all

//start up the main() function...create a new IRRLichtDevice and put it
// into 'device'...then:
IGUIFont fnt = device.GUIEnvironment.BuiltInFont;
//dum de dum, finnish up. now in the main loop, right smack
// after "device.SceneManager.DrawAll();"...
fnt.Draw("Hello World!",new Position2D(32,32),new Color(0,255,255,255));
//contiune till you end!
I'm so happy! :)
Image
Post Reply