It is currently Mon Oct 20, 2014 4:46 pm

All times are UTC [ DST ]




Post new topic Reply to topic  [ 129 posts ]  Go to page Previous  1 ... 3, 4, 5, 6, 7  Next
Author Message
PostPosted: Sat Feb 01, 2014 8:28 pm 
Offline
 Profile

Joined: Mon Jul 21, 2008 9:29 pm
Posts: 25
I did think about hacking an emulator but decided to have a look at grabbing the MIDI files first. I've used AmazingMIDI to convert the WAV files into MIDI and it seems to work quite well.


Top
 
PostPosted: Tue Feb 04, 2014 7:35 pm 
Offline
User avatar
 Profile

Joined: Sat Mar 26, 2011 3:01 pm
Posts: 263
Location: Kings Langley
Finally got around to adding joystick support - took about 50 bytes, but after another tidy up, I still have about 100 bytes in the main area and about 40 in a couple of blocks in page2.

Not tested on HW, and I am ignoring the interrupt!

ADCStartConv = &FEC0 \\ WO xxxxm0cc Mode 0:8 1:10 bit conv, Channel - write to reg to start conversion
ADCStatusReg = &FEC0 \\ RO db76mxcc Done:0 not:1, Busy:0 not:1 MSb76 of conv, Mode, Channel

.read_joystick
{
lda SysViaRegB : and #&10 \\ joy 0 fire (0=pressed, 1=up)
...
bit ADCStartConv : bmi done : bvc done \\ not complete / busy
lda ADCStatusReg \\ bits45 are MSBits 0=fullish-right, 1,2 near middle, 3=fullish-left
...
.done
ldx #0 : stx ADCStartConv \\ start new 8bit conversion on channel0 (joy0 left-right)
rts
}


Top
 
PostPosted: Tue Feb 04, 2014 7:59 pm 
Offline
User avatar
 Profile

Joined: Mon Jan 07, 2008 6:46 pm
Posts: 380
Location: Málaga, Spain
Don't forget to self-modify the I/O address in your initialisation if it's a Master. It lives somewhere different, annoyingly!


Top
 
PostPosted: Tue Feb 04, 2014 9:55 pm 
Offline
 Profile

Joined: Mon Jul 21, 2008 9:29 pm
Posts: 25
And it's done completely differently on the Compact :)


Top
 
PostPosted: Tue Feb 04, 2014 11:39 pm 
Offline
User avatar
 Profile

Joined: Mon Jan 07, 2008 6:46 pm
Posts: 380
Location: Málaga, Spain
Is it? It's not just that the ADC moved house?


Top
 
PostPosted: Wed Feb 05, 2014 9:22 am 
Offline
User avatar
 Profile

Joined: Mon Jan 07, 2008 7:02 pm
Posts: 273
Master Compact has a digital joystick wired to what was the user port.


Top
 
PostPosted: Wed Feb 05, 2014 5:52 pm 
Offline
User avatar
 WWW  Profile

Joined: Thu Apr 03, 2008 2:49 pm
Posts: 277
Location: Antarctica
Yes, that caught me out right at the end.. what I did was patch the joystick routine if running on a compact ..


Top
 
PostPosted: Thu Feb 06, 2014 11:16 am 
Offline
User avatar
 Profile

Joined: Mon Jan 07, 2008 6:46 pm
Posts: 380
Location: Málaga, Spain
Oh-oh... really? Got any info on that? I didn't have a clue, quite honestly.


Top
 
PostPosted: Thu Feb 06, 2014 6:54 pm 
Offline
User avatar
 Profile

Joined: Mon Jan 07, 2008 7:02 pm
Posts: 273
&FE60 :
bit 0 - fire
bit 1 - left
bit 2 - down
bit 3 - up
bit 4 - right
bits 5-7 - haven't a clue
All active low.

I wouldn't worry too much, it's not like anyone actually owns a Compact.


Top
 
PostPosted: Thu Feb 06, 2014 7:35 pm 
Offline
User avatar
 Profile

Joined: Mon Jan 07, 2008 6:46 pm
Posts: 380
Location: Málaga, Spain
Haha, cheers Tom!


Top
 
PostPosted: Fri Feb 07, 2014 8:05 pm 
Offline
 Profile

Joined: Mon Jul 21, 2008 9:29 pm
Posts: 25
TomW wrote:
I wouldn't worry too much, it's not like anyone actually owns a Compact.

I do! With a GoSDC inside, it makes a really portable games machine :)


Top
 
PostPosted: Wed Mar 19, 2014 8:08 am 
Offline
User avatar
 Profile

Joined: Sat Mar 26, 2011 3:01 pm
Posts: 263
Location: Kings Langley
TomW wrote:
&FE60 :
bit 0 - fire
bit 1 - left
bit 2 - down
bit 3 - up
bit 4 - right
bits 5-7 - haven't a clue
All active low.

I wouldn't worry too much, it's not like anyone actually owns a Compact.


I'm having a bit of a problem, all I get at &FE60 is 0, no matter what I set &FE62 to


Top
 
PostPosted: Wed Mar 19, 2014 8:55 am 
Offline
User avatar
 Profile

Joined: Sat Mar 26, 2011 3:01 pm
Posts: 263
Location: Kings Langley
Sorry, false alarm, it works fine, I was just overwriting some other code when selecting between joysticks.

I am trying to run on B-em in master compact mode, it works, but my BASIC programs just come up with file not found, any ideas?

I also tried using the DFS image of the welcome disk, but that also has problems.
I guess they have the wrong load/run address or something.


Attachments:
master-compact-file-not-found.jpg
master-compact-file-not-found.jpg [ 73.58 KiB | Viewed 111 times ]
Top
 
PostPosted: Sun Apr 27, 2014 11:46 am 
Offline
User avatar
 Profile

Joined: Sat Mar 26, 2011 3:01 pm
Posts: 263
Location: Kings Langley
For those that missed the sneak peek at EGX Rezzed (NEC), or the official release at the Acorn and RISC OS show at Wakefield, here is my nearly final version of Carnivale (now with an added e to match the old school (C) renaming).

Attachment:
File comment: Near final version of Carnivale (two bugs remaining)
carnivale.zip [19.81 KiB]
Downloaded 18 times


To build with beebasm from source, see links at the bottom of this post.

There seems to be two bugs remaining:

1. If you hit a falling duck, just wrong, the bullet gets left behind.
2. Somehow the palette gets corrupt including the background going white.

If anyone catches a video of this, or can spot the bug in the code, I would be very happy.

Here is a brief summary of my Carnivale project (hopefully it will get moved to a project page).

The game carnival came out in 1980 in the arcades. You control a gun at the bottom of the screen and try to shoot all the targets scrolling horizontally across the middle of the screen before you run out of bullets. There are some "pipes" at the top of the screen, which must be shot before you can move on to the "bonus" round where you shoot a bear, which changes direction each time you shoot it. As you play the main game and bonus rounds they get faster, with "ducks" occasionally flying down the main game screen to eat your bullets if they get to the bottom.
To get a "maximum" score, you need to shoot all pipes first without missing any shots or hitting anything else, then all the ducks, bears and rabbits as they move along the top row. Finally, shoot the letters "B", "O", "N", "U", "S" in that order. There are also bonus bullet targets (which disappear after the middle row) and a bonus/penalty box that appears on the top left.

My project started as most of my programming projects do with an idea for how I could do a "tricky" part of a game in a time or memory (or sometimes both) efficient way. With Carnivale, it was an idea for how to draw the main targets (13, each 3x2x8 bytes in MODE1) quickly enough to not flicker. If I hadn't put a demo on viewtopic.php?f=19&t=877, that would probably have been the end of it.
The demo pixel scrolled the top and bottom rows of targets to the right with the middle row going left, but leaving trails and not drawing correctly. With a few kind words from RobC and DaveM, I felt enthusiastic enough to add a bit more (mostly just hiding the dodgy middle row).

More kind words from jbnbeeb and off I went to run Carnival on MAME, capture a video and write some C code on the PC to grab the differences between frames of the "pipes" animating. I added a bit more to "generate" the 6502 to draw the pipes in the smallest amount of time and memory, but allow changing the colours of the pipes because I could only fit four frames of each.
More words of encouragement, this time from simonh and oss003 and hitting pipes was in. There was a suggestion that I add master support to use the extra memory as I was already running out. I've only had BBC-Bs and didn't really feel the love for the others, so I decided to kick out the OS, DFS and BASIC and go straight to the metal to free up more memory (later, this would make saving hi-scores a problem).

While I was looking at the video from MAME, I noticed that the original game moved sprites two pixels at a time and ran at 25Hz, this made me feel much better about the effort I had gone to to move single pixels at 50Hz.

With scoring in (including pipes bonus, but not double for hitting opposite pipes with consecutive shots), the middle row behaving (mostly) and ducks now falling, I was feeling quite good about the progress I had made in only a couple of weeks, despite some blood pressure issues. More encouragement, DavidB and DaveM and some suggestions to add more colour (well swapping white for cyan) which I wasn't thrilled with at first, because to me, red owls, white rabbits, yellow ducks and black background were the main colours.

As week three came and went and I added shooting falling ducks, bullet eating and end of level, I ran out of memory a couple of times and had to steal a bit more from the system, I realised that I wouldn't be able to save the hi-scores even if I added them.

With Christmas fast approaching, I tried to get the music in, this nearly drove me mad and I suspect frustrated DaveM, RobC, DaveF and PitfallJ, all who tried to help me get the music right. I learnt much more about MIDI and how various emulators support sound chips from the 8 bit days than I ever wanted to.

Over Christmas, I grabbed a video of the bears and wrote another program to generate the bonus round's bear's code and data; this involved as with the pipes finding matching 8 bytes blocks so that I could draw them without having to have full copies of each sprite for each frame.

As January started, DaveM was giving me lots of suggestions/encouragement and then RichTW joined in with the encouragement and saved me quite a bit of time finding more places to "steal" memory and oh yes, suggesting more colours. More encouragement from RichTW, DaveM and jbnbeeb gave me the push I needed to add a hi-score table, although I didn't think I would have enough memory to display it!

Then for a while everyone kept telling me that the music was broken, I had no idea what was wrong as I have always been useless with music despite my father being able to play anything and my sister being an excellent singer. DaveM put up a video of "Karnival" playing on his "PC in an arcade cabinet" and I could see/hear what they meant, which gave me another push, just when the music had nearly killed my interest in the project.

I was still thinking at this point of doing a BBC themed version with BBC related graphics. eg swap the owl for the one from the "BBC MICRO" programs, maybe use Chuckie Egg's duck etc. I wanted to add a second player and allow co-operative multi-player, that is, a second gun facing the other way and shooting on the odd pixels, as the first only shoots on the even ones. At this point, I realised that my enthusiasm for the project was going to run out before it was finished and that seemed a shame.

DevidB commented that my game was "much more polished" than Acornsoft's Carousel and I wasn't sure whether that was good or bad - sorry DavidB. trevj, did you ever get round to comparing Carnivale (as it is now called) to Carousel?

Three quarters of the way through Jan and I was sure DaveM had said that RetroSoftware might want to release it, but as he was away working, I wasn't sure what that meant for further releases on the forums, so there weren't any until now ;)

oss003, I never got around to doing that developer diary, but I hope this goes some way to compensating. I plan to explain parts of the code, hopefully to encourage others to do a bit more on some of their projects when (if) I get a project page.

More sound woes with various people trying to help; thanks RobC, I won't get around to adding SID support, but maybe you or someone else would consider adding it? I grabbed the MAME audio and my audio and compared the waveforms and saw what my ears could not; the pitch was wrong and with a time line, I could see by how much; fixing this made the music sound just right.

Time to add joystick support, thanks TomW for the pointers. I didn't really do much for a month or so and then DaveM got in contact and spurred me on to start the final straight. Apart from some sloppy coding, joystick support for B/master/compact was quite easy: do an OSBYTE 0 (*fx0) to get the OS and imply the joystick type from their (copy the appropriate routine over the default (longest) one.

For many weeks, I haven't been putting anything on the forums about Carnival, so DaveM has had to do all the encouraging and play-testing while I tried to fix the last couple of issues, get the hi-score working and add a bit more colour (now has all colours in MODE1 – 9 on a slow lcd).

The arcade version had a high score of 29 names, but I think you could only ever see the top three. I started with a hi-score of 30 entries, which I keep near the bottom of the stack and then when you "re-boot", look for a signature and save/load/re-create as appropriate. There isn't a "safe" area to keep the hi-score and I have no room to do a *SAVE, so I have reduce the number of entries to 21 and trimmed the signature. What is left works on most of the config's that I have tried, but not on all (eg compact).

DaveM took it to Rezzed over the weekend and apart from there still being a couple of infrequent bugs, says that it went down well. Hopefully I will make it to Wakefield for its official launch, although it is quite a way from Hertfordshire where I live.

I have now pretty much stopped work on it, although, I will fix any bugs that I can reproduce and help with any work anyone else wants to do on it.

I'm fairly keen to get on with the next project, maybe an "updated" version of Rally-X or possibly a version of Super Mario Bros (Imogen is now asking for Frogger, but I think there are already quite a few good versions – although, it does have rows of scrolling things ;-) - I'm not very creative; although I can code when I have to ;-)

Carnival has a basic program LOADER, which saves/loads/re-creates the hi-scores and allows selection of Z/X/RETURN, joystick or redefining the keys, this could do with some love, as could the key redefinition program – volunteers?

That's all for now, except to thank everyone who uses RetroSoftware or supports it by buying games for allowing Dave to keep the site going and encouraging people like me to make projects like Carnivale.

To build with beebasm, download the .ssd template and the source code below and then use this command line:

beebasm.exe -i carnival.asm -do carnivale.ssd -di template.ssd -v

Attachment:
File comment: asm and include files for building Carnivale with beebasm
source_code.zip [32.01 KiB]
Downloaded 11 times

Attachment:
File comment: template file for .ssd with loader, marquee and key redefinition (plus bonus key combination checker)
template.zip [10.94 KiB]
Downloaded 9 times


Top
 
PostPosted: Sun Apr 27, 2014 12:46 pm 
Offline
User avatar
 WWW  Profile

Joined: Wed Jan 26, 2011 2:35 am
Posts: 139
tricky wrote:
DevidB commented that my game was "much more polished" than Acornsoft's Carousel and I wasn't sure whether that was good or bad - sorry DavidB. trevj, did you ever get round to comparing Carnivale (as it is now called) to Carousel?

It is most definitely a good thing. :) Sorry if that was unclear. Your version seems to have much more depth than the Acornsoft version.


Top
 
PostPosted: Sun Apr 27, 2014 1:19 pm 
Offline
User avatar
 Profile

Joined: Sat Mar 26, 2011 3:01 pm
Posts: 263
Location: Kings Langley
DavidB wrote:
tricky wrote:
DevidB commented that my game was "much more polished" than Acornsoft's Carousel and I wasn't sure whether that was good or bad - sorry DavidB. trevj, did you ever get round to comparing Carnivale (as it is now called) to Carousel?

It is most definitely a good thing. :) Sorry if that was unclear. Your version seems to have much more depth than the Acornsoft version.


Sorry, I wasn't complaining about your comment. I was really being a bit rude about carousel :o


Top
 
PostPosted: Sun Apr 27, 2014 1:52 pm 
Offline
 Profile

Joined: Sun Apr 27, 2014 12:48 pm
Posts: 2
I have to say, I thought the game looked very impressive at the Wakefield show.
Very smooth and very colourful.

If you want ideas of what to do next, I have many ideas...
You could do a more colourful version of Quazatron (ZX spectrum)
Or convert R-type (and please don't anyone say 'but we have Nevryon' as if that's some kind of substitute)
The Trapdoor
Ghostbusters
Rainbow Islands (didn't someone start that a while ago?)
outrun (even forgot the capital letter in my haste to type)
or even... Wait for it, wait for it.....
Wonderboy III the Dragons trap (is this even technnically possible?)

But seriously, thanks for doing such a great job on Carnivale. Very impressive.
Cheers!


Top
 
PostPosted: Sun Apr 27, 2014 1:58 pm 
Offline
User avatar
 WWW  Profile

Joined: Wed Jan 26, 2011 2:35 am
Posts: 139
tricky wrote:
Sorry, I wasn't complaining about your comment. I was really being a bit rude about carousel :o

How naughty! :lol:


Top
 
PostPosted: Sun Apr 27, 2014 2:03 pm 
Offline
User avatar
 WWW  Profile

Joined: Wed Jan 26, 2011 2:35 am
Posts: 139
fwibbler wrote:
Rainbow Islands (didn't someone start that a while ago?)
outrun (even forgot the capital letter in my haste to type)

Rainbow Islands is a cute little game, but I used to think that about Bubble Bobble, too. 8-)

I know it's nothing like Outrun, but E-Type isn't at all bad, at least for the Electron.

It might be interesting to look at games in genres for which the Acorn 8-bit machines have very little coverage. Games like Rescue on Fractalus! spring to mind.


Top
 
PostPosted: Sun Apr 27, 2014 4:20 pm 
Offline
User avatar
 Profile

Joined: Sat Mar 26, 2011 3:01 pm
Posts: 263
Location: Kings Langley
fwibbler wrote:
Or convert R-type


Tried that before http://www.retrosoftware.co.uk/wiki/index.php/ProjectsInDevelopment#Jeltron_by_Richard_Broadhurst_and_Gil_Jaysmith


Top
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 129 posts ]  Go to page Previous  1 ... 3, 4, 5, 6, 7  Next

All times are UTC [ DST ]


Who is online

Users browsing this forum: No registered users and 0 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron