Hi there, I’m trying to develop a puzzle game for the calculator, and I need some help; you are supposed to travel along the bottom of the screen and catch bubbles that come out of the top of the screen. I could really use some help, because as of right now all I have it a minus sign, serving as a platform but it moves everywhere around the screen, is there anyway I can just have it move along the bottom of the screen and nothing else (I’m using the movement code found on this website; if that helps), also how do I get bubbles to fall from the top of the screen, and they switch between 0’s and O’s (Like a random array sort of thing?), and finally, how do I shoot upwards so the bubbles can stick to the top of the screen? Anyways, any help is greatly appreciated, thanks and I hope to talk to you soon. (Also for any further clarifications, I know I’m bad at explaining, I’m happy to answer any questions).
For the movement code you just need to remove the directional component for the up and down. If you’re using the homescreen you could try:
max(1,min(16,X-(K=24)+(K=26 →X
To randomly choose a character, use this code as what you are displaying. Eg: Disp sub(…
sub(“0O”, randInt(1,2),1
What exactly do you mean by “shoot up”? What are you trying to do exactly? Can you show us any of your code so far? What have you tried?
Shoot up- Kind of like Galaga in the sense where you press a button and there is a projectile that fires up, and what I’m trying to do is to have objects fall from the top of the screen, to the bottom, and then the player can catch them, and then send them up again. Also another question, is there any way to do an if statement to where “if this object reaches certain coordinates, then do this thing:” in anyway possible, kind of like an if statement?
Whatever variable you have for tracking said object's height, in this case A (and I'm assuming you are using output( or text( for this) is used below. Also, the 0 represents the top of the screen, depending on if it is the graph or home screen would change the number if this is for the bottom of the screen or any other height you want.
If A=0 //assuming that this is after you update the variable but before you would use it to display the object
Insert code here for what you want it to do.
If this If statement will run more than 1 line of code when then:
If A=0:Then //assuming that this is after you update the variable but before you would use it to display the object
Insert code here for what you want it to do.
End
Also, it would fit in with the 0's and O's if you use θ's as well ([Alpha] and [3]) which would give you three options for "bubbles."
🧟Initiating Project Horde 🧟
Awesome thank you, and do you/anyone potentially know how to make said bubbles fall from the top of the screen in a slow fashion?
Yes. You just have to use a loop to create “frames” of the game, and then you can update their location every frame, or every two frames, or every three or four or n frames.
If you want to learn how to do something like that, the Flappy Bird 2 page may be a good reference for you. Take a look over the code there and see how it works. If you have any questions on how that code works, or need more info on how to do something similar here, let me know and I can try to explain it.
Also, thank you for all your help and I will try to get the code I have so far on here; Thanks again!