
-----------------------------------
mike200015
Mon Jan 24, 2005 7:08 pm

Help with changing text colours
-----------------------------------
I made this little program, which is an addition to one of my programs. what it is, is an imitation loading bar when a program is loading, there is a number tht counts up as the bar fills in with black, i wnt to put the number in the bar, and when the black goes over the number, i want the number to change to white so you can still see it. if anyone knows how and can help id appreciate it .. thank you. here is the loading bar code.:

var x3 : int := 200
drawbox (200, 200, 400, 220, black)
for i : 0 .. 100
    drawfillbox (200, 200, x3, 220, black)
    locate (11, 34)
    put "Loading..", i, "%"
    x3 += 2
    delay (150)
end for


-----------------------------------
Delos
Mon Jan 24, 2005 7:20 pm


-----------------------------------

colour (7)
put "Hello"
colour (0)
put "World"
colour (14)
put "Meh"


-----------------------------------
cycro1234
Mon Jan 24, 2005 7:30 pm


-----------------------------------
Or u can make an if statement that checks to see if the bar is past a certain point, then change the colour to white.

-----------------------------------
cycro1234
Mon Jan 24, 2005 7:49 pm


-----------------------------------
Why are you flaming me?  :cry: 

I bet if...if...if you told Bill Gates that, he wuda never invented Microsoft!!!

-----------------------------------
compuwiz
Mon Jan 24, 2005 8:02 pm


-----------------------------------
I bet if...if...if you told Bill Gates that, he wuda never invented Microsoft!!!
well that's fine.....good reason to go back in time to send this stuff to bill gates.... :D

-----------------------------------
cycro1234
Mon Jan 24, 2005 8:37 pm


-----------------------------------
Don't spam the help section!

-----------------------------------
ste_louis26
Mon Jan 24, 2005 9:09 pm


-----------------------------------
you could also use the what dotcolour command to find that point before you switch the text to white and . . . . .  .robert do u have a life?

-----------------------------------
ste_louis26
Mon Jan 24, 2005 9:13 pm


-----------------------------------
Cound't you just have red or something to start with instead of changing it from black to white. It's a lot easier. Grey would do good.

-----------------------------------
basketball4ever
Tue Jan 25, 2005 1:02 am


-----------------------------------
    var col :int := 20
    var introline : string := "Hello mr.anderson ??? ."
    for a : 1 .. length (introline)
        colour (col)
        locate (10, a + 20)
        put introline (a) ..
        delay (100)
        col := col + 3
    end for
    loop
        exit when hasch
    end loop

-----------------------------------
ste_louis26
Tue Jan 25, 2005 12:12 pm


-----------------------------------
You also have to reposition the bar so that it falls on the line of the say's loading (locate is by characters so it isn't as flexable as pixals.)Do you want to change letter by letter or just the entire word.

-----------------------------------
gladiator_889
Tue Jan 25, 2005 12:39 pm


-----------------------------------
Ruben sucks!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! :lol:  :lol:  :lol:  :lol:  :lol:  :lol:  :lol:  :lol:  :lol:  :lol:  :lol:  :lol:  :lol:  :lol:  :lol:  :twisted:  :lol:  :twisted:  :lol: :twisted:  :lol:  :twisted:  :lol: :twisted:  :lol:  :twisted:  :lol: :twisted:  :lol:  :twisted:  :lol: :twisted:  :lol:  :twisted:  :lol: :twisted:  :lol:  :twisted:  :lol: :twisted:  :lol:  :twisted:  :lol: :twisted:  :lol:  :twisted:  :lol: :twisted:  :lol:  :twisted:  :lol: :twisted:  :lol:  :twisted:  :lol: :twisted:  :lol:  :twisted:  :lol: :twisted:  :lol:  :twisted:  :lol: :twisted:  :lol:  :twisted:  :lol: :twisted:  :lol:  :twisted:  :lol:

-----------------------------------
basketball4ever
Tue Jan 25, 2005 12:42 pm


-----------------------------------
spam.... stop spamming x_X

-----------------------------------
ste_louis26
Tue Jan 25, 2005 12:42 pm


-----------------------------------
don't spam the help section
