Gameboy Development Forum

Discussion about software development for the old-school Gameboys, ranging from the "Gray brick" to Gameboy Color
(Launched in 2008)

You are not logged in.

#1 2016-04-18 18:36:59

rychan
Member
From: Paignton, Devon, UK
Registered: 2015-12-16
Posts: 103
Website

GBDK Tutorial code

So, I finally got around to writing up a GBDK demo ROM for people to build things off from tonight.

It's fully commented and covers most of the bases to get a simple game started off with. Tiles / Data grabbing, joypad input, collision and a tiny amount of sound. Just enough to give a flavour of gameboy to it.

Any comments would be welcome.

You can download the files from here:

https://refreshgames.co.uk/2016/04/18/g … orial-rom/

Offline

 

#2 2016-05-04 04:34:11

a cat
Member
Registered: 2014-07-27
Posts: 98

Re: GBDK Tutorial code

Seems perfect for beginners

Thanks for sharing!


a cat in need of knowledge!!

Offline

 

#3 2016-05-09 16:46:24

rychan
Member
From: Paignton, Devon, UK
Registered: 2015-12-16
Posts: 103
Website

Re: GBDK Tutorial code

No worries, any questions feel free to ask smile

Offline

 

#4 2016-05-12 04:53:18

LuckyLights
Member
Registered: 2014-07-06
Posts: 20

Re: GBDK Tutorial code

Cool stuff!

Offline

 

#5 2016-06-03 10:26:58

caseyweederman
New member
Registered: 2016-06-03
Posts: 2

Re: GBDK Tutorial code

Hi! What version of GBDK compiles this?
I get
#error SFR is untested and disabled in 2.96
when I run the first line in the batch file. If I take out the -DUSE_SFR_FOR_REG, I get
/opt/gbdk/bin/lcc: fatal error in /opt/gbdk/bin/sdcc
I'm using https://github.com/gheja/gbdk

Thank you for all your hard work!

Offline

 

#6 2016-06-06 07:39:15

rychan
Member
From: Paignton, Devon, UK
Registered: 2015-12-16
Posts: 103
Website

Re: GBDK Tutorial code

I'll check once I'm, back home and get back to you casey, sorry to hear you're having difficulties compiling.

Offline

 

#7 2016-06-06 17:05:07

rychan
Member
From: Paignton, Devon, UK
Registered: 2015-12-16
Posts: 103
Website

Re: GBDK Tutorial code

gbdk3-2.93 - http://gbdk.sourceforge.net/
-----------------------------------------
This is a early-release beta.  Please report any bugs smile

Looks like I'm running an older version, eep!

Offline

 

#8 2016-09-07 03:31:10

WHOKILLEDKENNY
New member
From: China SDU
Registered: 2016-08-17
Posts: 2

Re: GBDK Tutorial code

rychan wrote:

So, I finally got around to writing up a GBDK demo ROM for people to build things off from tonight.

It's fully commented and covers most of the bases to get a simple game started off with. Tiles / Data grabbing, joypad input, collision and a tiny amount of sound. Just enough to give a flavour of gameboy to it.

Any comments would be welcome.

You can download the files from here:

https://refreshgames.co.uk/2016/04/18/g … orial-rom/

Hi rychan! I noticed there are actually five different tile patterns ---- with the first tile being totally blank! Thus the correct one should be rand()%5, rather than rand()%4, to make a starry background. I examined the program and found the "X" shaped tile was actually omitted in the random background, which I believe  should be a little mistake. smile

Offline

 

#9 2016-09-24 19:23:26

rychan
Member
From: Paignton, Devon, UK
Registered: 2015-12-16
Posts: 103
Website

Re: GBDK Tutorial code

Thanks for the message WHOKILLEDKENNY. I'll updat the code once my new website has come to fruition.

Offline

 

#10 2016-10-10 02:47:17

Mills
Member
Registered: 2012-12-21
Posts: 132

Re: GBDK Tutorial code

Love it!

Offline

 

#11 2017-01-18 02:16:39

npzman
Banned
From:
Registered: 2014-11-19
Posts: 197

Re: GBDK Tutorial code

rychan can you make video on how to develop with the GBDK


Twitter : @Sfeedman please follow
Join : sfeed.club my website please join

Offline

 

#12 2017-01-19 08:08:19

npzman
Banned
From:
Registered: 2014-11-19
Posts: 197

Re: GBDK Tutorial code

and teach me


Twitter : @Sfeedman please follow
Join : sfeed.club my website please join

Offline

 

#13 2017-02-19 18:39:21

rychan
Member
From: Paignton, Devon, UK
Registered: 2015-12-16
Posts: 103
Website

Re: GBDK Tutorial code

I might try to make a video at some point in the future but work and family commitments means I have little time for things currently. It would be cool to go througgh a simple game step - by - step though.

Offline

 

#14 2017-02-23 14:50:47

Heigw
Member
From: Michigan-United States
Registered: 2017-02-22
Posts: 14

Re: GBDK Tutorial code

Yeah, that would be cool.  I found one series of tutorials for the gameboy.  It was quite informative, but they move slowly.  Its good for beginners (me).


I've just started coding in C for the gameboy.  Any help or tutorials would be greatly appreciated.

I am making a game that is an "Interactive Story."  If think you could help in any way or want to check on the progress here is the ROM and source-code.
Story Time... With Uncle Heigw: http://www.filedropper.com/story_2

Offline

 

Board footer

Powered by PunBB
© Copyright 2002–2005 Rickard Andersson