Circuit Swamp

News Projects Techniques

SharpShooter

SharpShooter

Perhaps it began with Abe Lincoln's election to president in the autumn of 1860, although differences regarding the necessity of slavery had been growing for a while between south and north; The industrialised north not understanding the need for such labour on our cotton plantations. Lincoln's victory sparked South Carolina's secession from the Union, quickly followed by the other southern states. We now have our own president, Jefferson Davis, of the Confederate States of America.

About SharpShooter

SharpShooter is a Java application written for the Light Weight Java Gaming Library (LWJGL) 16k contest at www.javagaming.org.

The objective is to produce a cross-platform (Windows, Mac, Linux) game using the LWJGL. The jar archive containing the finished application must be less than 16k in size.

Preserving the southern way of life is not without sacrifice. In the summer of 1861 Lincoln ordered General Irving McDowell to advance upon our Confederate forces in Virginia. Battle was joined at Bull Run, with the Union gaining an initial advantage. Then the Confederate armies of Generals Pierre G.T. Beauregard and Joseph E. Johnston broke through, routing the unionists. Since then our fortunes have been mixed with victories under General Robert E. Lee at Fredericksburg and Chancellorsville being more then offset with the disaster at Gettysburg in June of 1863.

Now here we are a year later at Kennesaw Mountain in Georgia under the command of General Joseph E. Johnston. The Union army is somewhere to the north. The attack will becoming soon.

Controls

Rotate Camera:  Move Mouse or Right Controller Joystick
Move Player:    Cursor Keys or Left Controller Joystick
Fire Weapon:    Left Mouse Click or Controller Buttons
Change Weapon:  Right Mouse Click, RETURN Key or Controller Btns

Start Game:     SPACE Key
Quit Game:      ESC Key

Mouse Sensitivity:
- Low           F1 Key
- Normal        F2 Key
- High          F3 Key

Screen
- Windowed      F6 Key
- Fullscreen    F7 Key

Source Code

To compile the source you will need the Java SDK (1.4.2 or higher). When running the programs, the working directory must be set to the directory containing the program files.

  • Build and execute Compress.java. This builds the resource datafile d.dat.
  • Build and execute G.java. You should have a working game.
    • This distribution only contains the windows native libraries. If you are developing on linux or OS X, please download the appropriate libraries from lwjgl.org.
    • Ensure that the classpath includes lwjgl.jar and lwjgl_util.jar.
  • The game will be larger than 16k unless you use an obfusticator such as Proguard on the compiled jar and then re-zip with maximum compression with a tool such as 7zip.

License

Copyright © 2005, Alan Waddington
All rights reserved.

Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:

  • Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
  • Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
  • The names of its contributors may not be used to endorse or promote products derived from this software without specific prior written permission.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.