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 / text on 3d screen

Author
Message
Sonic 91 Software
20
Years of Service
User Offline
Joined: 19th Mar 2005
Location: In a Cryptic Crossworld!
Posted: 11th Nov 2006 22:07
help me please! i'm making a game that totals up the score at the end of each level, but the text appears on the screen for a split second and is gone again in the blink of an eye! this code is trying to total up the score at the end of level 1 as the player object is moving to level 2:



(object 100 is the player object and object 101 is a hidden box used to detect collisions)

"Fight the good fight of faith,
Lay hold on eternal life"
-1 Timothy 6:12
Sonic 91 Software
20
Years of Service
User Offline
Joined: 19th Mar 2005
Location: In a Cryptic Crossworld!
Posted: 11th Nov 2006 22:17
isn't it wierd that when you are stuck on something and you have no idea how to do it, so you post it in the forums, then as soon as you do that, you suddenly get many ideas on how to sort out whatever you were stuck on to begin with? i solved the problem i was having, by putting te total calculation and the text display in one loop before breaking from that loop with "exit" and going to another for the rest!

"Fight the good fight of faith,
Lay hold on eternal life"
-1 Timothy 6:12
Grog Grueslayer
Valued Member
19
Years of Service
User Offline
Joined: 30th May 2005
Playing: Green Hell
Posted: 12th Nov 2006 02:12
That happens all the time.
slicer 4 ever
18
Years of Service
User Offline
Joined: 11th Jul 2006
Location: currently: planet gamma3295
Posted: 12th Nov 2006 05:58
always happens to me=-)

my smiles love me =-)=-)=-)(-=(-=(-=
indi
22
Years of Service
User Offline
Joined: 26th Aug 2002
Location: Earth, Brisbane, Australia
Posted: 12th Nov 2006 11:29
if you want a speed up.

create a 2 polygon panel in 3d
create a bitmap away from the screen
print the new texture from the variable
update the texture

this prevents every loop printing and ultimately increases speed due to mixing 3d with print and ink.

Sonic 91 Software
20
Years of Service
User Offline
Joined: 19th Mar 2005
Location: In a Cryptic Crossworld!
Posted: 12th Nov 2006 13:51
I'm not sure about that, indi. wouldn't printing a new texture from a variable slow things down?

"Fight the good fight of faith,
Lay hold on eternal life"
-1 Timothy 6:12
indi
22
Years of Service
User Offline
Joined: 26th Aug 2002
Location: Earth, Brisbane, Australia
Posted: 12th Nov 2006 14:22
Im using it in my game with great fps.
would you prefer a print and ink every loop or would you prefer one texture update when required.?

Sonic 91 Software
20
Years of Service
User Offline
Joined: 19th Mar 2005
Location: In a Cryptic Crossworld!
Posted: 12th Nov 2006 16:15
OK, that is slighly out of my knowledge at the moment, we all know there is a learning curve to programming and if what you are describing really helps speed things up, can you show me a small example with code? It's probably an obvious thing to do, and very easy, but at the moment I'm still unsure.

"Fight the good fight of faith,
Lay hold on eternal life"
-1 Timothy 6:12
indi
22
Years of Service
User Offline
Joined: 26th Aug 2002
Location: Earth, Brisbane, Australia
Posted: 13th Nov 2006 00:01 Edited at: 13th Nov 2006 00:08
sure mate, here is a sample, not only that they can behave as 3d buttons. the functions within this example show how it can be done.
asking for code when you havent made an attempt however might stump your learning, however heres a sample.


Login to post a reply

Server time is: 2025-05-25 22:33:48
Your offset time is: 2025-05-25 22:33:48