Computer Science Canada

some text testing

Author:  santabruzer [ Sat Jan 17, 2004 11:20 pm ]
Post subject:  some text testing

well i dunnu.. i wonder how to make this better.. so that it will display ... "faster"
code:
var ptext : string
var mx, my, mb : int
var font := Font.New ("courier:12")
setscreen ("offscreenonly")
ptext := "Santabruzer"
type loc :
    record
        x, y : int
        letter : string
    end record
var text : array 1 .. length (ptext) of loc
loop
    for decreasing i : length (ptext) .. 1
        mousewhere (mx, my, mb)
        text (i).x := mx + i * 20
        text (i).y := my + 20
        text (i).letter := ptext (i)
        for f : 1 .. 5
            Font.Draw (text (i).letter, text (i).x - f, text (i).y - (f div 2), font, 24 + f)
        end for
        Font.Draw (text (i).letter, text (i).x, text (i).y, font, 7)
        delay (5)
    end for
    View.Update
    cls
end loop


Author:  Boarder16 [ Sat Jan 17, 2004 11:22 pm ]
Post subject: 

whoa! Very Happy nice work dude, i dunno about any suggestions.. but the text looks to "stiff"... if it were more free flowing it'd be cooler.. but nice work! Razz

Author:  santabruzer [ Sat Jan 17, 2004 11:23 pm ]
Post subject: 

saw it on a website.. decided it was easy enough to make.. plust i can probably make a tutorial on record with this example.. Razz

Author:  AsianSensation [ Sun Jan 18, 2004 4:28 pm ]
Post subject: 

instead if clearing the screen, draw a white box that covers the words, that should increase efficiency a bit. Also, take out any delays, that will also make it "flow" better.

Btw, dodge had already made a tutorial with records, so if you want to make another and challenge the "whatdotcolor warrior" go right on ahead.

Author:  Andy [ Sun Jan 18, 2004 6:17 pm ]
Post subject: 

challange... pshhh go rite ahead Twisted Evil Twisted Evil

Author:  santabruzer [ Sun Jan 18, 2004 6:43 pm ]
Post subject: 

nah screw it.. it's been done.. ... i swear it wasn't there two weeks ago.. Razz ... i'll just keep on being the record warrior in my mind Very Happy

Author:  Andy [ Sun Jan 18, 2004 7:26 pm ]
Post subject: 

uhh dude... look at the date on that... it's been their for at least 2 months


: