Author Topic: *Source included* A little demo I coded  (Read 1908 times)

0 Members and 1 Guest are viewing this topic.

Offline truup

  • Soldier
  • **
  • Posts: 243
*Source included* A little demo I coded
« on: August 03, 2007, 08:27:50 pm »
Here is a little demo I coded today. It's actually nothing special, a simple effect with chiptunes on it. They used to put intro's like this on the old cracked games on amiga, and other stuff.

For people who wants to know, it was coded in Freebasic. Freebasic is kind of a QBASIC clone, it doesn't have anything to do with Coolbasic, Realbasic or any other **** like that. You can get FreeBasic from http://freebasic.net

I'm planning on making it use SDL or TinyPTC, due to FreeBasic's build-in graphic functions being a bit slow. Then I also might add a plasma-effect on background, only if I figure out how it works, or if my friend gets it done. :P

* Note that it might do some flickering, if it does, please tell me and tell me also your computer's specs. *

As for the tune on it.. I didn't make it myself so I'm giving the link for it. I got it from http://www.chiptune.de/

Here is the sourcecode too. Note that it's modified version of the binary.
« Last Edit: August 04, 2007, 08:32:55 am by truup »

Offline rfreak

  • Soldier
  • **
  • Posts: 152
Re: A little demo I coded
« Reply #1 on: August 03, 2007, 08:43:36 pm »
It's a good start BRAVO! are you gonna make a little game for it?
R the coolest game ever

Offline truup

  • Soldier
  • **
  • Posts: 243
Re: A little demo I coded
« Reply #2 on: August 03, 2007, 09:08:11 pm »
It's a good start BRAVO! are you gonna make a little game for it?
Nah. :D Usually when making games you start by coding the game and then the intro. :P I'm still trying to do this little stuff for beginning, I'm not ready to make (big) games yet. :D Well, I've coded a snake but that's another story... I might change the variables and functions to english tomorrow, and release source too. :P

How ever, this is good training too. You have to optimate the code a bit to make it run smoother, do some FPS handling etc.. So it's basically like coding a game. :)

Offline rfreak

  • Soldier
  • **
  • Posts: 152
Re: A little demo I coded
« Reply #3 on: August 03, 2007, 09:13:19 pm »
I know all this but maybe you can start to do a small game after the intro
R the coolest game ever

Offline NinjaGimp369

  • Veteran
  • *****
  • Posts: 1474
  • Wa-Poww!
Re: A little demo I coded
« Reply #4 on: August 03, 2007, 10:49:38 pm »
Man, I love this music
"You should've used the pythagoras theorum, b*tch."
[/url]

Offline blackdevil0742

  • Veteran
  • *****
  • Posts: 1061
  • Don't Panic
Re: A little demo I coded
« Reply #5 on: August 03, 2007, 11:24:13 pm »
Awsome!

I really love these kind of graphics and music.

OBEY!!!

Offline Veritas

  • Camper
  • ***
  • Posts: 271
  • Waco
Re: A little demo I coded
« Reply #6 on: August 04, 2007, 01:22:01 am »
SDL = :D
FreeBasic = D:
DEHUMANIZE YOURSELF AND FACE TO BLOODSHED

Offline a-4-year-old

  • Veteran
  • *****
  • Posts: 1918
Re: A little demo I coded
« Reply #7 on: August 04, 2007, 06:50:17 am »
what was that purple beam of light for? i would have just apreciated like a space ship flying by with the banners behind it, you know, like those planes that fly by beaches?
If we hit the bullseye the rest of the dominoes will fall like a house of cards. Checkmate. -Zapp Brannigan

Offline blackdevil0742

  • Veteran
  • *****
  • Posts: 1061
  • Don't Panic
Re: A little demo I coded
« Reply #8 on: August 04, 2007, 07:01:26 am »
Iis the programing language easy to learn?

OBEY!!!

Offline truup

  • Soldier
  • **
  • Posts: 243
Re: A little demo I coded
« Reply #9 on: August 04, 2007, 07:43:33 am »
SDL = :D
FreeBasic = D:
Wtf? :D

what was that purple beam of light for? i would have just apreciated like a space ship flying by with the banners behind it, you know, like those planes that fly by beaches?
Heres the answer:
Awsome!

I really love these kind of graphics and music.

Iis the programing language easy to learn?
I'd say it is as easy as QBASIC is. QBASIC is a good language for beginners, and still powerful if programmer has got the skill. Most of the intros and demos were coded in some BASIC language for Amiga back at the old times. Well, FreeBasic is kind of "today's basic". :D

Offline Clawbug

  • Veteran
  • *****
  • Posts: 1393
  • 1184!
Re: *Source included* A little demo I coded
« Reply #10 on: August 04, 2007, 09:25:28 am »
I created something cool aswell! 8)

It is just plasmas in the background and a simple scroller with chiptune!. Pure 80's!


It WILL be slow on slow comps, I did not really pay attention to it when I created it, and now I am too lazy to start optimize it better. It uses frame dependent system for movement and other stuff. (It also needs faster drawing routine, the one included in FreeBASIC is SLOW compared to what it would be if the graphics data was written directly to memory and then flipped!)

Anyway, source code included aswell, written in FreeBASIC, just like truup's intro.

Fight! Win! Prevail!

Offline mxyzptlk

  • Veteran
  • *****
  • Posts: 1493
  • The Panda Ninja
Re: *Source included* A little demo I coded
« Reply #11 on: August 04, 2007, 09:29:34 am »
I remember apple basic, on my apple IIe, coding liitle simple "if... then...goto" scripts and seeing how they turned out. Is the syntax much like that of apple basic?
10
20
30
...

that kind of stuff?

"While preceding your entrance with a grenade is a good tactic in
Quake, it can lead to problems if attempted at work." -- C Hacking

Offline Clawbug

  • Veteran
  • *****
  • Posts: 1393
  • 1184!
Re: *Source included* A little demo I coded
« Reply #12 on: August 04, 2007, 09:51:32 am »
I remember apple basic, on my apple IIe, coding liitle simple "if... then...goto" scripts and seeing how they turned out. Is the syntax much like that of apple basic?
10
20
30
...

that kind of stuff?

Not really. Line numbers were quite abandoned in QBasic, though they were still usable. I am not quite sure about FreeBASIC though, but I guess they are not supported anymore.

I remember downloading some old GW-BASIC compiler and was like "WTF IS THIS....?" when I had to actually type line numbers and such.

There are some demos and intros made with GW-BASIC and QBASIC around though, fun to browse the code and guess how it works and stuff like that.
Fight! Win! Prevail!

Offline truup

  • Soldier
  • **
  • Posts: 243
Re: *Source included* A little demo I coded
« Reply #13 on: August 04, 2007, 09:52:56 am »
I remember apple basic, on my apple IIe, coding liitle simple "if... then...goto" scripts and seeing how they turned out. Is the syntax much like that of apple basic?
10
20
30
...

that kind of stuff?
Just check the sources. :) Though GOTO is pretty out-dated, and it is recommend to use Subs and functions instead of it.

Edit: Claw was faster. :(

Offline Clawbug

  • Veteran
  • *****
  • Posts: 1393
  • 1184!
Re: *Source included* A little demo I coded
« Reply #14 on: August 04, 2007, 09:55:27 am »
I remember apple basic, on my apple IIe, coding liitle simple "if... then...goto" scripts and seeing how they turned out. Is the syntax much like that of apple basic?
10
20
30
...

that kind of stuff?
Just check the sources. :) Though GOTO is pretty out-dated, and it is recommend to use Subs and functions instead of it.

Edit: Claw was faster. :(

Well, it is what, 20-30 years old method? Not *so* out-dated really! ;)

Enough of sarcasm. ;d
Fight! Win! Prevail!

Offline mxyzptlk

  • Veteran
  • *****
  • Posts: 1493
  • The Panda Ninja
Re: *Source included* A little demo I coded
« Reply #15 on: August 04, 2007, 09:57:46 am »
I was about 5 when I was coding it, cut me some slack ;)

Eh, I still might check Freebasic out.

"While preceding your entrance with a grenade is a good tactic in
Quake, it can lead to problems if attempted at work." -- C Hacking

Offline blackdevil0742

  • Veteran
  • *****
  • Posts: 1061
  • Don't Panic
Re: *Source included* A little demo I coded
« Reply #16 on: August 04, 2007, 11:19:17 am »
how does the program work. Do i write in the cmd?? That's all that opens when clicking the exe.

OBEY!!!

Offline Evil-Ville

  • Major
  • *
  • Posts: 55
  • Rerhüfmruts
Re: *Source included* A little demo I coded
« Reply #17 on: August 04, 2007, 11:20:05 am »
I've got a pile of Amiga disks behind my back right now with lots of demos and intros on them. None of them are even nearly this bad and I've got some obscure stuff there.
>:3

Offline truup

  • Soldier
  • **
  • Posts: 243
Re: *Source included* A little demo I coded
« Reply #18 on: August 04, 2007, 11:26:52 am »
how does the program work. Do i write in the cmd?? That's all that opens when clicking the exe.
It is meant for compiling sources only. You need to use another program to write the code, like Notepad or something. But I would recommend using an IDE, FBIDE seems to be the best IDE for FB this far, get it from http://fbide.freebasic.net

I've got a pile of Amiga disks behind my back right now with lots of demos and intros on them. None of them are even nearly this bad and I've got some obscure stuff there.
Good for you.