Jump to content
IGNORED

an idea for a game


arcade_lights

Recommended Posts

Hey guys. I have an idea for a new game. The concept is unusual so I could use some tips and links. You know how E.T. has to look for specific "power zones" to execute a power? Well, in my game, the main protagonist enters a nightclub, and he needs to dance on a podium in order to attract a partner. However, he must find the right place to dance before the timer runs out. The faster he finds it, the more points he gets, and if the time runs out it's game over. This place has to be random in every new game. I could also use some links about energy bars and timers, if it's not too much trouble. Thanx in advance.

Link to comment
Share on other sites

atariage.com/forums/topic/205648-how-were-the-power-zones-done-in-et-and-can-it-be-done-with-batari-basic/

 

pfscore bars

 

If you want a pfscore bar to tick down every so many seconds or minutes, you could use two counters. Since a variable can only count up to 4 seconds before the limit is reached (60 = 1 second, 120 = 2 seconds, 180 = 3 seconds, 240 = 4 seconds), you'll have to use a second variable if you want to go higher. Say you want your score bar to tick down once a minute, you could check your counter to see if it is equal to or greater than 240, then add 1 to your other counter. You'd clear the first counter and when it's equal to or greater than 240, you'd add 1 to your other counter again and it would go on like that until the second counter is equal to or greater than 15 (4 seconds x 15 = 1 minute).

Link to comment
Share on other sites

Thank you for the info. I've been working on it for the past few days and I have the basics done which consist of 3 screens. It's supposed to be like a fighting game. Two friends dance in the club, than they get tired and go to hang out at home and get into a fight. Now, I have several problems.

 

1. On the first screen the commands work fine, but on the second and third screen commands get kinda "frozen". If I move player0 left or right he only moves for 1 unit only. A beginner mistake, but I have no idea what I'm doing wrong, I suppose it's something about loop.

 

2. The pfscore2 in the second screen is supposed to drain slowly as the two players dance, but it either goes down all at once as I keep the joy0fire pressed, or if I put the command inside the loop it just decrements one health unit, and when I release the button it just goes back to full.

 

3. On the third screen (the apartment) I have the same problems as described under section 2. Here I also need some help. Player1 is supposed to run around so I used rand command on player1x, but he just moves way too fast. Also pfscore1 is supposed to be a timer and thick down. I know you already explained this to me Random Terrain, but I'm not quite sure I understand what I'm supposed to do. I apologize for for being such a noob :D If you could give me an example equation that would be great. So, in the 3rd screen, player0 is supposed to beat up player1, using static missile0 in his hand, before the timer runs out.

 

Thanx in advance guys. All help is highly appreciated. Btw I apologize for bas file being a little messed up, I did my best to avoid it.

club2.bas

Edited by arcade_lights
Link to comment
Share on other sites

Awesome. Thanx a lot Lewis. It's almost finished. Just a few more things. I also need a timer on the 3rd screen, just like you did on the 2nd screen. I tried copy pasting your code in the 3rd screen, but for some reason it gives me an error and won't compile. Also, I added score, as you can see in the bas file below. The point is to score as much as possible by dancing in the second screen and attacking in the 3rd screen (I added a static missile0 in the 3rd screen which is like a weapon or something). There is a problem though. On the second screen you gain points by pressing joy0fire and joy0up, but the score just jumps trough the roof, so there's no point in pressing several times, one could just keep the button pressed. What I need is a restrainer for these two buttons on the 2nd screen, but again, whenever I tried to insert it in the code, the program wouldn't compile. Also, in the 3rd screen, would it be possible for player1 to run around independently from player0? Something like those girls in Wizard's Texas chainsaw massacre or something similar? If he moves like this, I can just approach and keep the fire button pressed and gain points without trouble. And in the end, I had an idea for the game over screen. Would it be possible that when the timer runs out windows in the apartment start changing colors (red and blue, it's like cops outside of the apartment). If not I can just do a regular game over screen.

club4.bas

Edited by arcade_lights
Link to comment
Share on other sites

Arcade_Lights,

 

I will work this today / tomorrow. I think I can accomplish what you are looking for. I still consider myself a novice programmer compared to the others in the Forum. My programming style is from the Old Basic Style in the 80's. I learned this on the old Apple II Computers when I was a kid. Since I have been here I have adapted most of my programming style off of RT's. I think I can complete what you are looking for or come very close to it (and may be create an alternate version with some extras in it I think you might like or use to learn from).

 

To copy and paste code to another location. I can answer that one without looking at the code.

 

Skip_Timer (original code)

 

if Time_Counter < 1 then Skip_Timer1

 

Skip_Timer1 ; pasted code etc.

 

These need new names or the compiler / program wont know where to go. Also if you notice in the kernel setup i put "set romsize 32k" so you will have 8 banks. If you were coping and pasting code it would be similar to the above.

 

bank 2

 

if Time_Counter < 1 then Skip_Timer2 bank3 ; makes the program jump to bank3

 

; "timer code info"

 

bank 3

 

Skip_Timer2 ; this is inside bank3

Link to comment
Share on other sites

Arcade_Lights,

 

You would need to do something like:

 

if pfscore2 = o then pfscore=0

 

or jump somewhere etc.

 

Also pfscore goes if I am correct: 0, 7, 14, 21 ......255. Where as 0 is 0; 7 is actual 1; 14 is actually 2 etc.

 

Some programmers use the below, but I'm not 100% sure how it works. Bogax, RT, Mountain King, RevEng and others in the past have helped me with the below. I use the above code as I understand it better and more straight forward. The draw back is that many programmers like to make 4k or smaller games hence the below code saves space and is probably faster. I like to use bank switching as I have up to 32k space depending on the kernel.

 

pfscore1 = %00010101
pfscore2 = %11111111

 

working on your code now, thanks.

Link to comment
Share on other sites

Arcade_Lights,

 

I made some changes that you asked and some notes. For the Club screen you have to press fire twice to get points and up twice to get points. I have the sprite flip left or right based upon which direction. There are also boundaries. The enemy some times goes out the boundaries. The timers now work. There is the ending screen you wanted. I was working on a title screen. I saw one a while back that I am looking for that would be great for your game. Basically if flashes all the colors. I found it in the forum. I will look again and through my stuff. Still need to work last screen where they fight.Points go through the roof, but the same click twice would work from screen 2. I should have it complete later tonight. Hope this works. Also I see that you know music better that I do. That is something I plan to learn next. Any tips would be great.

 

Suggestion is that screen two has points deducted when player1 does a certain move randomly.

20180113 - Club2.txt

club2.bas.bin

Link to comment
Share on other sites

Perfect! You did it better than I imagined. I fixed the score issue in the end, I just deleted the player0-player1 collision equation. The score only goes up on missile0-player1 collision. There shouldn't be a restrainer for this screen, score should jump a little on missile0-player1 collision. You don't have to do the titlescreen, you can if you want to of course. And about music, honestly I don't know much. I just used the music and sound editor in view section, it gives you the keyboard and I just play the melody on the keyboard and click "create bas". Than I insert the music bas file in the program, but it won't always work. As you can see, I inserted the club equations somewhere in the middle of music bas file, otherwise it wouldn't work. I don't know why it works this way, I figured it out by accident when I did a game over screen for one of my previous games. What I know is this. When you play a note in music and sound editor it gives you this:

 

8,4,15
0,0,0
20
2,4,15
0,0,0
8
The numbers 20 and 8, in this case, have to do with sound duration so that's where you change the duration of notes and do the rhythm. I don' know what other numbers do, I didn't try to change them. Thanx again for all your help. As far as I'm concerned, the game is pretty much finished but if you want to add something more, any suggestions are welcome of course.
Link to comment
Share on other sites

 

The numbers 20 and 8, in this case, have to do with sound duration so that's where you change the duration of notes and do the rhythm. I don' know what other numbers do, I didn't try to change them. Thanx again for all your help. As far as I'm concerned, the game is pretty much finished but if you want to add something more, any suggestions are welcome of course.
The first set of 3 numbers is the first voice. The second set is the second voice.

 

8,4,15 --- volume0, channel0, frequency0 (volume of 8, pure tone, note of b)
0,0,0 --- volume1, channel1, frequency1 (silent)
20 --- duration of both notes (20 units)
2,4,15 (same as above but only a volume of 2
0,0,0 --- silent
8 -- duration of 8 units
When these 2 set are played it will sound like 1 continuous note that fades off.
If you make the slight change
8,4,15 --- volume0, channel0, frequency0 (volume of 8, pure tone, note of b)
8,4,19 --- volume1, channel1, frequency1 (volume of 8, pure tone, note of g)
20 --- duration of both notes (20 units)
2,4,15 (same as above but only a volume of 2)
2,4,19 (same as above but only a volume of 2)
8 -- duration of 8 units
Now it will play a chord of that fades off.
Add a set between the two set set to all zeros and a duration of 8. Now you added a rest.
8,4,15 --- volume0, channel0, frequency0 (volume of 8, pure tone, note of b)
8,4,19 --- volume1, channel1, frequency1 (volume of 8, pure tone, note of g)
20 --- duration of both notes (20 units)
0,0,0
0,0,0
8
2,4,15 (same as above but only a volume of 2)
2,4,19 (same as above but only a volume of 2)
8 -- duration of 8 units
Now it will sound like 2 chords played one after the other.
Link to comment
Share on other sites

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...