Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

DarkBASIC Discussion / Switching from 3d to 2d

Author
Message
timthepig
20
Years of Service
User Offline
Joined: 27th Feb 2005
Location:
Posted: 1st Mar 2005 06:30
Using Darkbasic(normal)

I have written a function which contains 2d text on-screen. This function is called(entershop) when a certain object is hit. However the 2d text onscreen appears for a moment and disappears.

The 2d text function contains a loop which it needs to perform(for a shop scenario). I've tried using "DRAW TO FRONT", CLS, INK(,,) etc - and no result. Though you are able to still input on the keyboard but there is a problem with switching from 2d to 3d somewhere??

Here is the source code for my program at present

NanoBrain
20
Years of Service
User Offline
Joined: 20th Jan 2005
Location: Portland, OR
Posted: 1st Mar 2005 13:57
Timthepig,

To draw 2d text onto a 3d screen, use the text or center text commands. These commands allow for you to place text over a 3d scene. Do not worry about using the cls command to clear the screen each loop when using this command. The commands are setup like this:

text x,y,string$

center text x,y,string$


+NanoBrain+
timthepig
20
Years of Service
User Offline
Joined: 27th Feb 2005
Location:
Posted: 2nd Mar 2005 03:06
I have used the text command as in the code snippet - and I have previously removed the cls command. But it still doesn't display the text?

Login to post a reply

Server time is: 2025-05-23 19:07:50
Your offset time is: 2025-05-23 19:07:50