https://cerbyo.itch.io/pico1k-pong-pico1kong-6minshard1024chars Play Either: (1)Above; (2)Download; (3)Own Pico8? Copy/p code below. Options 2&3 have improved performance and support wasd controls. Pico1k *PONG* (/ΛPΛico1:KONG/) ~6mins/hard/1024chars Controls (p0 1/2):
The Story so far... You lost your head in the war of 1812. Fortunately, the wiki of the future was poorly edited and you were able to resurrect due to the erroneous nature of the parallelograms wHO PLAN TO DESTROY THE WORLD! Takeup arms once again, for the last time, in the first-ever epic battle known simply as *PONG*. Gameplay: Defeat the parallelograms by getting your timeball through their defenses 10 times. If they get theirs through yours 10 times...well then that's bad and time will forever render as slow as blender 2.0. Mechanics: Your paddle can be thought of as a flat surface with a center dividing it into a left and right side. The paddle will return the ball based on the location of impact on this flat surface. Hitting the exact center will send the ball straight-up (i.e. gamestart). Hits further from the center will increase the angle of reflection to a max of 45degrees in the right/left direction depending on the point of impact. *Note: The angle is always based on where the ball makes contact; the paddle's speed has no significant effect on the angle. Variables like the paddle hit-speed will increase as matches persist and you near closer to 10 points, be careful. Score is '(score-enemy_score)/10'. A max-score of 10/10, and min-score of 1/10 may be achieved. Rendering time()<=blender_renderspeeds will yield a zero; SO SAY WE ALL! The score to beat is 8/10. Post your best in the comments. Techniques:
Tips: *Your points affect the gamestate (faster/harder), enemy points don't. Point 1:
Point 2-5:
Point 6-8:
Point 9-10
Code:
x=54y=124π±=0π=0s=0β=54βͺ=1β½=0β§=0q=62w=13k=0j=1h=0d=1o=0i=rnd r=rectfill _set_fps(60)::g::b=mid(.125,atan2(q-x-8,w-y-8),.375)n=mid(.125,atan2(q-β-8,w-βͺ-8),.375)p=1+s/7a=i(9)e=1+s/7 if(btn(0)and x>1)x-=1.3π±+=1/90else π±=0 if(btn(1)and x<110)x+=1.3π+=1/90else π=0 if(x<1)x=1 if(h>40)h=40 if β§<=0and j<0then if(a>=.02)d=1else d=-1β§=3o=28end if(β§>0)β§-=1 if(q>(β+8))β+=e*d if(q<(β+8))β-=e*d if(β>109)β=109 if(β<2)β=2 if(q>124)q=124k*=-1?"\ag0" if(q<3)q=3k*=-1?"\ag0" if w<5then if(q+2>=β and β+16>=q-2)w=5h+=1j=-(p+h/15)*sin(n)k=-(p+h/10)*cos(n)?"\a00#0c" end if w>123then if(q+2>=x and x+16>=q-2)w=124h+=1j=(p+h/15)*sin(b)*(1+π±+π)k=(p+h/10)*cos(b)*(1+π±+π)?"\af-1" end if(w>128)w=63q=i(121)+5j=.5k=i(s)-s/2β½+=1h=0?"\a00#.dc" if(w<0)w=63q=63j=1k=i(1)-.5s+=1h=0?"\a<<gat-9-gat" q+=k w+=j cls(14)r(1,0,126,127,1)r(x,y,x+16,126,11)r(β,βͺ,β+16,3,8)?"β ββ ",β-3,βͺ-2,8 ?"β+β",β-1,βͺ-1,7 if(o>0)o-=1?"β β",β-1,βͺ-1,8 ?s,6,5,11 ?β½,118,118,8 ?"β",q-3,w-2,9 if s>9or β½>9then::_::cls()?"β"..mid(0,s-β½,10).."/10",50,61,8 flip()goto _ end flip()goto g Author Note: This game was a side-experiment to help me develop an accurate bullet-reflection method. I hope to implement this into the top-down rpg shooter I'm working on. To that end, it is also my 2nd game-entry in the Sept2021 #pico1k #gamejam https://itch.io/jam/pico-1k/entries. My favourite parts were writing these words and testing the game. Contract Offender 3, will be out in another week, maybe. More free games on my dashboard/profile. Twitter: https://twitter.com/Cerbyo1. My twitter is 14+/political/offensive/anime/swear-free. |