Skip to content

Latest commit

 

History

History

paratrooper-game

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Paratrooper (game)

View shader on Shadertoy - Published on 2018-07-04

thumbnail

I made this shader because I wanted to try to create a simple but complete game on Shadertoy.

Buffer A: Game logic. As usual this code started nice, but in the end I added a lot of if-statements and it became a mess. Buffer B: Rendering of the screen (320x200). Buffer C: Encoding and decoding of bitmaps used.

So here it is: Paratrooper ("The worst IBM program of 1983").

             *Your Mission*

 Do not allow enemy  paratroopers to land
 on either side of your gun base. If four
 paratroopers  land on one  side of  your
 base,  they will overpower your defenses
 and blow  up your  gun.  After  you have
 survived the first round of helicopters,
 watch out for the jet bombers. Every jet
 pilot has a deadly aim!
 The numeric  key pad  controls  your gun
 and the firing of your bullets. Two keys
 start the gun moving:
     < and 4    counterclockwise
     > or 6     clockwise
 Using the ^ or 8 key stops  the movement
 of your gun and fires your bullets.

                 *Scoring*
     HELICOPTER or JET  .  .  10 points
     ENEMY PARATROOPER  .  .   5 points
     BOMB.  .  .  .  .  .  .  30 points

 Each bullet you fire costs you one point

    PRESS space bar FOR KEYBOARD PLAY

Shaders

Common

Source: Common.glsl

Buffer A

Source: Buffer A.glsl

Inputs

  • iChannel0: keyboard (linear, clamp, vflipped)
  • iChannel1: Buffer A (nearest, clamp, vflipped)

Buffer B

Source: Buffer B.glsl

Inputs

  • iChannel0: Buffer A (nearest, clamp, vflipped)
  • iChannel1: Buffer C (nearest, clamp, vflipped)

Buffer C

Source: Buffer C.glsl

Inputs

  • iChannel0: Buffer C (nearest, clamp, vflipped)

Image

Source: Image.glsl

Inputs

  • iChannel0: Buffer B (nearest, clamp, vflipped)

Links

License

Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License.