Large diffs are not rendered by default.

BIN +6.71 KB 1.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@@ -0,0 +1,13 @@
<?xml version="1.0" encoding="UTF-8"?>
<module type="JAVA_MODULE" version="4">
<component name="NewModuleRootManager" inherit-compiler-output="false">
<output url="file://$MODULE_DIR$/out/production/Shit" />
<exclude-output />
<content url="file://$MODULE_DIR$">
<sourceFolder url="file://$MODULE_DIR$/src" isTestSource="false" />
</content>
<orderEntry type="sourceFolder" forTests="false" />
<orderEntry type="inheritedJdk" />
<orderEntry type="library" name="resources" level="project" />
</component>
</module>
BIN +3.98 KB moneybag.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@@ -1,11 +1,7 @@
/Example5$1.class
/Example5$2.class
/Example5$3.class
/Example5.class
/IntValue.class
/LongValue.class
/Sprite.class
/Luncher$1.class
/Luncher$2.class
/Luncher$3.class
/Luncher.class
/Sprite.class
Binary file not shown.
Binary file not shown.
BIN -5 Bytes (100%) out/production/Shit/Sprite.class
Binary file not shown.
Empty file.
@@ -64,9 +64,9 @@ public void handle(KeyEvent e)
gc.setStroke( Color.BLACK );
gc.setLineWidth(1);

final Sprite briefcase = new Sprite();
briefcase.setImage("1.png");
briefcase.setPosition(200, 0);
final Sprite smurf = new Sprite();
smurf.setImage("1.png");
smurf.setPosition(200, 0);

final ArrayList<Sprite> moneybagList = new ArrayList<Sprite>();

@@ -94,25 +94,25 @@ public void handle(long currentNanoTime)

// game logic

briefcase.setVelocity(0,0);
smurf.setVelocity(0,0);
if (input.contains("LEFT"))
briefcase.addVelocity(-50,0);
smurf.addVelocity(-50,0);
if (input.contains("RIGHT"))
briefcase.addVelocity(50,0);
smurf.addVelocity(50,0);
if (input.contains("UP"))
briefcase.addVelocity(0,-50);
smurf.addVelocity(0,-50);
if (input.contains("DOWN"))
briefcase.addVelocity(0,50);
smurf.addVelocity(0,50);

briefcase.update(elapsedTime);
smurf.update(elapsedTime);

// collision detection

Iterator<Sprite> moneybagIter = moneybagList.iterator();
while ( moneybagIter.hasNext() )
{
Sprite moneybag = moneybagIter.next();
if ( briefcase.intersects(moneybag) )
if ( smurf.intersects(moneybag) )
{
moneybagIter.remove();
score.value++;
@@ -122,7 +122,7 @@ public void handle(long currentNanoTime)
// render

gc.clearRect(0, 0, 512,512);
briefcase.render( gc );
smurf.render( gc );

for (Sprite moneybag : moneybagList )
moneybag.render( gc );