Thanks, it's my first complete work! It's not in greyscale, the GIF came out funny. I made this entirely in BASIC and wanted to make a super compact Bomberman, and 1125 bytes is pretty small to me!

When you light the bomb, if you stand in the center of the bomb, you don't die. There is also some memory leaks in your code, instead of the main loop label (Lbl 0), I would replace it with a While 1 instead.
Hewwo, my name is Achak Claw. I was formerly BioHazard.
I agree, take a look at the gameplay very closely. For every time a new game starts, the performance starts to get lower and lower.
A few things. Yes, there are memory leaks. There are quite a few of them as a matter of fact. However, this was uploaded in 2017. Although the creator is still active, on such an old project I would expect there to be bugs.
Edit:
I had some spare time and decided to fix a few things.
- Fixed the memory leaks when a bomb explodes
- Fixed the bug where you can stand on top of the bomb
- Fixed the memory leaks when placing a bomb or regenerating the map
- Fixed the memory leak when you get to the square where you win
- Added enter as a key to place the bomb
- Removed the dependencies
ClrDraw
0→Xmin
94→Xmax
⁻62→Ymin
0→Ymax
AxesOff
FnOff
Lbl G
DelVar [A]
{12,12→dim([A]
Line(26,⁻57,74,⁻57
Line(26,⁻7,74,⁻7
Line(25,⁻8,25,⁻56
Line(75,⁻8,75,⁻56
For(B,26,50
Line(B,⁻56,B,⁻8,0
Line(100-B,⁻56,100-B,⁻8,0
End
For(A,1,12
For(B,1,12
4A→C
⁻4B→D
randInt(⁻3,1→[A](B,A
If Ans=1 or Ans=⁻2
Pt-On(24+C,D-6,2
If Ans=⁻3
Then
Pt-On(24+C,D-6,2
Pt-On(24+C,D-6
End
End
End
0→[A](1,1
Pt-Off(28,⁻10,2
Pt-Off(28,⁻10
0→[A](12,12
Pt-Off(72,⁻54,2
Pt-Off(72,⁻54
0→[A](1,2
Pt-Off(32,⁻10,2
Pt-Off(32,⁻10
0→[A](2,1
Pt-Off(28,⁻14,2
Pt-Off(28,⁻14
0→W
Ans→Z
28→U
⁻10→V
30→T
0→L
Lbl 0
0→D
0→K
//set D to 0, this will act as a flag
//set K to 0, this prevents the while loop from triggering too early
Pt-On(U,V,3
While not(D)not(sum(K={21,22,45,105
//Add a check for D into the while, also add a check for K being one of our special keys
//since this is an and statement, we can use multiplication to save a byte
DelVar D
Repeat Ans or D
//Add a check for D into the repeat
T-L→T
If not(Ans:1→D
//Replace the goto with a flag set
getKey→K
End
//now we are outside the repeat, but still within the while
If D:Goto ED
//Jump to the end of the while
If sum(K={21,22,45,105:Goto ED
//Fix the keypress memory leaks by jumping to the end of the while
Pt-Off(U,V,3
U+4(K=26 and not(pxl-Test(abs(V),U+3)))-4(K=24 and not(pxl-Test(abs(V),U-3→U
V+4(K=25 and not(pxl-Test(abs(V)-3,U)))-4(K=34 and not(pxl-Test(abs(V)+3,U→V
Pt-On(U,V,3
If U=72 and V=⁻54:1→D
//Set the flag here, so we exit the while
Lbl ED
End
If U=72 and V=⁻54:Goto W
If K=21 or K=105:Goto S
If K=22:Goto G
If K=45
Then
ClrDraw
ZStandard
AxesOn
FnOn
DelVar [A]
ClrHome
Stop
End
Lbl D
Pt-Off(W,Z,2
//Add a conditional to check if you are where the bomb is
//This will Always trigger, but we need it inside a conditional
//To satisfy the end we added in L
If WZ
Then
If W=U and Z=V:Goto L
End
If W<72
Then
If [A](abs((62-abs(Z))/4-14),(W/4)-5)≠⁻3
Pt-Off(W+4,Z,2
If W+4=U and Z=V
Goto L
End
If W>28
Then
If [A](abs((62-abs(Z))/4-14),(W/4)-7)≠⁻3
Pt-Off(W-4,Z,2
If W-4=U and Z=V
Goto L
End
If Z>⁻54
Then
If [A](abs((62-abs(Z))/4-14)+1,(W/4)-6)≠⁻3
Pt-Off(W,Z-4,2
If W=U and Z-4=V
Goto L
End
If Z<⁻10
Then
If [A](abs((62-abs(Z))/4-14)-1,(W/4)-6)≠⁻3
Pt-Off(W,Z+4,2
If W=U and Z+4=V
Goto L
End
30→T:0→L
Goto 0
Lbl S
If L=1:Goto 0
1→L
U→W:V→Z
Pt-On(W,Z,2
Goto 0
Lbl W
θ+1→θ
Text(0,46,"WIN!
Pt-On(θ,⁻62
Pause
Text(0,46,"
Goto G
Lbl L
//Adding an end here takes care of the memory leaks from the if then end statements
//Since this label will only be entered from a memory leak, there is no risk in putting this here
End
0→θ
Text(0,44,"LOSE
Pause
Text(0,44,"
Line(0,⁻62,94,⁻62,0
Goto G
EDIT: How can I change the memory leaks and flaws?
Hewwo, my name is Achak Claw. I was formerly BioHazard.
To fix the error of being able to stand where the bomb is, you have find in the code where it determines if you die. Then, you have to add a conditional to check if you are where the bomb is.
//This is the portion of the code that checks if you are in the blast area of the bomb
//This is where we need to add the conditional to see if we are where the bomb is
//Since we know it is a smaller conditional than the others, we should put it first to optimize speed
//That is because if it is triggered, we won't have to do the longer calculations before getting to this one
If WZ
Then
If W=U and Z=V:Goto L
End
//The above conditional is the one I added. It always triggers, since there is always W and Z.
//I could simplify this more, but have it this way so it matches the format of the others
//The format is important to how I solved the memory leaks
If W<72
Then
If [A](abs((62-abs(Z))/4-14),(W/4)-5)≠⁻3
Pt-Off(W+4,Z,2
If W+4=U and Z=V
Goto L
End
If W>28
Then
If [A](abs((62-abs(Z))/4-14),(W/4)-7)≠⁻3
Pt-Off(W-4,Z,2
If W-4=U and Z=V
Goto L
End
If Z>⁻54
Then
If [A](abs((62-abs(Z))/4-14)+1,(W/4)-6)≠⁻3
Pt-Off(W,Z-4,2
If W=U and Z-4=V
Goto L
End
If Z<⁻10
Then
If [A](abs((62-abs(Z))/4-14)-1,(W/4)-6)≠⁻3
Pt-Off(W,Z+4,2
If W=U and Z+4=V
Goto L
End
The memory leaks are a bit more complicated. First you have to find them, then you have to fix them. You may notice that I indent my code every time there is a For, If-Then, While, or Repeat, and unindent when an End statement is reached. This helps me find any Goto's that Jump outside the current level.
Lets take a look at the code box in the first collapsible. You will notice all the statements that say Goto L jump out of an If-Then statement before an end. This is a memory leak. Now, lets take a look at label L. What I mean by that is not look at the code inside label L, but look at how we can get to Label L. Is it always through a goto, or is it sometimes run in normal program execution without a goto? In the original program, the only way that the code in Label L will be run is through a Goto. If we look closer, we notice that all the lines which Goto L cause a memory leak. That means the fix for this is simple, we just correct the leak inside Label L. This will fix it for all the instances of Goto L, and will save us some work. This is why it was important to have the conditional in the first code box formatted the way it was. If it did not cause a memory leak, it would cause this fix to throw an error.
Lbl L
//Adding an end here takes care of the memory leaks from the if then end statements
//Since this label will only be entered from a memory leak, there is no risk in putting this here
End
0→θ
Text(0,44,"LOSE
Pause
Text(0,44,"
Line(0,⁻62,94,⁻62,0
Goto G
Now lets deal with the memory leaks from the while and repeat loops. The first thing I noticed is that the repeat loop is a Level 2 memory leak, meaning it is jumping outside of 2 loops instead of just 1. The easiest way to fix a memory leak is by splitting the conditionals. This means having 1 conditional inside the loop, and 1 conditional outside the loop. Each conditional has a very specific purpose. The conditional inside the loop should be set to cleanly exit the loop, meaning that it will stop the loop without jumping out of it. The conditional outside the loop will be the one to actually run the Goto. I will take care of the repeat loop first.
//Original Code
Repeat Ans
T-L→T
If not(Ans:Goto D
getKey→K
End
Before we work on splitting the conditional, it is important to know what exits the loop, and what causes that to be triggered. In this case, we see that Ans exits the loop. What triggers Ans is the getKey. Because the getKey is last, K will always be the value in Ans. Therefore, we need to add another check into the repeat. To do this, create a simple recycled flag (learn more about flags). We change the first conditional into a flag set, and then add in the second conditional outside the loop.
0→D
//The above line is for visual, it actually goes elsewhere in the final program
Repeat Ans or D
//Add a check for D into the repeat
T-L→T
If not(Ans:1→D
//Replace the goto with a flag set
getKey→K
End
If D:Goto D
Now we have reduced the Level 2 memory leak into a Level 1 memory leak, we need to split the conditional again. This time, we need to do it inside the while statement. It would make sense at this time to also fix the memory leaks that are caused by other conditions, but for simplicity I split it into a few steps
0→D
//Set D to 0 so that this while loop is always run at least once
While not(D)
//Since we used D as our flag in the repeat loop, we substitute it as a condition of the while loop
//We use not, since we want to exit the while loop if D is 1, and run the while loop if D is 0
DelVar D
//Set D to 0 every time we enter the repeat loop. This is the "recycled" part of the recycled flag
Repeat Ans or D
T-L→T
If not(Ans:1→D
getKey→K
End
//now we are outside the repeat, but still within the while
//If the flag is set, we want to skip to the end of the while loop
//Although there is a goto here, it is not a leak since it does not exit the loop, it just jumps around inside it
If D:Goto ED
//Jump to the end of the while
If U=72 and V=⁻54:Goto W
If K=21 or K=105:Goto S
If K=22:Goto G
//the above 3 gotos are memory leaks
If K=45
Then
ClrDraw
ZStandard
AxesOn
FnOn
DelVar [A]
ClrHome
Stop
End
//note that the if K=45 is not a memory leak, since it ends the program. It is still a good practice to move it outside however
Pt-Off(U,V,3
U+4(K=26 and not(pxl-Test(abs(V),U+3)))-4(K=24 and not(pxl-Test(abs(V),U-3→U
V+4(K=25 and not(pxl-Test(abs(V)-3,U)))-4(K=34 and not(pxl-Test(abs(V)+3,U→V
Pt-On(U,V,3
Lbl ED
//note that we jump right to the end of the while
End
//Since Lbl D is immediately outside the while, we don't need "Goto D" anymore, since it will run automatically.
Lbl D
Okay, thats one memory leak fixed. Now we need to fix the memory leak when we press keys 21 or 22. To keep the code clean, we should also move the keypress for 45 outside as well.
0→D
0→K
//set K to 0 since we want the while loop to be ran at least once
Pt-On(U,V,3
While not(D)not(sum(K={21,22,45,105
//Add a check for K being one of our special keys
//since this is an and statement, we can use multiplication to save a byte
DelVar D
Repeat Ans or D
T-L→T
If not(Ans:1→D
getKey→K
End
If D:Goto ED
If sum(K={21,22,45,105:Goto ED
//If one of our special keys is pressed, we jump to the end of the while. We can use the same label we created earlier
Pt-Off(U,V,3
U+4(K=26 and not(pxl-Test(abs(V),U+3)))-4(K=24 and not(pxl-Test(abs(V),U-3→U
V+4(K=25 and not(pxl-Test(abs(V)-3,U)))-4(K=34 and not(pxl-Test(abs(V)+3,U→V
Pt-On(U,V,3
If U=72 and V=⁻54:Goto W
Lbl ED
End
//Now we can add in the second halves of the split conditionals.
//It doesnt matter that they are before Lbl D since they will not be run if we are going to Lbl D
//This means they wont interfere with anything, and now the Goto's are outside of any loops
If K=21 or K=105:Goto S
If K=22:Goto G
If K=45
Then
ClrDraw
ZStandard
AxesOn
FnOn
DelVar [A]
ClrHome
Stop
End
Lbl D
The last memory leak we need to fix is when the game is won. Again, we just need to split the conditionals
0→D
0→K too early
Pt-On(U,V,3
While not(D)not(sum(K={21,22,45,105
DelVar D
Repeat Ans or D
T-L→T
If not(Ans:1→D
getKey→K
End
If D:Goto ED
If sum(K={21,22,45,105:Goto ED
Pt-Off(U,V,3
U+4(K=26 and not(pxl-Test(abs(V),U+3)))-4(K=24 and not(pxl-Test(abs(V),U-3→U
V+4(K=25 and not(pxl-Test(abs(V)-3,U)))-4(K=34 and not(pxl-Test(abs(V)+3,U→V
Pt-On(U,V,3
If U=72 and V=⁻54:1→D
//There are 3 options here for how to exit the conditional.
//We could set a value to D, Set a value to K(such as 1), or add a new flag
//It really doesn't matter which one we choose, but I decided
//to use D just because its already a recycled flag and requires no change to the while loop
//This leaves K for keypresses only, which is good since its best to use a variable for only
// one type of function as often as possible
Lbl ED
End
//We can put our win conditional here since it is outside
//the while loop and wont interfere with Lbl D
If U=72 and V=⁻54:Goto W
If K=21 or K=105:Goto S
If K=22:Goto G
If K=45
Then
ClrDraw
ZStandard
AxesOn
FnOn
DelVar [A]
ClrHome
Stop
End
Lbl D
Now we can check for any more memory leaks inside the main program. I have labeled all the Goto's with whether or not they are a leak. We can see all the Goto's have been accounted for, and the ones that do leak are fixed immediately after they jump to the label. This means all the leaks have been fixed, and we can see that you can no longer stand where the bomb is.
ClrDraw
0→Xmin
94→Xmax
⁻62→Ymin
0→Ymax
AxesOff
FnOff
Lbl G
DelVar [A]
{12,12→dim([A]
Line(26,⁻57,74,⁻57
Line(26,⁻7,74,⁻7
Line(25,⁻8,25,⁻56
Line(75,⁻8,75,⁻56
For(B,26,50
Line(B,⁻56,B,⁻8,0
Line(100-B,⁻56,100-B,⁻8,0
End
For(A,1,12
For(B,1,12
4A→C
⁻4B→D
randInt(⁻3,1→[A](B,A
If Ans=1 or Ans=⁻2
Pt-On(24+C,D-6,2
If Ans=⁻3
Then
Pt-On(24+C,D-6,2
Pt-On(24+C,D-6
End
End
End
0→[A](1,1
Pt-Off(28,⁻10,2
Pt-Off(28,⁻10
0→[A](12,12
Pt-Off(72,⁻54,2
Pt-Off(72,⁻54
0→[A](1,2
Pt-Off(32,⁻10,2
Pt-Off(32,⁻10
0→[A](2,1
Pt-Off(28,⁻14,2
Pt-Off(28,⁻14
0→W
Ans→Z
28→U
⁻10→V
30→T
0→L
Lbl 0
0→D
0→K
Pt-On(U,V,3
While not(D)not(sum(K={21,22,45,105
DelVar D
Repeat Ans or D
T-L→T
If not(Ans:1→D
getKey→K
End
If D:Goto ED
If sum(K={21,22,45,105:Goto ED
//Neither of these are leaks, since they stay inside the while statement
Pt-Off(U,V,3
U+4(K=26 and not(pxl-Test(abs(V),U+3)))-4(K=24 and not(pxl-Test(abs(V),U-3→U
V+4(K=25 and not(pxl-Test(abs(V)-3,U)))-4(K=34 and not(pxl-Test(abs(V)+3,U→V
Pt-On(U,V,3
If U=72 and V=⁻54:1→D
Lbl ED
End
If U=72 and V=⁻54:Goto W
If K=21 or K=105:Goto S
If K=22:Goto G
//None of these jump into or out of a loop, so they aren't leaks.
If K=45
Then
ClrDraw
ZStandard
AxesOn
FnOn
DelVar [A]
ClrHome
Stop
End
Lbl D
Pt-Off(W,Z,2
If WZ
Then
If W=U and Z=V:Goto L
//Technically a leak, but it is fixed later in the program
End
If W<72
Then
If [A](abs((62-abs(Z))/4-14),(W/4)-5)≠⁻3
Pt-Off(W+4,Z,2
If W+4=U and Z=V:Goto L
//Technically a leak, but it is fixed later in the program
End
If W>28
Then
If [A](abs((62-abs(Z))/4-14),(W/4)-7)≠⁻3
Pt-Off(W-4,Z,2
If W-4=U and Z=V:Goto L
//Technically a leak, but it is fixed later in the program
End
If Z>⁻54
Then
If [A](abs((62-abs(Z))/4-14)+1,(W/4)-6)≠⁻3
Pt-Off(W,Z-4,2
If W=U and Z-4=V:Goto L
//Technically a leak, but it is fixed later in the program
End
If Z<⁻10
Then
If [A](abs((62-abs(Z))/4-14)-1,(W/4)-6)≠⁻3
Pt-Off(W,Z+4,2
If W=U and Z+4=V:Goto L
//Technically a leak, but it is fixed later in the program
End
30→T:0→L
Goto 0
Lbl S
If L=1:Goto 0
//This doesn't jump into or out of a loop, so its not a leak
1→L
U→W:V→Z
Pt-On(W,Z,2
Goto 0
Lbl W
θ+1→θ
Text(0,46,"WIN!
Pt-On(θ,⁻62
Pause
Text(0,46,"
Goto G
//This doesn't jump into or out of a loop, so its not a leak
Lbl L
//Adding an end here takes care of the memory leaks from the if then end statements
//Since this label will only be entered from a memory leak, there is no risk in putting this here
End
0→θ
Text(0,44,"LOSE
Pause
Text(0,44,"
Line(0,⁻62,94,⁻62,0
Goto G
//This doesn't jump into or out of a loop, so its not a leak
Okay, this confuses me a bit. Which code is the whole game?
EDIT: Nevermind, I found it.
EDIT 2: You should add your loooooooong post to a new page. Or collapse your post, so it would not take a user 1000 years to get to the bottom.
Hewwo, my name is Achak Claw. I was formerly BioHazard.
I kind of edited Trenly's version a bit, I made it a dark version. Looks cool, you can try it out.
:"MINI BOMBERMAN - DARK
CLASSIC
ClrHome
FnOff
AxesOff
ClrDraw
0→Xmin
94→Xmax
-62→Ymin
0→Ymax
For(I,0,47
Vertical I
Vertical 94-I
End
DelVar θ
Lbl G
DelVar [A]{12,12→dim([A]
Line(26,57,74,57,0
Line(26,7,74,7,0
Line(25,8,25,56,0
Line(75,8,75,56,0
If K=22 or not(pxl-Test(34,50:Then
For(B,26,50
Line(B,56,B,8
100-B
Line(Ans,56,Ans,8
End:End
For(A,1,12
For(B,1,12
4A→C
4B→D
randInt(3,1→[A](B,A
If max(Ans={1,2:Then
Pt-Off(24+C,D-6,3
Pt-On(24+C,D-6
End
If Ans=3
Then
Pt-Off(24+C,D-6,2
Pt-Off(24+C,D-6
End
End
End
0→[A](1,1
Pt-On(28,10,2
Pt-On(28,10
0→[A](12,12
Pt-On(72,54,2
Pt-On(72,54
0→[A](12,11
Pt-On(68,54
Pt-On(68,54,2
0→[A](11,12
Pt-On(12,11
0→[A](1,2
Pt-On(32,10,2
Pt-On(32,10
0→[A](2,1
Pt-On(28,14,2
Pt-On(28,14
0→W
Ans→Z
28→U
10→V
DelVar L30→T
Lbl 0
DelVar DDelVar KPt-Off(U,V,3
While not(D)not(sum(K={21,22,45,105
DelVar D
Repeat Ans or D
T-L→T
If not(Ans:1→D
getKey→K
End
If D:Goto ED
If sum(K={21,22,45,105:Goto ED
Pt-On(U,V,3
U+4(K=26 and pxl-Test(abs(V),U+3))-4(K=24 and pxl-Test(abs(V),U-3→U
V+4(K=25 and pxl-Test(abs(V)-3,U))-4(K=34 and pxl-Test(abs(V)+3,U→V
Pt-Off(U,V,3
If U=72 and V=54:1→D
Lbl ED
End
If U=72 and V=54:Goto W
If max(K={21,105:Goto S
If K=22:Goto G
If K=45
Then
ClrDraw
ZStandard
ZInteger
DelVar [A]ClrHome
Return
End
Lbl D
DelVar S
For(I,1,20
Pt-Change(W-1,Z+1
Pt-Change(W-1,Z-1
Pt-Change(W+1,Z+1
Pt-Change(W+1,Z-1
End
Pt-On(W,Z,2
If WZ
Then
If W=U and Z=V:Goto L
End
If W<72
Then
If [A](abs((62-abs(Z))/4-14),(W/4)-5)≠3
Pt-On(W+4,Z,2
If W+4=U and Z=V:Goto L
End
If W>28
Then
If [A](abs((62-abs(Z))/4-14),(W/4)-7)≠3
Pt-On(W-4,Z,2
If W-4=U and Z=V:Goto L
End
If Z>54
Then
If [A](abs((62-abs(Z))/4-14)+1,(W/4)-6)≠3
Pt-On(W,Z-4,2
If W=U and Z-4=V:Goto L
End
If Z<10
Then
If [A](abs((62-abs(Z))/4-14)-1,(W/4)-6)≠3
Pt-On(W,Z+4,2
If W=U and Z+4=V:Goto L
End
DelVar L30→T
Goto 0
Lbl S
If L=1:Goto 0
1→L
U→W:V→Z
Pt-Off(W,Z,2
Goto 0
Lbl W
For(I,27,35
Line(28,I,72,I,0
End
Text(28,44,"WIN
θ+1→θ
Pt-Off(Ans,60
Pause
Goto G
Lbl L
End
For(I,27,35
Line(28,I,72,I,0
End
Text(28,42,"LOSE
Pause
DelVar θLine(0,60,94,60
Goto G
https://pasteboard.co/Ic0keRF.png
EDIT: I added the .8xp file to the forum attachments.
Hewwo, my name is Achak Claw. I was formerly BioHazard.
Bruh this is actually epic. Great job :)
I'll add it to the actual link and add some creds
EDIT: Also thanks to Trenly for fixing memory leaks :)
I have a few concerns. First, the Ymin should be -62, not 62. The matrix takes also takes a lot longer to load than the original and gives me an invalid dim on Line 95 before it can fully load. I can't seem to fix that error, so can't see if there's any other bugs.
Note: Was using the typed code
Edit: Seems like all your commands are missing negatives in the typed version. You may want to double check you have everything typed correctly.
Does the download work correctly? I reset WabbitEmu, and I sent it to it. It looks like it works correctly.
https://pasteboard.co/Ic0Igs2.gif
Hewwo, my name is Achak Claw. I was formerly BioHazard.
The download works fine, its the typed version thats not working. All your negative signs disappeared.
Heh. I opened it in TI-Connect CE, so guess I need to check for negatives before uploading then. :p
Hewwo, my name is Achak Claw. I was formerly BioHazard.
woorks great! had lots of fun
DoodleDill21
Thank you, I'm glad someone enjoyed my version of Battlesquid's version of the game. PM me if you have suggestions.
Hewwo, my name is Achak Claw. I was formerly BioHazard.