-
Content Count
367 -
Joined
-
Last visited
Posts posted by Retro Lord
-
-
I need too figure out a better way too calculate hit detection so it'll be easier too shoot the zombies. But collision detection with multisprite is very hard.
-
News:
Fixed all the bugs related too dying. When you die you are placed correctly in the middle of the screen, no more cheap deaths. I still need a proper game over screen though.
Managed too wrap my head around how music works and the game now sports a small music loop.
Thanks too this thread;
DOWNLOAD - Zed0.6.bas.bin
-
Okay latest version:
NEWS:
Walls are now deadly. Touch the walls and you lose a life and start in the middle of the screen,
There are 3 new screens. (I need to make some sort of transition from level to level for a better feel)
The screen colors are randomly generated too add some flavor.
May your aim be true and give you lots of headshots. My highscore record is 510 =)
DOWNLOAD - Zed0.5.bas.bin
-
Thanks for your feedback. I fixed the glitched and added some new stuff, I'll post the newest version once it's more stable and playable =)
-
By the way, could I be rude and request a short happy melody from someone who knows how to compose music? A small victory jingle would be pretty rad too have when you defeat a zombie wave and go on to the next level.
-
Small update: The playfield changes color when you kill 4 zombies. The game also ends when you run out of lives. Experimental boss is forming.
Some more pleasing sound effects included.
Download - Zed0.4.bas.bin
-
1
-
-
I'm curious if it is possible too have random playfield pixels with the multisprite kernel?
-
Neat solution! Thanks a bunch, that was very helpful!
-
A concept demo I deviced from Rabbit 2600's Robotron engine.
There are 4 zombies on screen. They can be killed by headshots only. This is no easy task and require a bit of skill. But I found it pretty cool. When they grab you, you lose a life, and you have too race against time. Blasting as many zombies as you can aswell as picking up dots too refill the timer.
This might be my successor too Denderes Violence. I found it pretty fun and addictive.
I'm thinking about implementing a shop that you go to once the timer runs out, there you buy health and some kind of weapon powerup by spending your earned points. So it'll be a real struggle to get the highscore. A bit of risk vs reward thing.
No promises =)
Have fun!
Download = Zed.bas.bin
-
Yeah, I'm not that good at optimizing my codes so I believe they are really bloated and a majority of it could be done alot better. Cheers for having a look at it.
Download = default.bas
-
I think I almost solved it. If I do the code I mentioned above without the else variable at the end it kind of works, but missile0 only appears in screen v=2 and no other screen. And if I leave after finding it it's always present in all the other screens aswell.
If I include the else variable missile0 is not in any of the screens.
UPDATE:
Found something that almost worked. if I changedif joy0fire then goto start : a = (rand&1) + (rand&7)
too
if joy0fire then g = (rand&7) : goto start
missile0 is indeed at a randomly chosen screen. I still have the issue with keeping it from appearing if you leave the screen without picking it up.
-
Neat. So at the titlescreen I could have:
if joy0fire then goto start : a = (rand&1) + (rand&7)
And then a system to check what value a is like:
if a=0 && v=2 then missile0x=50:missile0y=50 else missile0x=200:missile0y=200 if a=1 && v=4 then missile0x=50:missile0y=50 else missile0x=200:missile0y=200 if a=2 && v=6 then missile0x=50:missile0y=50 else missile0x=200:missile0y=200
v would be the counter for the rooms. Am way of how this would work?
-
I'm in a bit of a jam. I have a playfield made up of 9 screens. At the start of the game I want the game too decide upon 1 of the screens where the "artifact" is. Aka missile0. The player walks around searching for it. Any ideas on a way too set this up and also making the game remember where the "artifact" is located if the player leaves the screen without picking it up (aka touching it)?
My setup for the screens is
if v=1 then playfield:
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
X.....X.................X......X
X.....X.................X......X
X.....X.................X......X
X.....X.....XXXXX.......XX......
X.....X.....XXXXX.......XX......
X.....X.....XXXXXXX.....XX......
X...........X..................X
X...........X..................X
X...........X..................X
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
endetc.
And going to another screen is as simple as checking for the players x,y position.
-
Thanks! It took me about 3 days but I finaly got it working perfectly =)
-
Screenshots would be nice =)
-
That's some good suggestions. I'll see how much I can implement =)
-
I'm stumped at this one. I want to be able too fire left and right. I can fire right but not left, how come?
The k is simply for making sound and is not really relevant.
if ballx>135 then ballx=200 : bally=200 : goto skip if ballx<10 then ballx=200 : bally=200 : goto skip2 if bally>90 then ballx=200 : bally=200 : goto skip if ballx<10 then ballx=200 : bally=200 : goto skip2 if joy0right && joy0fire goto SHOOTRIGHT if joy0left && joy0fire goto SHOOTLEFT SHOOTRIGHT ballx = ballx+2:goto draw_loop skip if joy0fire && joy0right then k=10 : ballx = missile1x:bally=missile1y-5 SHOOTLEFT ballx = ballx-2:goto draw_loop skip2 if joy0left && joy0fire then k=10 : ballx = missile1x:bally=missile1y-5 draw_loop goto main
-
Nevermind, figured out I only had to switch player0 and player1 around and that solved it.
-
I'm experimenting with the advlight script that allows you too have a light effect around the player. There's one thing I can't figure out. How do I make player1(monster) overlap player0(light) so that player1 becomes visible when in the light? I've set COLUP1 too $00 so it's the same color as the background so you can't see it unless it's in the light zone.
Thanks in advance.
rem ---- Adventure 'Light' Sample Program ---- rem This program demonstrates how to move an animated sprite. rem It combines previous sample programs I've written, and rem adds an invisible playfield along with the 'light' sprite rem that surrounds the player in the mazes in the original rem Atari adventure game. rem Any non-indented command is taken as a label. This is rem something you can jump to with the 'goto' or 'gosub' rem command. rem Declare Variables: rem I'm going to declare x and y variables for the player's rem position, so I can move him with the joystick later. missile0x=50 missile0y=50 player1x=100 player1y=50 rem Add Static Playfield playfield: X..............................X XXXXXXXXXXXXXXXXXXXX..........XX X..................X...........X X..............................X XX............................XX X..............................X X..............................X XX............................XX X.........X....................X X.........XXXXXXXXXXXXXXXXXXXXXX X..............................X end rem Change the color of the playfield to black to match the rem background color. We want the walls to be invisible for rem this sample. COLUPF=0 main rem Set NUSIZ to make light sprite quad sized. rem rem Value Effect rem $0x (x = don't care) missile = 1 pixel wide rem $1x missile = 2 pixels wide rem $2x missile = 4 pixels wide rem $3x missile = 8 pixels wide rem $x0 one copy of player and missile rem $x1 two close copies of player and missile rem $x2 two medium copies of player and missile rem $x3 three close copies of player and missile rem $x4 two wide copies of player and missile rem $x5 double-sized player rem $x6 three medium copies of player and missile rem $x7 quad-sized player NUSIZ0=$37 missile0height = 8 rem Set CTRLPF so light sprite moves behind playfield rem rem Value Effect rem $0x (x = don't care) ball = 1 pixel wide rem $1x ball = 2 pixels wide rem $2x ball = 4 pixels wide rem $3x ball = 8 pixels wide rem $x1 none of the below rem $x3 left half of PF gets player0 color, rem right half gets player1 color rem $x5 players move behind playfield rem $x7 both of the above CTRLPF=$05 rem position light sprite so it surrounds player sprite rem and moves with it player0x=missile0x-20:player0y=missile0y+20 rem COLUP0=<xx> sets the color of the player 0 sprite. Valid rem range is 0-254. rem Sample Program 3 used 28 (decimal), which is yellow. rem Sample Program 5 used $28 (hexadecimal), which is orange. rem This sample program uses hexadecimal for the color values. COLUP0=$28 COLUP1=$00 rem Change the background color with COLUBK. Changing to same rem color as playfield to make playfield invisible. COLUBK=$00 rem f will be used for the frame counter. In Sample Program 5, rem this was y instead of f; but Sample Program 3 uses y for rem the vertical position of player0, so we need to use a rem different variable-- and "f" is a nice little abbreviation rem for "frame"! f=f+1 rem Here is where you define the shape of the player sprite. rem It's limited to 8 pixels wide, but you can make it as rem tall/long as you want. You have to draw the sprite upside rem down; it's flipped when it's displayed onscreen. rem The 'player0' must be indented, the 'end' must NOT be rem indented. rem The frame counter will be used in animating the sprite. rem We'll draw a different picture for the sprite, depending on rem what the value of f is. Generally, the animation should rem cycle through at least 3 different images to give a decent rem illusion of movement. if f=10 then player1: %00111010 %00000000 %00011010 %00010000 %00001010 %00011110 %10001110 %11110110 %00111010 %11011110 %00100100 %00011000 %00101100 %00111100 %00010100 %00111000 end if f=20 then player1: %01110011 %00000001 %00110010 %00010000 %00001010 %00011110 %10001110 %11110110 %00111010 %11011110 %00100100 %00011000 %00101100 %00111100 %00010100 %00111000 end rem This defines the adventure 'light' sprite light player0: %01111110 %11111111 %11111111 %11111111 %11111111 %11111111 %11111111 %11111111 %11111111 %11100111 %11000011 %11000011 %11000011 %11000011 %11000011 %11000011 %11000011 %11000011 %11000011 %11000011 %11000011 %11000011 %11000011 %11100111 %11111111 %11111111 %11111111 %11111111 %11111111 %11111111 %11111111 %01111110 end rem The next statement ensures that f cycles continuously from rem 1 to 30 when we perform the "f=f+1" statement up above. if f=20 then f=0 rem Put the player on the screen at horizontal position x rem (which we initialized to 50). Valid range is 1 to 159. player0x=missile0x-14 rem Put the player on the screen at vertical position y (which rem we initialized to 50). Valid range is 1 to ~90. player0y=missile0y+12 rem This command instructs the program to write the data for rem the display (picture) to the TV screen. drawscreen rem Make the guy move. if joy0right then missile0x=missile0x+1 if joy0left then missile0x=missile0x-1 if joy0up then missile0y=missile0y-1 if joy0down then missile0y=missile0y+1 goto main -
I'm thinking about doing a sequel and I just wanted too check if there is any interest for it.
The concept is the same as before. Kill waves of zombies and defeat the boss. But this time you stand in the center and zombies are coming left and right and you have to be quick too get them all. And I will take pacgreg's suggestion to heart and have random colors on the zombies for more variety. And have 3 different bosses. Maybe have a civilian running up too you during the wave that you have too save. I.E don't shoot! for added difficulty. This would be fairly simple to do since I would basically just have too modify the source of the original game slightly.
Thanks in advance for everyones support.
-
I'm glad you like it. =)
@Byte Knight - They are big. But that's the standard boss-grand megadeath bullets all giant bosses buy when they shop at Doomed R Us =)
He's tough to beat but I assure he is beatable.
-
Aha, I'm beginning too see what I might have done wrong. Many thanks RandomTerrain. It appears I have the goto/gosub in the wrong location.
-
Ah, I missed that. That is great to know! I changed too return otherbank but I still can't get them going.Could it be because I use "if v=1 then playfield" in the banks, or dosn't it matter what kind of information is within the bank so that may be a cause of the issue?
This is what my bank2 is filled with:
map bank 2 if v=1 then playfield: XXXXXXXXXXX......XXXXXXXXXXXXXXX XXXXXXXXXXX.......XXXXXXXXXXXXXX XXXXXXXXXXX........XXXXXXXXXXXXX XXXXXXXXXX..........XXXXXXXXXXXX XXX...........................XX XXX...........................XX XX.............................X X..............................X X...............XXXXXXX.......XX XX.........XXXXXXXXXXXXXXXXXXXXX XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX end if v=2 then playfield: XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX ..XXXXXXXXXXXXXXXXXXXXXXXXX..... ......XXXXXXXXXXXXXXXXX......... ..............XXXXX............. ................................ ................................ ................................ ................................ ................................ ....XXXX............XXXXXXXXX... XXXXXXXXXXX......XXXXXXXXXXXXXXX end if v=3 then playfield: XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX ...XXXXXXXXXXXXXXXXXXXXXXXXXXXXX .......XXXXXXXXXXXXXXXXXXXXXXXXX ..........XXXXXXXXXXXXXXXXXX.... .....................XXXX....... ................................ ................................ ..............XXXX.............. ............XXXXXXXXXXXXXXXXX... .........XXXXXXXXXXXXXXXXXXXXXXX XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX end if v=4 then playfield: XX.............................. XXX............................. XX.......................XX..... ...........XX...........XXX..... ...........XXX.................. ................................ ................................ ...X................XX.......... ...XX..............XXX.......... XXXXX........................... XXX............................. end if v=5 then playfield: ................................ ................................ .....XX......................... .....XXX........................ ..................XX............ .................XXX.......X.... ........................XXXXXX.. .......................XXXXXXXXX ............XX..XXXXXXXXXXXXXXXX ...........XXXXXXXXXXXXXXXXXXXXX ...........XXXXXXXXXXXXXXXXXXXXX end if v=6 then playfield: XX.............................. XXXXX........................... XXXXXXX......................... XXXXXXXX........................ XXXXX........................... XXXXX........................... XXXX......................XX.... XX....................XXXXXXX... XXX..............XXXXXXXXXXXXXX. XXXX.........XXXXXXXXXXXXXXXXXXX XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX end if v=7 then playfield: ...........XXXXXXXXXXXXXXXXXXXXX ...........XXXXXXXXXXXX.XXXXXXXX ...........XXXXXXXXXXX...XXXXXXX ............XXX.XXXXXX...XXXXXXX ............XX.............XXXXX ............................XXXX ............................XXXX ..........X................XXXXX .........XXXX....XX....XXXXXXXXX XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX end if v=8 then playfield: ................................ ..................XX............ .................XXX............ .........XX..................... .........XXX.................... ................................ .......................XX....... .......................XXX...... ................................ ................................ ................................ end if v=9 then playfield: XXXXXXXXXXXXXXXX................ XXXXXXXXXXXXXXXXX............... .......XXXXXXXXXXX.............. .............XXXXX.............. ..............XXX............... XXX............................. XXXXX........................... XXXXX........................... XXXXX........................... XXXXX........................... XXX............................. end if v=10 then playfield: XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX XXXX.......................XXXXX XX........XX.XX.XX.XX........... X.........XXXXXXXXXXX........... XX........XXXXXXXXXXX........... XX........XX.X...X.XX........XXX XX........XXXX...XXXX.......XXXX X...........................XXXX X..........................XXXXX XXX........................XXXXX XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX end if v=11 then playfield: XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX ...........XXXXXXXXX............ ................................ ................................ ................................ ................................ XXXXXXXXXXXXXX.................. XXXXXXXXXXXXXXXX................ XXXXXXXXXXXXXXXX................ XXXXXXXXXXXXXXXX................ end if v=12 then playfield: XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX ..........XXXXXXXXXXXXXXXXX..... ..............XXXXXXXXXX........ ...............XXXXX............ ................................ ................................ ................................ ................................ ................................ ................................ end if v=13 then playfield: XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX XX........XXXXXXX...XXXXXX...... X............................... ................................ ................................ ................................ ................................ ................................ XXXXXXXXX.......XXXXXXXX........ XXXXXXXXXX.....XXXXXXXXXXXXXXX.. XXXXXXXXXXX...XXXXXXXXXXXXXXXXXX end if v=14 then playfield: XXXXXXXXXXX...XXXXXXXXXXXXXXXXXX XXXXXXXXXX....XXXXXXXXXX.XXXXXXX XXXX.XXXX......XXXXXXXX...XXXXXX XXXX..............XXXXX...XXXXXX XXXX........................XXXX XXX..........................XXX XX............................XX XXXX.........................XXX XXXXXXXX....................XXXX XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX end if v=16 then playfield: ...................XXXXXXXXXXXXX ...................XXXXXXXXXXXXX ....................XXXXXXXXXXXX ................................ ................................ XXXXXXXXXX...................... XXXXXXXXXXXXXX.................. XXXXXXXXXXXXXXXXX........XXXX... XXXXXXXXXXXXXXXXXX.XXXXXXXXXXXXX XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX end if v=17 then playfield: XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX XXXXXXXXXXXXXXXXXX.............. XXXXXXXXX....................... XX.XXX.......................... XX.............................. ......................XXXXXXXXXX .....................XXXXXXXXXXX ...................XXXXXXXXXXXXX ...................XXXXXXXXXXXXX ...................XXXXXXXXXXXXX ...................XXXXXXXXXXXXX end if v=18 then playfield: XXXXXXXXXXXXXXX....XXXXXXXXXXXXX ..XXXXXXXXXXXXX....XX...XXXXXXXX .............................XXX ..............................XX ...............................X ...............................X ...............................X ....XXXXXXXXX.........XXXXXXXXXX XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX end if v=19 then playfield: XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX XXXXXXXXXXXXXXXXXXXXXXXX........ XXXXXXXXXXXXXXXXXXX............. XXXXXXXXXXXXXX.................. XXXXXXXXXXXXX................... XXXXXXXXXXXX.................... XXXXXXXXXXXXX................... XXXXXXXXXXXXXXX..........XX..... XXXXXXXXXXXXXXX.....XXXXXXXXXXXX XXXXXXXXXXXXXXX....XXXXXXXXXXXXX end if v=20 then playfield: XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX .....XXXXXXXXXXXXXXXXXXXX....... ................................ ................................ ................................ ................................ ................................ ......XXXXXXXXXXXXXXXXXXXXX..... XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX end if v=21 then playfield: XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX XXXXXX......XX.XXXXXXXXXXX..XXXX ................................ ................................ ................................ ................................ ....................XXXX........ ..............XX.XXXXXXXXXXXXXXX ..XXXX..XXXXXXXXXXXXXXXXXXXXXXXX XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX end if v=22 then playfield: .......................XXXXXXXXX .......................XXXXXXXXX ........................XXXXXXXX .........................XXXXXXX ..........................XXXXXX .........................XXXXXXX .........................XXXXXXX XXXXXXX................XXXXXXXXX XXXXXXXXXXXXXXX....XXXXXXXXXXXXX XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX end if v=23 then playfield: .......................XXXXXXXXX ........................XXXXXXXX .........................XXXXXXX ..........XX............XXXXXXXX .........XXX..........XXXXXXXXXX ......................XXXXXXXXXX ......................XXXXXXXXXX ...XX...................XXXXXXXX ...XXX...................XXXXXXX ........................XXXXXXXX .......................XXXXXXXXX end if v=24 then playfield: XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX ..XXXXXXX.........XXXXXXXXXXXXXX ....................XXXXXXXXXXXX ......................XXXXXXXXXX ........................XXXXXXXX ........................XXXXXXXX .........................XXXXXXX ........................XXXXXXXX .......................XXXXXXXXX .......................XXXXXXXXX end return otherbank
-
Hm, I'm having a little trouble with bankswitching. I added " gosub map bank2" that leads too "map bank 2" containing all my map data and ending with "returnthisbank"
When I test it out I can't get the game too load the maps. What may I be doing wrong?
Source - Lonk.bas.bin

Multisprite zombie shooting demo
in batari Basic
Posted
I've encountered a bug that I have no idea on how too fix. My plan is having you shoot the zombies and when you kill 1 they are gone, and when you kill all 5 zombies you move too the next screen.
The bug crashes the game when the last zombie is killed.
My setup for this is:
t is the counter for the kills. When it hits 5 you go to the next screen.
n is for playing a sound effect.
g is the counter for displaying the screens.
My setup for the killed zombies:
Sourcecode : Zed0.7.bas