Jump to content
IGNORED

Basic Robotron engine


Rabbit 2600

Recommended Posts

This would be a good platform to test out flicker mitigation techniques. I wonder if you could use the missiles as the chests for the robots. If you could timeshare missile0 and missile1 then there would be less flicker on the robots.

 

Also, you could use playfield blocks as the robot chests. The only thing that would blink are the heads, arms and legs. The tradeoff is that the robot movement would be clunky (always moving single playfield block at a time.)

Link to comment
Share on other sites

Sure I can post the code =)

 

I must learn missiles sometime, I have great examples to look at but I just don't get it. Thinking of having the robots firing missiles left and right so they won't be so easy to bomb.

 rem Generated 2013-10-19 17:39:33 by Visual bB Version 1.0.0.554
 rem **********************************
 rem *<filename>                      *
 rem *<description>                   *
 rem *<author>                        *
 rem *<contact info>                  *
 rem *<license>                       *
 rem **********************************

   set kernel multisprite

        set smartbranching on


 player1x = 135 : player1y = 25
 player2x = 122 : player2y = 50
 player3x = 255 : player3y = 255
 player4x = 255 : player4y = 255
 player0x = 50 : player0y = 50
 player5x = 32 : player5y = 75

 ballx = 255 : bally = 255

   AUDV0=0
   AUDV1=0

BATTLEFIELD



                                  dim _P1_L_R = player1x.a
                                  dim _P1_U_D = player1y.b

                                  dim _P2_L_R = player2x.c
                                  dim _P2_U_D = player2y.d

                                  dim _P5_L_R = player5x.k
                                  dim _P5_U_D = player5y.l

                                  dim _P0_L_R = player0x.i
                                  dim _P0_U_D = player0y.j

 if q = 1 then player0:
        %00100100
        %00100100
        %00011000
        %00011000
        %00011110
        %00000000
        %00011000
        %00011000
end

 if q = 2 then player0:
        %00100100
        %00100100
        %00011000
        %00011000
        %01111000
        %00000000
        %00011000
        %00011000
end

   player1:
        %00001000
        %00000000
        %01011101
        %01011101
        %00011100
        %01100011
        %00011100
        %00011100
end

   player2:
        %00001000
        %00000000
        %01011101
        %01011101
        %00011100
        %01100011
        %00011100
        %00011100
end


BOMB
  rem POSSIBLY INEFFICIENT CODE, SEPARATE COLOR INFO FOR EACH FRAME...
   player3:
        %00011100
        %00111110
        %00101110
        %00100110
        %00011100
        %00001000
        %00000110
        %00000000
end

EXPLOSION

 player4:
        %00110011
        %00110011
        %11001100
        %11001100
        %00110011
        %00110011
        %11001100
        %11001100
end


   player5:
        %00001000
        %00000000
        %01011101
        %01011101
        %00011100
        %01100011
        %00011100
        %00011100
end

 _COLUP1 = $0E

 COLUP2 = $40

 COLUP3 = $02

 COLUP4 = rand

 COLUP5 = $16

 COLUP0 = $1E

 t = t + 1

 if t = 10 then COLUPF = $94

 if t = 20 then COLUPF = $98

 if t = 20 then t = 0




 playfield:
 ................
 ................
 ................
 ................
 ................
 XXXXXXXXXXXXXXXX
 X...............
 X...............
 X...............
 X...............
 XXXXXXXXXXXXXXXX
end

 scorecolor = $0E

 drawscreen

        if joy0right then q = 1 : _P0_L_R = _P0_L_R + 0.30
        if joy0left then q = 2 : _P0_L_R = _P0_L_R - 0.30
        if joy0up then _P0_U_D = _P0_U_D + 0.30
        if joy0down then _P0_U_D = _P0_U_D - 0.30

  if _P1_U_D < _P0_U_D then _P1_U_D = _P1_U_D + 0.10
  if _P1_U_D > _P0_U_D then _P1_U_D = _P1_U_D - 0.10
  if _P1_L_R < _P0_L_R then _P1_L_R = _P1_L_R + 0.10
  if _P1_L_R > _P0_L_R then _P1_L_R = _P1_L_R - 0.10

  if _P2_U_D < _P0_U_D then _P2_U_D = _P2_U_D + 0.10
  if _P2_U_D > _P0_U_D then _P2_U_D = _P2_U_D - 0.10
  if _P2_L_R < _P0_L_R then _P2_L_R = _P2_L_R + 0.10
  if _P2_L_R > _P0_L_R then _P2_L_R = _P2_L_R - 0.10

  if _P5_U_D < _P0_U_D then _P5_U_D = _P5_U_D + 0.10
  if _P5_U_D > _P0_U_D then _P5_U_D = _P5_U_D - 0.10
  if _P5_L_R < _P0_L_R then _P5_L_R = _P5_L_R + 0.10
  if _P5_L_R > _P0_L_R then _P5_L_R = _P5_L_R - 0.10

 if player1y = 35 then player1y = 34

 if player2y = 55 then player2y = 54
 if player2y = 36 then player2y = 37

 if player5y = 60 then player5y = 61

 if player3x < 255 then goto SKIP

 if joy0fire then player3x = player0x + 8 : player3y = player0y : z = 72

SKIP

 if z > 0 then z = z - 1 : if z = 0 then player4x = player3x : player4y = player3y : u = 52

 if u > 0 then AUDV0 = 15 : AUDC0 = 8 : AUDF0 = 30 : u = u - 1 : if u = 0 then player4x = 255 : player4y = 255 : player3x = 255 : player3y = 255 : AUDV0 = 0

   if n > 0 then AUDV0 = 15 : AUDC0 = 8 : AUDF0 = 20 : n = n - 1: if n = 0 then AUDV0 = 0

 if player2x = player4x && player2y = player4y then player2y = 255 : player2x = 255 : score = score + 100

 if player1x = player4x && player1y = player4y then player1y = 255 : player1x = 255 : score = score + 100

 if player5x = player4x && player5y = player4y then player5y = 255 : player5x = 255 : score = score + 100

 if joy0left && collision(player0,playfield) then player0x = player0x + 1
 if joy0right && collision(player0,playfield) then player0x = player0x - 1

 if joy0up && collision(player0,playfield) then player0y = player0y - 1
 if joy0down && collision(player0,playfield) then player0y = player0y + 1






 goto BATTLEFIELD
Link to comment
Share on other sites

  • 7 years later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...