Jump to content

Captain Spazer

Members
  • Content Count

    110
  • Joined

  • Last visited

Community Reputation

31 Excellent

About Captain Spazer

  • Rank
    Chopper Commander

Profile Information

  • Gender
    Male
  • Interests
    Retro videogames ofcourse!
  • Currently Playing
    Mike Tyson's Punch Out & Pitfall 2
  1. Ahh, thank you. Note to self, write things down!
  2. I managed to compose a small victory tune, but I can't seem to trigger it correctly, I only get a buzzing noise, any thoughts? techdemo.bin rem Generated 04-02-2019 16:06:57 by Visual bB Version 1.0.0.568 rem ********************************** rem *<filename> * rem *<description> * rem *<author> * rem *<contact info> * rem *<license> * rem ********************************** set smartbranching on dim duration=y dim rand16=z player1x = 100 : player1y = 80 missile1x = 134 : missile1y = 80 player0x = 10 : player0y = 80 ballx = 109 : bally = 79 ballheight = 2 dim _P0_Left_Right = player0x.c dim _P0_Up_Down = player0y.d const pfscore = 1 pfscore1 = 21 rem * Volume off AUDV0=0 AUDV1=0 rem * Initialize duration and set up music duration = 1 goto MusicSetup dragonlevel pfscorecolor = $0E COLUPF = $DC COLUP0 = $1C scorecolor = $0E if g = 0 then playfield: ................................ ................................ ................................ ........................X.X.X... .......................X.X.X.X.. ......................X.......X. ................................ ................................ XX.............................. X............................... XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX end rem little caveman walk animation if b = 5 then player0: %01000000 %00100000 %00011110 %00011000 %00111110 %01000000 %00011000 %00011000 end if b = 10 then player0: %00000100 %00001000 %01111000 %00011110 %00011000 %01100000 %00011000 %00011000 end rem dino idle if a = 0 then player1: %00011111 %00001010 %00001010 %00001010 %00001010 %00001010 %00001010 %00001100 %00001000 %00001100 %00111110 %00111010 %00001110 %00000000 %00000000 %00000000 end rem dino eat if a = 1 then player1: %00011111 %00001010 %00001010 %00001010 %00001010 %10101010 %10101010 %10101100 %11111000 %10110000 %11100000 %00000000 %00000000 %00000000 %00000000 %00000000 end rem dino looks away if a = 2 then player1: %00011111 %00001010 %00001010 %00001010 %00001010 %00001010 %00001010 %00001100 %00001000 %00011000 %00111110 %00101110 %00111000 %00000000 %00000000 %00000000 end rem dizzy dino if h = 1 then player1: %00011111 %00001010 %00001010 %00001010 %00001010 %00001010 %00001010 %00001100 %00001000 %00011000 %00111110 %00101110 %00111000 %00000000 %00101000 %00010000 end f = f+ 1 if f = 60 then a = (rand&3) if f > 60 then f = 0 NUSIZ1 = $37 if b > 10 then b = 0 drawscreen rem little caveman move if e = 0 && k = 0 && j < 2 && joy0right then _P0_Left_Right = _P0_Left_Right + 0.50 : b = b + 1 : d = 0 if e = 0 && k = 0 && j < 2 && joy0left then _P0_Left_Right = _P0_Left_Right - 0.50 : b = b + 1 : d = 1 if d = 0 then REFP0 = 0 if d = 1 then REFP0 = 8 rem throw axe if d = 0 && e = 0 && i = 0 && k = 0 && pfscore1 > 0 && joy0fire then e = 1 : pfscore1 = pfscore1/4 if e = 1 then missile0x = player0x : missile0y = player0y : e = 2 if e = 2 then missile0x = missile0x + 2 : missile0y = missile0y - 2 if missile0y < 20 then missile0x = 200 : missile0y = 200 : e = 0 : d = 0 if missile0x > 140 then missile0x = 200 : missile0y = 200 : e = 0 : d = 0 rem dino is stunned if hit if collision(missile0,player1) then h = 1 : missile0x = 200 : missile0y = 200 : score = score + 30 if h = 1 then i = i + 1 if i = 60 then h = 0 : i = 0 if h = 1 then COLUP1 = rand if h = 0 then COLUP1 = $C2 rem steal the egg if collision(player0,ball) then j = 1 if j = 1 then ballx = player0x : bally = player0y - 4 if j = 1 && collision(ball,playfield) then j = 2 if j = 2 then goto GetMusic GotMusic rem dino eats player if a = 1 && collision(player0,player1) then k = 1 if k = 1 then player0x = 119 goto dragonlevel rem ***************************************************** rem * Music rem ***************************************************** GetMusic rem * Check for end of current note duration = duration - 1 if duration>0 then GotMusic rem * Retrieve channel 0 data temp4 = sread(musicData) temp5 = sread(musicData) temp6 = sread(musicData) rem * Check for end of data if temp4=255 then duration = 1 : goto MusicSetup rem * Play channel 0 AUDV0 = temp4 AUDC0 = temp5 AUDF0 = temp6 rem * Retrieve channel 1 data temp4 = sread(musicData) temp5 = sread(musicData) temp6 = sread(musicData) rem * Play channel 1 AUDV1 = temp4 AUDC1 = temp5 AUDF1 = temp6 rem * Set duration duration = sread(musicData) goto GotMusic rem ***************************************************** rem * Music Data Block rem ***************************************************** rem * Format: rem * v,c,f (channel 0) rem * v,c,f (channel 1) rem * d rem * rem * Explanation: rem * v - volume (0 to 15) rem * c - control [a.k.a. tone, voice, and distortion] (0 to 15) rem * f - frequency (0 to 31) rem * d - duration MusicSetup sdata musicData = x 8,4,27 0,0,0 15 2,4,27 0,0,0 8 8,4,24 0,0,0 9 2,4,24 0,0,0 8 8,4,20 0,0,0 9 2,4,20 0,0,0 8 8,4,18 0,0,0 9 2,4,18 0,0,0 8 8,4,20 0,0,0 11 8,4,18 0,0,0 38 2,4,18 0,0,0 8 255 end goto GotMusic
  3. So far so good, that made things work out!
  4. Collision in DPC+ is something I don't understand quite yet, but if I'm on the right track, I need to see if for example player1y is = to player0y + - height and player1x = player0 + - width?
  5. Thank you for providing the code, it answers a lot of my questions
  6. Making progress, I think I'm starting to get the hang of things with dpc+ now, it's still a little tricky but I adore the features, don't know how I managed without them. I have an issue with a piece of code, I'm not sure if it has something to do with how dpc+ works or if it's me that written the code badly, to me it looks fine. The idea is that there is a random chance that a car appears on screen, then travels down, then repeats the cycle of randomly deciding whether to put it back top or not, problem is the code never starts, it's placed in the main loop. Any thoughts? rem player1 is car if d = 0 then (e = rand&3) if d = 0 && e = 2 then d = 1 if d = 1 then player1x = 70 : player1y = 78 : d = 2 if d = 2 then player1y = player1y + 1 : player1x = player1x - 1 if collision(player1,playfield) then player1x = player1x + 1 if player1y > 150 then d = 0 if d = 0 then player1x = 200 : player1y = 200
  7. Ahh, I missed that, thank you.
  8. Yes, I corrected that mistake. Another question, I know pfscroll 1 4 4 scrolls the pfcolors up, how do I scroll the pfcolors down?
  9. I just started fiddling with DPC+, it is awesome, but some things are different so it takes some getting used too. My first question on how to do stuff in DPC+ is: If I want a wider player0 sprite, how do I do that? The usual NUSIZ0= $07 doesn't do anything it seems? EDIT: I found the problem, I placed it in the wrong spot
  10. I get an error with this combination of kernel options, what am I doing wrong? set kernel_options no_blank_lines pfcolors playercolors
  11. If I can, I'll put in AI, I doubt I'll make it, though, I don't think I can make an AI capable of building it's own forts.
  12. Updates: ricochet on the upper and lower edge of the screen bugfixes, absolutely no chance of breaking walls by walking in to them now. Something I would like to add is that the wind blows you back a little, but I'm running out of variables Snowball Fight.bin
  13. It's a bug, thank you for the report, I'dd add it to the list of things to fix. I will also change the colors a bit to make the snowstorm pop more, and move the players behind the snow. I've been thinking of using DPC, but it seems daunting. I don't know how hard it is to stick a none dpc project into it and continue to work, I'll look more into it. I don't know if I'll add AI for singleplayer, maybe, I'll save that for last
×
×
  • Create New...