Where do I begin!?

Started by cmunoz, July 23, 2011, 07:25:49 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.


I'm new to Bennu, I have some experience coding games in actionscript 2, but have no idea how to get started in Bennu.
I downloaded the runtime, and all I can get it to do is show me a dos-like command prompt which closes itself whenever I try to press any key, as it suggests I do. I found one tutorial on how to move a ball around the screen using WSAD keys, but it's just a list of code, without any indication of what to do with the code (it won't paste into that command prompt, and I tried saving it as a text file, but when I dragged the text file onto the command promt, it said it needed a dll file for my code)
So basically, before I can even attempt to write code, I have to figure out WHERE to put the code.
The "beginner tutorial" on the bennugd.org website seems to not exist.
I would greatly appreciate any help on how to get up and running.
Thank you.


I found this thread:

and I'll start by giving that a try.
Thanks again.


Bennu is a commandline compiler, wich compile your source program into a bytecode (dcb) file wich has to be run with bgdi.

Basically open a dos propmt and type: bgdc helloworld.prg
                                                    bgdi helloworld.dcb

That's the rough basics.
O, your program has to include the modules you use, the so called "mod_<whatever>.dll" files.
To print text onto the dos prompt, you include mod_say, with the import statement.



You may find EXTREMELY OLD/EARLY bits and peices of code for my platform game on the forum, study from that.



Myself learned all I know about Bennu script from the online documentation. It's just a matter of using a bunch of processes and functions which I guess could be looked at like objects. Processes runs in parallel with each other and a function freezes its parent caller until end of execution of the function.

[code language="bennu"]process player(x,y) //This would be your player "object"
file=my_gfx_file; //Loaded in a global variable with load_fpg() or load_png()
graph=1; //The index of the player sprite
repeat //Make a loop to continue reading key inputs
if(key(_right)) x++; end //Move right
if(key(_left)) x--; end //Move left
until(key(_esc)) //Break the loop when key esc is pressed
ley_me_alone(); //Kills any other running processes


download bennupack ..

tools+examples+tutorials+links and moreeeee...