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 Printing Over text

Author
Message
Zooker
21
Years of Service
User Offline
Joined: 27th Oct 2002
Location: United States
Posted: 25th Nov 2002 01:50
I want to be able to have text printing over Text and leaving nothing behind. I used SET TEXT OPAQUE but when I print over the same line I printed previously the remains of the other letters are there. How can I stop that. Is there any way to make a Space$ comand which will obliterate the print? Do I need any other text statements then the One I Used? (:
simonuk74
21
Years of Service
User Offline
Joined: 3rd Nov 2002
Location:
Posted: 25th Nov 2002 01:56
when you want to `refresh the screen` with new/different text, you would have to use the CLS command.
If you were to try to remove the text by printing a `space` over it, I dont think it would work.

if you were to put the bit of code required into a `repeat/until` loop, then you will need to set a sync rate before the loop, and refresh the sync at the end of the loop, other wise the screen may stutter/ flash.

Simon

indi
21
Years of Service
User Offline
Joined: 26th Aug 2002
Location: Earth, Brisbane, Australia
Posted: 25th Nov 2002 02:52
instead of deleting the text or clearing the screen

set up a constant named variable for that text output.





DrakeX
21
Years of Service
User Offline
Joined: 26th Aug 2002
Location:
Posted: 25th Nov 2002 03:47
@Zooker: hmm well i think i've figured out from your rather umm sparse description than you're doing something in 2d.

well listen to simon

sync on : sync rate 60
do
cls
text 0,0,str$(rnd(100))
sync
loop

and there ya go.

i'm looking at yooooou!
Zooker
21
Years of Service
User Offline
Joined: 27th Oct 2002
Location: United States
Posted: 25th Nov 2002 07:30
Thanks for the Help fellas! You can't seem to do anything in DB without using the sync command but I think I'll try erasing the text with a Box statement!
Are You The Indi from the Old DB Forums. I think You and Magellan were Friends? He was a Good Programer Too!!

TheCyborg
21
Years of Service
User Offline
Joined: 6th Oct 2002
Location: Denmark
Posted: 25th Nov 2002 10:11
The SET TEXT OPAQUE command does not work with the print commend... only the Text and Center Text commands...
(In the case you did not know)

TheCyborg Development.
http://TheCyborg.Amok.dk
The Ultimate Source To DarkBASIC Programming.
indi
21
Years of Service
User Offline
Joined: 26th Aug 2002
Location: Earth, Brisbane, Australia
Posted: 25th Nov 2002 14:10
yes mate thats me good luck in your problem

Zooker
21
Years of Service
User Offline
Joined: 27th Oct 2002
Location: United States
Posted: 25th Nov 2002 20:46
TheCyborg !!
Thanks, I didn't know that and I would of thought that if it would of worked sooner with the print rather then the Text statement. Will Blunders never Cease!
Yo Indi!
If you ever talk to Magellan tell him I think his programing of that Menu system was a work of Art. I've been trying to modify it to work with keyboard commands but can't get to first base. I don't like Rats. Rats are MICE with a weight problem!

Login to post a reply

Server time is: 2024-03-03 02:44:29
Your offset time is: 2024-03-03 02:44:29