PDA

View Full Version : TBGL Easter Egg in a basket



dcromley
13-04-2009, 05:29
This is maybe my 5th post. It's late -- Easter is almost over even here in Wyoming.
I'm a retired mainframe (IBM mainframes) systems programmer. I still like to play with
math and programming, mostly Word and Excel macros in VBA. I don't see how people
can keep up with what's going on in the programming world. It's too much.

Anyway, I like graphics, and I worked my butt off getting this program done by Easter.
Barely made it. (It's tomorrow in a large part of the world). Of course, I copied from
the Examples a lot. It has some things I want to improve, so I'm just putting it on my
website. That's probably the best place anyhow. I enjoyed it, I hope you do.
You need the .tbasic file and the .bmp texture file.

http://dkcromley.inoutbox.com/dceasterbasket.tbasic
http://dkcromley.inoutbox.com/weave.bmp

Lower case is important. (Not on all sites, right?) Regards, Dave

kryton9
13-04-2009, 06:55
Happy Easter dkcromley.

I rar'd which is like zipping up the two files, makes it easier perhaps to download and run.

Nice to have another coder interested in graphics, thanks for sharing your hard worked example.
I got my Easter egg now :)

ErosOlmi
13-04-2009, 08:04
Thanks a lot Dave for this application.
I checked you code: very nice and precise way of programming. Great, I like it a lot

If I can, I have only one indication about the source: the use of CALL statement is not necessary if you just want to execute a named function. In this case only indicate the function name. It is a little faster without the CALL statement.

The main reason why I've developed CALL is to be able to call script functions whose name is not known at run-time and can be computer on the fly as a string expression. Check CALL (http://www.thinbasic.com/public/products/thinBasic/help/html/call.htm) help and see examples to see what I mean.

Thanks again for this very nice present.
Ciao
Eros

Petr Schreiber
13-04-2009, 08:35
Very nice! :)

Michael Hartlef
13-04-2009, 08:38
Nice script Dave, thanks for sharing. :eusaclap:

TBGL_BuildFont should only be called once, outside your loop. And then you need to correct the position you print the text.

dcromley
13-04-2009, 17:21
Thanks.

I especially appreciate the code improvement comments.

>Posted by: Michael Hartlef
>And then you need to correct the position you print the text.
That was debug text that I just didn't remove. And I would've made a 800x600 window
instead of 1024x768 if I'd remembered to. Was the text in the upper left for you?

>Posted by: kent sarikaya
>I rar'd which is like zipping up the two files, makes it easier ..
Yes, I thought of that. I've only used the LHA zipper which dates back to 1991 but I
really like. It also makes a nice *.exe package, but I guess that's a poor idea for
security. Is ZIP common here? LHA?

Have a good week. Dave

ErosOlmi
13-04-2009, 17:47
ZIP is more diffuse bur RAR is ok too.
LHA ... mmmm the risk is no one will get your code.

If you want to attach files to posts, click on "Additional Options" just below text area.

Ciao
Eros