Skip to content

Commit

Permalink
Initial import from local Subversion.
Browse files Browse the repository at this point in the history
  • Loading branch information
dozingcat committed Nov 20, 2010
1 parent bfed6c4 commit 4606b8d
Show file tree
Hide file tree
Showing 39 changed files with 3,789 additions and 0 deletions.
19 changes: 19 additions & 0 deletions AndroidManifest.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android" android:installLocation="auto"
package="com.dozingcatsoftware.bouncy"
android:versionCode="1"
android:versionName="1.0">
<application android:icon="@drawable/icon" android:label="@string/app_name" android:theme="@android:style/Theme.NoTitleBar.Fullscreen" android:debuggable="true">
<activity android:name=".BouncyActivity"
android:label="@string/app_name" android:configChanges="keyboard|keyboardHidden|orientation" android:screenOrientation="portrait">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>

<activity android:name="AboutActivity"></activity>
</application>
<uses-sdk android:minSdkVersion="4" />

</manifest>
674 changes: 674 additions & 0 deletions COPYING

Large diffs are not rendered by default.

11 changes: 11 additions & 0 deletions README
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
Vector Pinball is a pinball game for Android devices. It is released under
version 3 of the GPL; see "COPYING" for the license text.

The GitHub project page is: https://github.com/dozingcat/vectorpinball/

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.

Vector Pinball includes the libgdx library by Bad Logic Games: http://www.badlogicgames.com/wordpress/?page_id=307. libgdx is used under the terms of Version 2.0 of the Apache License, available at http://www.apache.org/licenses/LICENSE-2.0.
11 changes: 11 additions & 0 deletions default.properties
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# This file is automatically generated by Android Tools.
# Do not modify this file -- YOUR CHANGES WILL BE ERASED!
#
# This file must be checked in Version Control Systems.
#
# To customize properties used by the Ant build system use,
# "build.properties", and override values to adapt the script to your
# project structure.

# Project target.
target=android-8
33 changes: 33 additions & 0 deletions gen/com/dozingcatsoftware/bouncy/R.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
/* AUTO-GENERATED FILE. DO NOT MODIFY.
*
* This class was automatically generated by the
* aapt tool from the resource data it found. It
* should not be modified by hand.
*/

package com.dozingcatsoftware.bouncy;

public final class R {
public static final class attr {
}
public static final class drawable {
public static final int icon=0x7f020000;
}
public static final class id {
public static final int scoreView=0x7f060000;
public static final int worldView=0x7f060001;
}
public static final class layout {
public static final int about=0x7f030000;
public static final int main=0x7f030001;
}
public static final class raw {
public static final int field_layout=0x7f040000;
}
public static final class string {
public static final int about_menu_item=0x7f050002;
public static final int about_text=0x7f050001;
public static final int app_name=0x7f050000;
public static final int end_game_menu_item=0x7f050003;
}
}
Binary file added libs/armeabi/libandroidgl20.so
Binary file not shown.
Binary file added libs/armeabi/libgdx.so
Binary file not shown.
Binary file added libs/gdx.jar
Binary file not shown.
Binary file added res/drawable-hdpi/icon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added res/drawable-ldpi/icon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added res/drawable-mdpi/icon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
16 changes: 16 additions & 0 deletions res/layout/about.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
<?xml version="1.0" encoding="utf-8"?>

<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="fill_parent">

<TextView
android:text="@string/about_text"
android:autoLink="web|email"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:includeFontPadding="true"
android:layout_weight="1"/>


</FrameLayout>
20 changes: 20 additions & 0 deletions res/layout/main.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
>
<com.dozingcatsoftware.bouncy.ScoreView
android:id="@+id/scoreView"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:layout_weight="9"
/>

<com.dozingcatsoftware.bouncy.FieldView
android:id="@+id/worldView"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:layout_weight="1"
/>
</LinearLayout>
260 changes: 260 additions & 0 deletions res/raw/field_layout.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,260 @@
[
{
"width": 20,
"height": 30,

"delegate": "Field1Delegate",
"targetTimeRatio": 2.5,
"gravity": 4.0,

"numballs": 3,
"ballradius": 0.5,
"ballcolor": [192, 192, 224],
"launch": {"position": [19.4, 3.0], "velocity": [0, 15.4], "random_velocity": [0, 0.6]},

"elements": [
"Strings in this section are treated as comments and ignored.",
"All field elements except for flippers are defined in this section.",
"Each element is a JSON object with a mandatory class property to indicate type",
"and type=specific additional attributes. The element classes are defined",
"in the com.dozingcatsoftware.bouncy.element package.",

"launch rail",
{"class": "WallElement", "position": [18.7, 0.1, 18.7, 23]},
{"class": "WallElement", "position": [19.9, 0.1, 19.9, 23]},

"main outside arc",
{
"class": "WallArcElement",
"center": [10,23],
"xradius": 9.9,
"yradius": 7,
"minangle": 0,
"maxangle": 180,
"segments": 30
},

"right inside arc",
{
"class": "WallArcElement",
"center": [10,23],
"xradius": 8.6,
"yradius": 5.6,
"minangle": 0,
"maxangle": 54,
"segments": 12
},

"left inside arc, upper",
{
"class": "WallArcElement",
"center": [10,23],
"xradius": 8.1,
"yradius": 5.6,
"minangle": 110,
"maxangle": 180,
"segments": 12
},

"left outside arc, outer",
{"class": "WallArcElement", "center": [6.246, 23], "xradius": 6.146, "yradius": 7.778, "minangle": 180, "maxangle": 225},
"left outside arc, inner",
{"class": "WallArcElement", "center": [6.246, 23], "xradius": 4.346, "yradius": 5.978, "minangle": 180, "maxangle": 225},

"path along right edge",
{"class": "WallPathElement", "positions": [[17.2, 12.5], [17, 15], [14.8, 21.4], [15.05, 24.5], [15.05, 27.53]]},

{"class": "WallElement", "position": [0.1, 0.1, 18.7, 0.1], "color": [0,0,0], "kill": true},
{"class": "WallElement", "position": [18.7, 0.1, 19.9, 0.1]},

"left bottom",
{"class": "WallElement", "position": [0.1, 4, 6, 1]},
"right bottom",
{"class": "WallElement", "position": [18.7, 4, 12.7, 1]},

"left side",
{"class": "WallElement", "position": [0.1, 4, 0.1, 10], "name": "left border"},

"above left outlane",
{
"class": "WallArcElement",
"center": [3.1,10],
"xradius": 3.0,
"yradius": 3.0,
"minangle": 120,
"maxangle": 180,
"segments": 8
},
{"class": "WallElement", "position": [1.6, 12.5, 1.9, 17.5]},

"left outlane",
{"class": "WallElement", "position": [1.45, 8.5, 1.45, 4.8]},

"right outlane",
{"class": "WallElement", "position": [17.35, 8.5, 17.35, 4.8]},
"above right outlane",
{
"class": "WallArcElement",
"center": [15.7,10],
"xradius": 3.0,
"yradius": 3.0,
"minangle": 0,
"maxangle": 60,
"segments": 8
},

"flipper lanes",
{"class": "WallElement", "position": [1.45, 4.8, 6.25, 2.3]},
{"class": "WallElement", "position": [17.35, 4.8, 12.45, 2.3]},

"ball savers, disappear when hit and reappear when drop targets are cleared, controlled by Field1Delegate",
{"class": "WallElement", "id": "BallSaver-left", "position": [0.15, 5.0, 1.35, 5.0],
"kick": 6.0, "color": [0, 255, 0], "retractWhenHit": true},

{"class": "WallElement", "id": "BallSaver-right", "position": [17.45, 5.0, 18.65, 5.0],
"kick": 6.0, "color": [0, 255, 0], "retractWhenHit": true},

"separators between top lanes",
{"class": "WallElement", "position": [9.0, 26.5, 9.0, 27.8]},
{"class": "WallElement", "position": [10.5, 26.5, 10.5, 27.8]},
{"class": "WallElement", "position": [12.0, 26.5, 12.0, 27.8]},
{"class": "WallElement", "position": [13.5, 26.5, 13.5, 27.8]},

"ledges for right drop targets",
{"class": "WallElement", "position": [17.0, 15.0, 16.811785056743986, 14.932360254767369]},
{"class": "WallElement", "position": [16.594161528604218, 16.129289659536088, 16.405946585348204, 16.061649914303459]},
{"class": "WallElement", "position": [16.188323057208436, 17.258579319072176, 16.000108113952422, 17.190939573839547]},
{"class": "WallElement", "position": [15.782484585812654, 18.387868978608267, 15.59426964255664, 18.320229233375638]},
{"class": "WallElement", "position": [15.376646114416872, 19.517158638144355, 15.188431171160858, 19.449518892911726]},

"right drop targets",
{"class": "DropTargetGroupElement", "id": "DropTargetRightSave", "color": [0, 255, 0], "score": 500, "reset": 2.0,
"positions": [[16.77796518412767, 15.026467726395376, 16.43976645796452, 15.96754244267545],
[16.372126712731887, 16.155757385931466, 16.033927986568738, 17.09683210221154],
[15.966288241336107, 17.285047045467554, 15.628089515172954, 18.226121761747628],
[15.560449769940325, 18.414336705003645, 15.222251043777172, 19.355411421283719]]},

"ledges for left drop targets",
{"class": "WallElement", "position": [1.6479138325823575, 13.298563876372622, 1.8475548016755132, 13.286585418227032]},
{"class": "WallElement", "position": [1.7197845814558936, 14.496409690931557, 1.9194255505490494, 14.484431232785967]},
{"class": "WallElement", "position": [1.7916553303294298, 15.694255505490492, 1.9912962994225856, 15.682277047344902]},
{"class": "WallElement", "position": [1.8635260792029658, 16.892101320049427, 2.0631670482961217, 16.880122861903839]},

"left drop targets",
{"class": "DropTargetGroupElement", "id": "DropTargetLeftSave", "color": [0, 255, 0], "score": 500, "reset": 2.0,
"positions": [[1.853544030748308, 13.38640590277361, 1.9134363214762546, 14.384610748239389],
[1.9254147796218442, 14.584251717332545, 1.9853070703497908, 15.582456562798324],
[1.9972855284953803, 15.78209753189148, 2.0571778192233272, 16.780302377357259]]},

"left kicker, 60 degree angle",
{
"class": "WallElement",
"position": [3.2, 8.77, 5.7, 4.43],
"kick": 3.5,
"score": 100,
"color": [0, 0, 255]
},
"top/bottom of left kicker without kick, x goes .25 (=0.5*cos(pi/3)), y goes .43 (=0.5*sin(pi/3))",
{"class": "WallElement", "position": [2.95, 9.2, 3.2, 8.77]},
{"class": "WallElement", "position": [5.95, 4, 5.7, 4.43]},

"around left kicker",
{"class": "WallElement", "position": [2.95, 9.2, 2.95, 5.8]},
{"class": "WallElement", "position": [2.95, 5.8, 5.95, 4]},

"right kicker",
{
"class": "WallElement",
"position": [15.6, 8.77, 13.1, 4.43],
"kick": 3.5,
"score": 100,
"color": [0, 0, 255]
},
"top/bottom of right kicker without kick",
{"class": "WallElement", "position": [15.85, 9.2, 15.6, 8.77]},
{"class": "WallElement", "position": [12.85, 4, 13.1, 4.43]},

"around right kicker",
{"class": "WallElement", "position": [15.85, 9.2, 15.85, 5.8]},
{"class": "WallElement", "position": [15.85, 5.8, 12.85, 4]},

"box above bumpers with drop targets",
{"class": "WallElement", "position": [9.0, 27.9, 7.230, 28.262]},
{"class": "WallElement", "position": [9.0, 26.4, 5.95, 25.6]},
{"class": "WallElement", "position": [5.95, 25.6, 5.95, 27.85]},

"upper drop targets",
{"class": "DropTargetGroupElement", "id": "DropTargetTop", "color": [0, 255, 255], "score": 500, "reset": 2.0,
"positions": [[8.6154667066968891, 26.09237336535751, 7.7449150447446904, 25.864031945829066],
[7.261275232549024, 25.737175601646598, 6.3907235705968253, 25.508834182118154],
[5.75, 26.1, 5.75, 27.1]]},

"bumpers below top lanes",
{"class": "BumperElement", "radius": 0.85, "position": [9.5, 18], "kick": 3, "color": [0, 0, 224], "score": 500},
{"class": "BumperElement", "radius": 0.85, "position": [12.3, 21.2], "kick": 3, "color": [0, 0, 224], "score": 500},
{"class": "BumperElement", "radius": 0.85, "position": [6.5, 20.5], "kick": 3, "color": [0, 0, 224], "score": 500},
"purple bumper is extra points",
{"class": "BumperElement", "radius": 0.70, "position": [4.5, 23.5], "kick": 2.5, "color": [192, 0, 192], "score": 1000},

"rollovers for ramp shot",
{"class": "RolloverGroupElement", "id": "RampRollovers", "radius": 0.5, "score": 500, "reset": 5,
"rollovers": [{"position": [1.7, 19.5], "color": [255, 0, 0], "score": 2000},
{"position": [1.0, 23.0], "color": [0, 255, 0], "score": 3000},
{"position": [3.1, 27.0], "color": [0, 0, 255], "score": 5000},
{"position": [6.3, 28.7], "color": [255, 255, 255], "score": 10000}
]
},

"rollovers for flipper lanes",
{"class": "RolloverGroupElement", "id": "FlipperRollovers", "color": [0, 224, 224], "radius": 0.4, "score": 500, "cycleOnFlipper": true,
"rollovers": [{"position": [0.775, 7.0]},
{"position": [2.2, 7.0]},
{"position": [16.6, 7.0]},
{"position": [18.025, 7.0]}
]
},

"rollovers for top lanes",
{"class": "RolloverGroupElement", "id": "TopRollovers", "color": [0, 224, 224], "radius": 0.45, "score": 500, "cycleOnFlipper": true,
"rollovers": [{"position": [9.75, 27.2]},
{"position": [11.25, 27.2]},
{"position": [12.75, 27.2]},
{"position": [14.25, 27.2]}
]
},

"rollovers in middle for extra ball when all lit",
{"class": "RolloverGroupElement", "id": "ExtraBallRollovers", "radius": 0.5, "ignoreBall": true,
"rollovers": [{"position": [9.4, 13], "color": [224, 0, 0]},
{"position": [12.0, 11.5], "color": [224, 224, 0]},
{"position": [12.0, 8.5], "color": [0, 224, 0]},
{"position": [9.4, 7], "color": [0, 224, 224]},
{"position": [6.8, 8.5], "color": [0, 0, 224]},
{"position": [6.8, 11.5], "color": [224, 0, 224]},
{"position": [9.4, 10], "radius": 1.5, "color": [224, 224, 224]}
]
}

],

"flippers": [
{
"position": [6.35, 2.2],
"length": 2.5,
"minangle": -20,
"maxangle": 20,
"upspeed": 7,
"downspeed": 3
},
{
"position": [12.35, 2.2],
"length": -2.5,
"minangle": -20,
"maxangle": 20,
"upspeed": 7,
"downspeed": 3
}
]

}
]
7 changes: 7 additions & 0 deletions res/values/strings.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<string name="app_name">Vector Pinball</string>
<string name="about_text">Vector Pinball 1.0\n© 2010 Brian Nenninger\nMore info: www.dozingcatsoftware.com/VectorPinball\nComments and bug reports: bnenning@gmail.com\n\nTouch the screen to start a new game, launch a ball if one is not in play, and activate both flippers.\n\nGame Rules:\n- Light all the cyan rollovers in the top or bottom lanes to advance the score multiplier. All points you earn will be multiplied by this amount.\nShooting the left ramp will also advance the multiplier.\n- The game starts with ball savers in the left and right outlanes, which disappear when used. Hit all drop targets on the left or right side to restore them.\n- Hitting any group of drop targets will activate the next light in the center of the field. When the large white central light is activated, shoot the left ramp for an extra ball.\n\nVector Pinball is open source; the code is at https://github.com/dozingcat/Vector-Pinball</string>
<string name="about_menu_item">About/Help</string>
<string name="end_game_menu_item">End Game</string>
</resources>
Loading

0 comments on commit 4606b8d

Please sign in to comment.