Jump to content

pmgraphics

Members
  • Content Count

    172
  • Joined

  • Last visited

Community Reputation

11 Good

About pmgraphics

  • Rank
    Chopper Commander

Recent Profile Visitors

1,435 profile views
  1. pmgraphics

    Quest

    QUEST -Object: rescue the maiden from the dungeon -Get the magic key to complete three tasks. 1)Release the maiden from her cell. 2)Hit the monster enough to use the key to open the wall to reveal the beast. 3)Hit the beast three times to escape the dungeon. -You must complete the tasks before the maiden runs out of life. -Hitting the dungeon walls or the sprawling tentacles reduces your armour. -Being hit by the monster or the beast also reduces your armour.
  2. Is there a definitive table that provides all the correct values to use when use poke and color to display a character as a certain color register?
  3. So 250 worked to crate a pink boarder. I was using the attached atari ascii code list, which color registers 0,1,2 worked but not 3. Is there a document out there that sorts this all out with what values work with what conditions like poke and color plot? thanks ascii_atascii_table.pdf
  4. I have redefined characters to use as graphics. The following code creates my border using the letter Z redefined in blue. 115 COLOR 218:PLOT 0,0:DRAWTO 0,23:DRAWTO 19,23:DRAWTO 19,0:DRAWTO 0,0 I can use COLOR 90 (orange), 122 (green), and 218 (blue) for color registers 0, 1, and 2. If I use COLOR 186 for color register 3 (inverse lower case) a blue colon is printed and not the red/pink redefined letter Z. ?#6;"inverse-lower-z" creates a red/pink border piece. How do you use color register 3 (186 in this case) in the above code to create a border with the redefined character z? Thanks
  5. I'm working a game I made as a kid that uses PMG. I detect collisions with the PMG players and the play field by detecting collisions with color registers 0, 1 and 2 of the redefined characters in graphics mode 17. Is it possible to detect a fourth item that uses color register 3? Or better, is it possible to detect the ASCII value of the character that the PMG player hits so you are not limited to only 3 different collision scenarios? Player0 check collision with any upper case or inverse upper case characters IF PEEK(53252)=1 OR PEEK(53252)=4 THEN ... Player2 check collision with any lower case characters IF PEEK(53254)=2 THEN ...
  6. pmgraphics

    Shoot

    SHOOT -OBJECT: INCREASE POWER BY SHOOTING POWER PODS TO CREATE A HOLE IN THE MINE COLUMN, WHILE NOT HITTING THE MINES, AND THEN SHOOTING A LASER BEYOND THE MINES TO COMPLETE THE WAVE. -TRACK YOUR RISING POWER (P), THE MINE COLUMN RE-ENERGIZE (M), AND THE WAVE OVERRUN INDICATOR (W). -DIFFICULTY IS DETERMINED BY SETTING THE P (3,5,6), THE M (7,6,5), AND THE W (9,8,7). -OVERTIME THE STORED ENERGY CHARGES THE SPECIAL WEAPON, AN EMP. -WHEN THE SHIP TURNS YELLOW, THE EMP IS READY FOR USE BY PRESSING 'B'.
  7. In this situation I need to clear the keyboard to prevent "stored" key press. Since the player only uses the key press at certain times, if pressed when the game is not ready for it, the moment it is ready the condition is triggered since the key press was waiting in the buffer, and executes instantly. that was one reason why I had a one-liner starting with the poke 764,255, so the keyboard was cleared always prior to peeking, but as noted that was very unresponsive, thus I moved it to the top of the loop which improved response time. is there another way to not have a buffered key press?
  8. After reading the inkey thread I placed the following between my reading the trigger and reading the stick, within my main game loop. It works but it takes about 3 seconds of holding down the space bar to be detected. Other code in the loop executes near instantly. TR=PEEK(644) IF TR=0 THEN GOSUB 200 ... POKE 764,255:IF WC>0 THEN EMP=PEEK(764):IF EMP=33 THEN GOTO 815 STK=PEEK(632) ... uPDATE: I moved the POKE 764,255 to the start of my main game loop instead of just before the peek, and now it detects the key press immediately.
  9. I have a small graphics program that uses the below OPEN statement, and the program runs until a key is pressed. Once a key is pressed the goto is executed to return to the user to the menu for another run. 680 U=1:OPEN #1,4,0,"K:":GET #1,X:CLOSE #1 690 PUT #6,125:GOTO 90 In my program I wanted a similar thing where if I press the space bar during play something happens. I included the following 55 IF WC>0 THEN OPEN #1,4,0,"K:":GET #1,EMP:CLOSE #1 56 IF EMP=32 THEN GOTO 815 but once WC is greater than zero all programming halts and waits for input from the keyboard instead of waiting in the background for a key to be pressed. Pressing the space bar does trigger the coded at line 815, but then returns to waiting for input, instead of continuing the program. My goal is to use the space bar during game play to trigger the event as programmed at line 815 and to keep game play going, like Atari Defender.
  10. I was able to incorporate the improved 🕹️ routine into my games and play has greatly improved.
  11. The revised player movement routine works great. When checking for a collision with another character I put the peek check at line 48, but there was no detection. After moving the peek check to line 32 it then detected the collision. Is this how it works? Other game logic goes prior to joystick read, but checking for collisions with peek needs to be prior to the poke statement? 5 GR.17 10 I=0:Y=10:SCRI=19:SCRY=23 15 SCREEN=PEEK(88)+256*PEEK(89) 17 ME=SCREEN+200:DI=0:DY=1 30 OLDME=ME:ME=SCREEN+I+20*Y 32 IF PEEK(ME)=39 OR PEEK(ME)=52 THEN POS.2,2:?#6;PEEK(ME) 35 IF DI OR DY THEN POKE OLDME,0:POKE ME,202 40 TR=PEEK(644) 47 IF TR=0 THEN GOSUB 200 48 REM IF PEEK(ME)=39 OR PEEK(ME)=52 THEN POS.2,2:?#6;PEEK(ME) 49 STK=PEEK(632) 50 DI=(STK=7)*(I<SCRI)-(STK=11)*(I>0) 55 DY=(STK=13)*(Y<SCRY)-(STK=14)*(Y>0) 82 Y=Y+DY:I=I+DI 100 GOTO 30 200 POS.5,10:? #6;"TRIGGER" 205 RETURN
  12. if I understand you correctly, is this the right order of the code? -I moved the play drawn after the joystick is read, from drawing before reading the joystick. -I placed the trigger after the player is drawn 5 GR.17 10 I=0:Y=10:SCRI=19:SCRY=23 15 SCREEN=PEEK(88)+256*PEEK(89) 40 STK=PEEK(632):TR=PEEK(644) 45 ME=SCREEN+I+20*Y:POKE (ME),202 47 IF TR=0 THEN GOSUB 200 50 DI=(STK=7)-(STK=11) 55 DY=(STK=13)-(STK=14) 60 Y=Y+DY:I=I+DI 62 IF DY=1 OR DI=1 OR DI=-1 OR DY=-1 THEN POKE (ME),0 65 IF I>=SCRI THEN I=SCRI 70 IF I<=0 THEN I=0 75 IF Y>=SCRY THEN Y=SCRY 80 IF Y<=2 THEN Y=2 85 REM IF STK<>15 THEN POKE (ME),0 100 GOTO 40 200 POS.5,10:? #6;"TRIGGER" 205 RETURN
  13. This works well for diagonal. I just recently figured it out. 50 DI=(STK=5 OR STK=6 OR STK=7)-(STK=9 OR STK=10 OR STK=11) 55 DY=(STK=5 OR STK=9 OR STK=13)-(STK=6 OR STK=10 OR STK=14) What I am trying to resolve is, upon release of an arrow key (using Altirra), more often then most the player does not stop at that spot but usually moves one more space in the direction you were travelling. Thus for my game that requires stopping at exact positions, this problem makes it very difficult.
  14. Does the code only work in turbo basic? I'm getting errors on both j and k lines at the & symbol.
  15. In the code below is it better to use IF STK<>15 THEN POKE (ME),0 or line 62, to remove the player after movement to a new spot? Also side question: how do I edit lines 50 and 55 to incorporate diagonal movement? 5 GR.17 10 I=0:Y=10:SCRI=19:SCRY=23 15 SCREEN=PEEK(88)+256*PEEK(89) 40 ME=SCREEN+I+20*Y:POKE (ME),202 45 STK=PEEK(632):TR=PEEK(644) 50 DI=(STK=7)-(STK=11) 55 DY=(STK=13)-(STK=14) 60 Y=Y+DY:I=I+DI 62 IF DY=1 OR DI=1 OR DI=-1 OR DY=-1 THEN POKE (ME),0 65 IF I>=SCRI THEN I=SCRI 70 IF I<=0 THEN I=0 75 IF Y>=SCRY THEN Y=SCRY 80 IF Y<=2 THEN Y=2 85 REM IF STK<>15 THEN POKE (ME),0 90 IF TR=0 THEN GOSUB 200 100 GOTO 40 200 POS.5,10:? #6;"TRIGGER" 205 RETURN Thanks
×
×
  • Create New...