diff --git a/GoneBananas/GoneBananas.sln b/GoneBananas/GoneBananas.sln
new file mode 100644
index 0000000..7b19ecf
--- /dev/null
+++ b/GoneBananas/GoneBananas.sln
@@ -0,0 +1,48 @@
+
+Microsoft Visual Studio Solution File, Format Version 11.00
+# Visual Studio 2010
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "GoneBananasiOS", "GoneBananasiOS\GoneBananasiOS.csproj", "{0F682923-EE76-4240-BBEB-56BF44B82A57}"
+EndProject
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "GoneBananasAndroid", "GoneBananasAndroid\GoneBananasAndroid.csproj", "{7B89D990-03EA-4FF4-8392-376C08E37161}"
+EndProject
+Project("{D954291E-2A0B-460D-934E-DC6B0785DB48}") = "GoneBananasShared", "GoneBananasShared\GoneBananasShared.shproj", "{7187ABEC-F6E0-4CF4-8E8C-481DBE6DA18B}"
+EndProject
+Global
+ GlobalSection(SolutionConfigurationPlatforms) = preSolution
+ Debug|iPhoneSimulator = Debug|iPhoneSimulator
+ Release|iPhoneSimulator = Release|iPhoneSimulator
+ Debug|iPhone = Debug|iPhone
+ Release|iPhone = Release|iPhone
+ Ad-Hoc|iPhone = Ad-Hoc|iPhone
+ AppStore|iPhone = AppStore|iPhone
+ EndGlobalSection
+ GlobalSection(ProjectConfigurationPlatforms) = postSolution
+ {0F682923-EE76-4240-BBEB-56BF44B82A57}.Ad-Hoc|iPhone.ActiveCfg = Ad-Hoc|iPhone
+ {0F682923-EE76-4240-BBEB-56BF44B82A57}.Ad-Hoc|iPhone.Build.0 = Ad-Hoc|iPhone
+ {0F682923-EE76-4240-BBEB-56BF44B82A57}.AppStore|iPhone.ActiveCfg = AppStore|iPhone
+ {0F682923-EE76-4240-BBEB-56BF44B82A57}.AppStore|iPhone.Build.0 = AppStore|iPhone
+ {0F682923-EE76-4240-BBEB-56BF44B82A57}.Debug|iPhone.ActiveCfg = Debug|iPhone
+ {0F682923-EE76-4240-BBEB-56BF44B82A57}.Debug|iPhone.Build.0 = Debug|iPhone
+ {0F682923-EE76-4240-BBEB-56BF44B82A57}.Debug|iPhoneSimulator.ActiveCfg = Debug|iPhoneSimulator
+ {0F682923-EE76-4240-BBEB-56BF44B82A57}.Debug|iPhoneSimulator.Build.0 = Debug|iPhoneSimulator
+ {0F682923-EE76-4240-BBEB-56BF44B82A57}.Release|iPhone.ActiveCfg = Release|iPhone
+ {0F682923-EE76-4240-BBEB-56BF44B82A57}.Release|iPhone.Build.0 = Release|iPhone
+ {0F682923-EE76-4240-BBEB-56BF44B82A57}.Release|iPhoneSimulator.ActiveCfg = Release|iPhoneSimulator
+ {0F682923-EE76-4240-BBEB-56BF44B82A57}.Release|iPhoneSimulator.Build.0 = Release|iPhoneSimulator
+ {7B89D990-03EA-4FF4-8392-376C08E37161}.Ad-Hoc|iPhone.ActiveCfg = Release|Any CPU
+ {7B89D990-03EA-4FF4-8392-376C08E37161}.Ad-Hoc|iPhone.Build.0 = Release|Any CPU
+ {7B89D990-03EA-4FF4-8392-376C08E37161}.AppStore|iPhone.ActiveCfg = Release|Any CPU
+ {7B89D990-03EA-4FF4-8392-376C08E37161}.AppStore|iPhone.Build.0 = Release|Any CPU
+ {7B89D990-03EA-4FF4-8392-376C08E37161}.Debug|iPhone.ActiveCfg = Debug|Any CPU
+ {7B89D990-03EA-4FF4-8392-376C08E37161}.Debug|iPhone.Build.0 = Debug|Any CPU
+ {7B89D990-03EA-4FF4-8392-376C08E37161}.Debug|iPhoneSimulator.ActiveCfg = Debug|Any CPU
+ {7B89D990-03EA-4FF4-8392-376C08E37161}.Debug|iPhoneSimulator.Build.0 = Debug|Any CPU
+ {7B89D990-03EA-4FF4-8392-376C08E37161}.Release|iPhone.ActiveCfg = Release|Any CPU
+ {7B89D990-03EA-4FF4-8392-376C08E37161}.Release|iPhone.Build.0 = Release|Any CPU
+ {7B89D990-03EA-4FF4-8392-376C08E37161}.Release|iPhoneSimulator.ActiveCfg = Release|Any CPU
+ {7B89D990-03EA-4FF4-8392-376C08E37161}.Release|iPhoneSimulator.Build.0 = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(MonoDevelopProperties) = preSolution
+ StartupItem = GoneBananasiOS\GoneBananasiOS.csproj
+ EndGlobalSection
+EndGlobal
diff --git a/GoneBananas/GoneBananasAndroid/Assets/AboutAssets.txt b/GoneBananas/GoneBananasAndroid/Assets/AboutAssets.txt
new file mode 100644
index 0000000..a9b0638
--- /dev/null
+++ b/GoneBananas/GoneBananasAndroid/Assets/AboutAssets.txt
@@ -0,0 +1,19 @@
+Any raw assets you want to be deployed with your application can be placed in
+this directory (and child directories) and given a Build Action of "AndroidAsset".
+
+These files will be deployed with your package and will be accessible using Android's
+AssetManager, like this:
+
+public class ReadAsset : Activity
+{
+ protected override void OnCreate (Bundle bundle)
+ {
+ base.OnCreate (bundle);
+
+ InputStream input = Assets.Open ("my_asset.txt");
+ }
+}
+
+Additionally, some Android functions will automatically load asset files:
+
+Typeface tf = Typeface.CreateFromAsset (Context.Assets, "fonts/samplefont.ttf");
diff --git a/GoneBananas/GoneBananasAndroid/Assets/Content/Sounds/tap.mp3 b/GoneBananas/GoneBananasAndroid/Assets/Content/Sounds/tap.mp3
new file mode 100644
index 0000000..6d7665a
Binary files /dev/null and b/GoneBananas/GoneBananasAndroid/Assets/Content/Sounds/tap.mp3 differ
diff --git a/GoneBananas/GoneBananasAndroid/Assets/Content/fonts/arial-22.xnb b/GoneBananas/GoneBananasAndroid/Assets/Content/fonts/arial-22.xnb
new file mode 100644
index 0000000..75be35b
Binary files /dev/null and b/GoneBananas/GoneBananasAndroid/Assets/Content/fonts/arial-22.xnb differ
diff --git a/GoneBananas/GoneBananasAndroid/Assets/Content/hd/animations/monkey.plist b/GoneBananas/GoneBananasAndroid/Assets/Content/hd/animations/monkey.plist
new file mode 100644
index 0000000..b45f18b
--- /dev/null
+++ b/GoneBananas/GoneBananasAndroid/Assets/Content/hd/animations/monkey.plist
@@ -0,0 +1,139 @@
+
+
+
+
+ frames
+
+ Banana-hd.png
+
+ frame
+ {{2,2},{44,108}}
+ offset
+ {0,0}
+ rotated
+
+ sourceColorRect
+ {{0,0},{44,108}}
+ sourceSize
+ {44,108}
+
+ frame-1.png
+
+ frame
+ {{48,2},{391,555}}
+ offset
+ {0,0}
+ rotated
+
+ sourceColorRect
+ {{0,0},{391,555}}
+ sourceSize
+ {391,555}
+
+ frame-2.png
+
+ frame
+ {{441,2},{390,553}}
+ offset
+ {0,0}
+ rotated
+
+ sourceColorRect
+ {{0,0},{390,553}}
+ sourceSize
+ {390,553}
+
+ frame-3.png
+
+ frame
+ {{833,2},{387,566}}
+ offset
+ {0,0}
+ rotated
+
+ sourceColorRect
+ {{0,0},{387,566}}
+ sourceSize
+ {387,566}
+
+ frame-4.png
+
+ frame
+ {{1222,2},{386,579}}
+ offset
+ {0,0}
+ rotated
+
+ sourceColorRect
+ {{0,0},{386,579}}
+ sourceSize
+ {386,579}
+
+ frame-5.png
+
+ frame
+ {{1610,2},{387,573}}
+ offset
+ {0,0}
+ rotated
+
+ sourceColorRect
+ {{0,0},{387,573}}
+ sourceSize
+ {387,573}
+
+ frame-6.png
+
+ frame
+ {{2,583},{389,560}}
+ offset
+ {0,0}
+ rotated
+
+ sourceColorRect
+ {{0,0},{389,560}}
+ sourceSize
+ {389,560}
+
+ frame-7.png
+
+ frame
+ {{393,583},{390,553}}
+ offset
+ {0,0}
+ rotated
+
+ sourceColorRect
+ {{0,0},{390,553}}
+ sourceSize
+ {390,553}
+
+ frame-8.png
+
+ frame
+ {{785,583},{389,557}}
+ offset
+ {0,0}
+ rotated
+
+ sourceColorRect
+ {{0,0},{389,557}}
+ sourceSize
+ {389,557}
+
+
+ metadata
+
+ format
+ 2
+ realTextureFileName
+ monkey.png
+ size
+ {2048,2048}
+ smartupdate
+ $TexturePacker:SmartUpdate:c63ac17999f746ee253cb9e63215058f:7b9d55d9c4db1e73987b80a4545fa776:c408e1678cc8476d89ba18c5256b3484$
+ textureFileName
+ monkey.png
+
+
+
diff --git a/GoneBananas/GoneBananasAndroid/Assets/Content/hd/animations/monkey.png b/GoneBananas/GoneBananasAndroid/Assets/Content/hd/animations/monkey.png
new file mode 100644
index 0000000..7aecb29
Binary files /dev/null and b/GoneBananas/GoneBananasAndroid/Assets/Content/hd/animations/monkey.png differ
diff --git a/GoneBananas/GoneBananasAndroid/Assets/Content/hd/balls.png b/GoneBananas/GoneBananasAndroid/Assets/Content/hd/balls.png
new file mode 100755
index 0000000..2ba46b5
Binary files /dev/null and b/GoneBananas/GoneBananasAndroid/Assets/Content/hd/balls.png differ
diff --git a/GoneBananas/GoneBananasAndroid/Assets/Content/hd/cloud.png b/GoneBananas/GoneBananasAndroid/Assets/Content/hd/cloud.png
new file mode 100644
index 0000000..8957f1e
Binary files /dev/null and b/GoneBananas/GoneBananasAndroid/Assets/Content/hd/cloud.png differ
diff --git a/GoneBananas/GoneBananasAndroid/Assets/Content/hd/grass.png b/GoneBananas/GoneBananasAndroid/Assets/Content/hd/grass.png
new file mode 100644
index 0000000..d8b8620
Binary files /dev/null and b/GoneBananas/GoneBananasAndroid/Assets/Content/hd/grass.png differ
diff --git a/GoneBananas/GoneBananasAndroid/GoneBananasAndroid.csproj b/GoneBananas/GoneBananasAndroid/GoneBananasAndroid.csproj
new file mode 100644
index 0000000..2621d73
--- /dev/null
+++ b/GoneBananas/GoneBananasAndroid/GoneBananasAndroid.csproj
@@ -0,0 +1,81 @@
+
+
+
+ Debug
+ AnyCPU
+ {EFBA0AD7-5A72-4C68-AF49-83D382785DCF};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}
+ 8.0.30703
+ 2.0
+ {7B89D990-03EA-4FF4-8392-376C08E37161}
+ Library
+ GoneBananasAndroid
+ Assets
+ Resources
+ Resource
+ Resources\Resource.designer.cs
+ True
+ False
+ GoneBananasAndroid
+ v4.0.3
+ Properties\AndroidManifest.xml
+
+
+ true
+ full
+ false
+ bin\Debug
+ DEBUG;ANDROID;
+ prompt
+ 4
+ None
+ false
+
+
+ full
+ true
+ bin\Release
+ prompt
+ 4
+ false
+ false
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/GoneBananas/GoneBananasAndroid/MainActivity.cs b/GoneBananas/GoneBananasAndroid/MainActivity.cs
new file mode 100644
index 0000000..6d9b711
--- /dev/null
+++ b/GoneBananas/GoneBananasAndroid/MainActivity.cs
@@ -0,0 +1,38 @@
+using System;
+
+using Android.App;
+using Android.Content;
+using Android.Content.PM;
+using Android.OS;
+using Android.Runtime;
+using Android.Views;
+using Android.Widget;
+using CocosSharp;
+using Microsoft.Xna.Framework;
+using GoneBananas;
+
+namespace GoneBananasAndroid
+{
+ [Activity(
+ Label = "GoneBananas",
+ AlwaysRetainTaskState = true,
+ Icon = "@drawable/ic_launcher",
+ Theme = "@android:style/Theme.NoTitleBar",
+ ScreenOrientation = ScreenOrientation.Portrait,
+ LaunchMode = LaunchMode.SingleInstance,
+ MainLauncher = true,
+ ConfigurationChanges = ConfigChanges.Keyboard | ConfigChanges.KeyboardHidden)
+ ]
+ public class MainActivity : AndroidGameActivity
+ {
+ protected override void OnCreate(Bundle bundle)
+ {
+ base.OnCreate(bundle);
+
+ var application = new CCApplication();
+ application.ApplicationDelegate = new GoneBananasApplicationDelegate();
+ SetContentView(application.AndroidContentView);
+ application.StartGame();
+ }
+ }
+}
\ No newline at end of file
diff --git a/GoneBananas/GoneBananasAndroid/Properties/AndroidManifest.xml b/GoneBananas/GoneBananasAndroid/Properties/AndroidManifest.xml
new file mode 100644
index 0000000..45d43e4
--- /dev/null
+++ b/GoneBananas/GoneBananasAndroid/Properties/AndroidManifest.xml
@@ -0,0 +1,6 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/GoneBananas/GoneBananasAndroid/Properties/AssemblyInfo.cs b/GoneBananas/GoneBananasAndroid/Properties/AssemblyInfo.cs
new file mode 100644
index 0000000..324e91f
--- /dev/null
+++ b/GoneBananas/GoneBananasAndroid/Properties/AssemblyInfo.cs
@@ -0,0 +1,28 @@
+using System.Reflection;
+using System.Runtime.CompilerServices;
+using Android.App;
+
+// Information about this assembly is defined by the following attributes.
+// Change them to the values specific to your project.
+
+[assembly: AssemblyTitle ("GoneBananasAndroid")]
+[assembly: AssemblyDescription ("")]
+[assembly: AssemblyConfiguration ("")]
+[assembly: AssemblyCompany ("")]
+[assembly: AssemblyProduct ("")]
+[assembly: AssemblyCopyright ("mike_bluestein")]
+[assembly: AssemblyTrademark ("")]
+[assembly: AssemblyCulture ("")]
+
+// The assembly version has the format "{Major}.{Minor}.{Build}.{Revision}".
+// The form "{Major}.{Minor}.*" will automatically update the build and revision,
+// and "{Major}.{Minor}.{Build}.*" will update just the revision.
+
+[assembly: AssemblyVersion ("1.0.0")]
+
+// The following attributes are used to specify the signing key for the assembly,
+// if desired. See the Mono documentation for more information about signing.
+
+//[assembly: AssemblyDelaySign(false)]
+//[assembly: AssemblyKeyFile("")]
+
diff --git a/GoneBananas/GoneBananasAndroid/Resources/AboutResources.txt b/GoneBananas/GoneBananasAndroid/Resources/AboutResources.txt
new file mode 100644
index 0000000..10f52d4
--- /dev/null
+++ b/GoneBananas/GoneBananasAndroid/Resources/AboutResources.txt
@@ -0,0 +1,44 @@
+Images, layout descriptions, binary blobs and string dictionaries can be included
+in your application as resource files. Various Android APIs are designed to
+operate on the resource IDs instead of dealing with images, strings or binary blobs
+directly.
+
+For example, a sample Android app that contains a user interface layout (main.axml),
+an internationalization string table (strings.xml) and some icons (drawable-XXX/icon.png)
+would keep its resources in the "Resources" directory of the application:
+
+Resources/
+ drawable/
+ icon.png
+
+ layout/
+ main.axml
+
+ values/
+ strings.xml
+
+In order to get the build system to recognize Android resources, set the build action to
+"AndroidResource". The native Android APIs do not operate directly with filenames, but
+instead operate on resource IDs. When you compile an Android application that uses resources,
+the build system will package the resources for distribution and generate a class called "R"
+(this is an Android convention) that contains the tokens for each one of the resources
+included. For example, for the above Resources layout, this is what the R class would expose:
+
+public class R {
+ public class drawable {
+ public const int icon = 0x123;
+ }
+
+ public class layout {
+ public const int main = 0x456;
+ }
+
+ public class strings {
+ public const int first_string = 0xabc;
+ public const int second_string = 0xbcd;
+ }
+}
+
+You would then use R.drawable.icon to reference the drawable/icon.png file, or R.layout.main
+to reference the layout/main.axml file, or R.strings.first_string to reference the first
+string in the dictionary file values/strings.xml.
diff --git a/GoneBananas/GoneBananasAndroid/Resources/Resource.designer.cs b/GoneBananas/GoneBananasAndroid/Resources/Resource.designer.cs
new file mode 100644
index 0000000..73c9d96
--- /dev/null
+++ b/GoneBananas/GoneBananasAndroid/Resources/Resource.designer.cs
@@ -0,0 +1,112 @@
+#pragma warning disable 1591
+// ------------------------------------------------------------------------------
+//
+// This code was generated by a tool.
+// Mono Runtime Version: 4.0.30319.17020
+//
+// Changes to this file may cause incorrect behavior and will be lost if
+// the code is regenerated.
+//
+// ------------------------------------------------------------------------------
+
+[assembly: Android.Runtime.ResourceDesignerAttribute("GoneBananasAndroid.Resource", IsApplication=true)]
+
+namespace GoneBananasAndroid
+{
+
+
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("Xamarin.Android.Build.Tasks", "1.0.0.0")]
+ public partial class Resource
+ {
+
+ static Resource()
+ {
+ global::Android.Runtime.ResourceIdManager.UpdateIdValues();
+ }
+
+ public static void UpdateIdValues()
+ {
+ }
+
+ public partial class Attribute
+ {
+
+ static Attribute()
+ {
+ global::Android.Runtime.ResourceIdManager.UpdateIdValues();
+ }
+
+ private Attribute()
+ {
+ }
+ }
+
+ public partial class Drawable
+ {
+
+ // aapt resource value: 0x7f020000
+ public const int ic_launcher = 2130837504;
+
+ static Drawable()
+ {
+ global::Android.Runtime.ResourceIdManager.UpdateIdValues();
+ }
+
+ private Drawable()
+ {
+ }
+ }
+
+ public partial class Id
+ {
+
+ // aapt resource value: 0x7f050000
+ public const int myButton = 2131034112;
+
+ static Id()
+ {
+ global::Android.Runtime.ResourceIdManager.UpdateIdValues();
+ }
+
+ private Id()
+ {
+ }
+ }
+
+ public partial class Layout
+ {
+
+ // aapt resource value: 0x7f030000
+ public const int Main = 2130903040;
+
+ static Layout()
+ {
+ global::Android.Runtime.ResourceIdManager.UpdateIdValues();
+ }
+
+ private Layout()
+ {
+ }
+ }
+
+ public partial class String
+ {
+
+ // aapt resource value: 0x7f040001
+ public const int app_name = 2130968577;
+
+ // aapt resource value: 0x7f040000
+ public const int hello = 2130968576;
+
+ static String()
+ {
+ global::Android.Runtime.ResourceIdManager.UpdateIdValues();
+ }
+
+ private String()
+ {
+ }
+ }
+ }
+}
+#pragma warning restore 1591
diff --git a/GoneBananas/GoneBananasAndroid/Resources/drawable/ic_launcher.png b/GoneBananas/GoneBananasAndroid/Resources/drawable/ic_launcher.png
new file mode 100644
index 0000000..1760deb
Binary files /dev/null and b/GoneBananas/GoneBananasAndroid/Resources/drawable/ic_launcher.png differ
diff --git a/GoneBananas/GoneBananasAndroid/Resources/layout/Main.axml b/GoneBananas/GoneBananasAndroid/Resources/layout/Main.axml
new file mode 100644
index 0000000..bd890ff
--- /dev/null
+++ b/GoneBananas/GoneBananasAndroid/Resources/layout/Main.axml
@@ -0,0 +1,14 @@
+
+
+
+
+
diff --git a/GoneBananas/GoneBananasAndroid/Resources/values/Strings.xml b/GoneBananas/GoneBananasAndroid/Resources/values/Strings.xml
new file mode 100644
index 0000000..e60901d
--- /dev/null
+++ b/GoneBananas/GoneBananasAndroid/Resources/values/Strings.xml
@@ -0,0 +1,5 @@
+
+
+ Hello World, Click Me!
+ GoneBananasAndroid
+
diff --git a/GoneBananas/GoneBananasShared/CCPhysicsSprite.cs b/GoneBananas/GoneBananasShared/CCPhysicsSprite.cs
new file mode 100644
index 0000000..fb82a69
--- /dev/null
+++ b/GoneBananas/GoneBananasShared/CCPhysicsSprite.cs
@@ -0,0 +1,51 @@
+using System;
+using Box2D.Common;
+using Box2D.Dynamics;
+using CocosSharp;
+
+namespace GoneBananas
+{
+ internal class CCPhysicsSprite : CCSprite
+ {
+ readonly float ptmRatio;
+
+ public CCPhysicsSprite (CCTexture2D f, CCRect r, float ptmRatio) : base (f, r)
+ {
+ this.ptmRatio = ptmRatio;
+ }
+
+ public b2Body PhysicsBody { get; set; }
+
+ public override CCAffineTransform AffineLocalTransform {
+ get {
+ if (PhysicsBody == null)
+ return base.AffineLocalTransform;
+
+ b2Vec2 pos = PhysicsBody.Position;
+
+ float x = pos.x * ptmRatio;
+ float y = pos.y * ptmRatio;
+
+ if (IgnoreAnchorPointForPosition) {
+ x += AnchorPointInPoints.X;
+ y += AnchorPointInPoints.Y;
+ }
+
+ // Make matrix
+ float radians = PhysicsBody.Angle;
+ var c = (float)Math.Cos (radians);
+ var s = (float)Math.Sin (radians);
+
+ if (!AnchorPointInPoints.Equals (CCPoint.Zero)) {
+ x += c * -AnchorPointInPoints.X + -s * -AnchorPointInPoints.Y;
+ y += s * -AnchorPointInPoints.X + c * -AnchorPointInPoints.Y;
+ }
+
+ // Rot, Translate Matrix
+ var m_sTransform = new CCAffineTransform (c, s, -s, c, x, y);
+
+ return m_sTransform;
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git a/GoneBananas/GoneBananasShared/GameLayer.cs b/GoneBananas/GoneBananasShared/GameLayer.cs
new file mode 100644
index 0000000..f51dc13
--- /dev/null
+++ b/GoneBananas/GoneBananasShared/GameLayer.cs
@@ -0,0 +1,346 @@
+using System;
+using System.Collections.Generic;
+using CocosDenshion;
+using CocosSharp;
+using System.Linq;
+
+using Box2D.Common;
+using Box2D.Dynamics;
+using Box2D.Collision.Shapes;
+
+namespace GoneBananas
+{
+ public class GameLayer : CCLayerColor
+ {
+ const float MONKEY_SPEED = 350.0f;
+ const float GAME_DURATION = 60.0f; // game ends after 60 seconds or when the monkey hits a ball, whihcever comes first
+
+ // point to meter ratio for physics
+ const int PTM_RATIO = 32;
+
+ float elapsedTime;
+ CCSprite monkey;
+ List visibleBananas;
+ List hitBananas;
+
+ // monkey walking animation
+ CCAnimation walkAnim;
+ CCRepeatForever walkRepeat;
+ CCCallFuncN walkAnimStop = new CCCallFuncN (node => node.StopAllActions ());
+
+ // background sprite
+ CCSprite grass;
+
+ // particles
+ CCParticleSun sun;
+
+ // circle layered behind sun
+ CCDrawNode circleNode;
+
+ // parallax node for clouds
+ CCParallaxNode parallaxClouds;
+
+ // define our banana rotation action
+ CCRotateBy rotateBanana = new CCRotateBy (0.8f, 360);
+
+ // define our completion action to remove the banana once it hits the bottom of the screen
+ CCCallFuncN moveBananaComplete = new CCCallFuncN (node => node.RemoveFromParent ());
+
+ // physics world
+ b2World world;
+
+ // balls sprite batch
+ CCSpriteBatchNode ballsBatch;
+ CCTexture2D ballTexture;
+
+ public GameLayer ()
+ {
+ var touchListener = new CCEventListenerTouchAllAtOnce ();
+ touchListener.OnTouchesEnded = OnTouchesEnded;
+
+ AddEventListener (touchListener, this);
+ Color = new CCColor3B (CCColor4B.White);
+ Opacity = 255;
+
+ visibleBananas = new List ();
+ hitBananas = new List ();
+
+ // batch node for physics balls
+ ballsBatch = new CCSpriteBatchNode ("balls", 100);
+ ballTexture = ballsBatch.Texture;
+ AddChild (ballsBatch, 1, 1);
+
+ AddGrass ();
+ AddSun ();
+ AddMonkey ();
+
+ Schedule (t => {
+ visibleBananas.Add (AddBanana ());
+ elapsedTime += t;
+ if (ShouldEndGame ()) {
+ EndGame ();
+ }
+ AddBall ();
+ }, 1.0f);
+
+ Schedule (t => CheckCollision ());
+
+ Schedule (t => {
+ world.Step (t, 8, 1);
+
+ foreach (CCPhysicsSprite sprite in ballsBatch.Children) {
+ if (sprite.Visible && sprite.PhysicsBody.Position.x < 0f || sprite.PhysicsBody.Position.x * PTM_RATIO > ContentSize.Width) { //or should it be Layer.VisibleBoundsWorldspace.Size.Width
+ world.DestroyBody (sprite.PhysicsBody);
+ sprite.Visible = false;
+ sprite.RemoveFromParent ();
+ } else {
+ sprite.UpdateTransformedSpriteTextureQuads ();
+ }
+ }
+ });
+ }
+
+ void AddGrass ()
+ {
+ grass = new CCSprite ("grass");
+ AddChild (grass);
+ }
+
+ void AddSun ()
+ {
+ circleNode = new CCDrawNode ();
+ circleNode.DrawSolidCircle (CCPoint.Zero, 30.0f, CCColor4B.Yellow);
+ AddChild (circleNode);
+
+ sun = new CCParticleSun (CCPoint.Zero);
+ sun.StartColor = new CCColor4F (CCColor3B.Red);
+ sun.EndColor = new CCColor4F (CCColor3B.Yellow);
+ AddChild (sun);
+ }
+
+ void AddMonkey ()
+ {
+ var spriteSheet = new CCSpriteSheet ("animations/monkey.plist");
+ var animationFrames = spriteSheet.Frames.FindAll ((x) => x.TextureFilename.StartsWith ("frame"));
+
+ walkAnim = new CCAnimation (animationFrames, 0.1f);
+ walkRepeat = new CCRepeatForever (new CCAnimate (walkAnim));
+ monkey = new CCSprite (animationFrames.First ()) { Name = "Monkey" };
+ monkey.Scale = 0.25f;
+
+ AddChild (monkey);
+ }
+
+ CCSprite AddBanana ()
+ {
+ var spriteSheet = new CCSpriteSheet ("animations/monkey.plist");
+ var banana = new CCSprite (spriteSheet.Frames.Find ((x) => x.TextureFilename.StartsWith ("Banana")));
+
+ var p = GetRandomPosition (banana.ContentSize);
+ banana.Position = p;
+ banana.Scale = 0.5f;
+
+ AddChild (banana);
+
+ var moveBanana = new CCMoveTo (5.0f, new CCPoint (banana.Position.X, 0));
+ banana.RunActions (moveBanana, moveBananaComplete);
+ banana.RepeatForever (rotateBanana);
+
+ return banana;
+ }
+
+ CCPoint GetRandomPosition (CCSize spriteSize)
+ {
+ double rnd = CCRandom.NextDouble ();
+ double randomX = (rnd > 0)
+ ? rnd * VisibleBoundsWorldspace.Size.Width - spriteSize.Width / 2
+ : spriteSize.Width / 2;
+
+ return new CCPoint ((float)randomX, VisibleBoundsWorldspace.Size.Height - spriteSize.Height / 2);
+ }
+
+ void AddClouds ()
+ {
+ float h = VisibleBoundsWorldspace.Size.Height;
+
+ parallaxClouds = new CCParallaxNode {
+ Position = new CCPoint (0, h)
+ };
+
+ AddChild (parallaxClouds);
+
+ var cloud1 = new CCSprite ("cloud");
+ var cloud2 = new CCSprite ("cloud");
+ var cloud3 = new CCSprite ("cloud");
+
+ float yRatio1 = 1.0f;
+ float yRatio2 = 0.15f;
+ float yRatio3 = 0.5f;
+
+ parallaxClouds.AddChild (cloud1, 0, new CCPoint (1.0f, yRatio1), new CCPoint (100, -100 + h - (h * yRatio1)));
+ parallaxClouds.AddChild (cloud2, 0, new CCPoint (1.0f, yRatio2), new CCPoint (250, -200 + h - (h * yRatio2)));
+ parallaxClouds.AddChild (cloud3, 0, new CCPoint (1.0f, yRatio3), new CCPoint (400, -150 + h - (h * yRatio3)));
+ }
+
+ void MoveClouds (float dy)
+ {
+ parallaxClouds.StopAllActions ();
+ var moveClouds = new CCMoveBy (1.0f, new CCPoint (0, dy * 0.1f));
+ parallaxClouds.RunAction (moveClouds);
+ }
+
+ void CheckCollision ()
+ {
+ visibleBananas.ForEach (banana => {
+ bool hit = banana.BoundingBoxTransformedToParent.IntersectsRect (monkey.BoundingBoxTransformedToParent);
+ if (hit) {
+ hitBananas.Add (banana);
+ CCSimpleAudioEngine.SharedEngine.PlayEffect ("Sounds/tap");
+ Explode (banana.Position);
+ banana.RemoveFromParent ();
+ }
+ });
+
+ hitBananas.ForEach (banana => visibleBananas.Remove (banana));
+
+ int ballHitCount = ballsBatch.Children.Count (ball => ball.BoundingBoxTransformedToParent.IntersectsRect (monkey.BoundingBoxTransformedToParent));
+
+ if (ballHitCount > 0) {
+ EndGame ();
+ }
+ }
+
+ void EndGame ()
+ {
+ var gameOverScene = GameOverLayer.SceneWithScore (Window, hitBananas.Count);
+ var transitionToGameOver = new CCTransitionMoveInR (0.3f, gameOverScene);
+ Director.ReplaceScene (transitionToGameOver);
+
+ //work-around bug that creates an infinite loop resulting in repeated transitionToGameOver calls
+ this.UnscheduleAll ();
+ }
+
+ void Explode (CCPoint pt)
+ {
+ var explosion = new CCParticleExplosion (pt); //TODO: manage "better" for performance when "many" particles
+ explosion.TotalParticles = 10;
+ explosion.AutoRemoveOnFinish = true;
+ AddChild (explosion);
+ }
+
+ bool ShouldEndGame ()
+ {
+ return elapsedTime > GAME_DURATION;
+ }
+
+ void OnTouchesEnded (List touches, CCEvent touchEvent)
+ {
+ monkey.StopAllActions ();
+
+ var location = touches [0].LocationOnScreen;
+ location = WorldToScreenspace (location); //Layer.WorldToScreenspace(location);
+ float ds = CCPoint.Distance (monkey.Position, location);
+
+ var dt = ds / MONKEY_SPEED;
+
+ var moveMonkey = new CCMoveTo (dt, location);
+
+ //BUG: calling walkRepeat separately as it doesn't run when called in RunActions or CCSpawn
+ monkey.RunAction (walkRepeat);
+ monkey.RunActions (moveMonkey, walkAnimStop);
+
+ // move the clouds relative to the monkey's movement
+ MoveClouds (location.Y - monkey.Position.Y);
+ }
+
+ protected override void AddedToScene ()
+ {
+ base.AddedToScene ();
+
+ Scene.SceneResolutionPolicy = CCSceneResolutionPolicy.NoBorder;
+
+ grass.Position = VisibleBoundsWorldspace.Center;
+ monkey.Position = VisibleBoundsWorldspace.Center;
+
+ var b = VisibleBoundsWorldspace;
+ sun.Position = b.UpperRight.Offset (-100, -100); //BUG: doesn't appear in visible area on Nexus 7 device
+
+ circleNode.Position = sun.Position;
+
+ AddClouds ();
+ }
+
+ void InitPhysics ()
+ {
+ CCSize s = Layer.VisibleBoundsWorldspace.Size;
+
+ var gravity = new b2Vec2 (0.0f, -10.0f);
+ world = new b2World (gravity);
+
+ world.SetAllowSleeping (true);
+ world.SetContinuousPhysics (true);
+
+ var def = new b2BodyDef ();
+ def.allowSleep = true;
+ def.position = b2Vec2.Zero;
+ def.type = b2BodyType.b2_staticBody;
+ b2Body groundBody = world.CreateBody (def);
+ groundBody.SetActive (true);
+
+ b2EdgeShape groundBox = new b2EdgeShape ();
+ groundBox.Set (b2Vec2.Zero, new b2Vec2 (s.Width / PTM_RATIO, 0));
+ b2FixtureDef fd = new b2FixtureDef ();
+ fd.shape = groundBox;
+ groundBody.CreateFixture (fd);
+ }
+
+ void AddBall ()
+ {
+ int idx = (CCRandom.Float_0_1 () > .5 ? 0 : 1);
+ int idy = (CCRandom.Float_0_1 () > .5 ? 0 : 1);
+ var sprite = new CCPhysicsSprite (ballTexture, new CCRect (32 * idx, 32 * idy, 32, 32), PTM_RATIO);
+
+ ballsBatch.AddChild (sprite);
+
+ CCPoint p = GetRandomPosition (sprite.ContentSize);
+
+ sprite.Position = new CCPoint (p.X, p.Y);
+
+ var def = new b2BodyDef ();
+ def.position = new b2Vec2 (p.X / PTM_RATIO, p.Y / PTM_RATIO);
+ def.type = b2BodyType.b2_dynamicBody;
+ b2Body body = world.CreateBody (def);
+
+ var circle = new b2CircleShape ();
+ circle.Radius = 0.5f;
+
+ var fd = new b2FixtureDef ();
+ fd.shape = circle;
+ fd.density = 1f;
+ fd.restitution = 0.85f;
+ fd.friction = 0.3f;
+ body.CreateFixture (fd);
+
+ sprite.PhysicsBody = body;
+
+ Console.WriteLine ("sprite batch node count = {0}", ballsBatch.ChildrenCount);
+ }
+
+ public override void OnEnter ()
+ {
+ base.OnEnter ();
+
+ InitPhysics ();
+ }
+
+ public static CCScene GameScene (CCWindow mainWindow)
+ {
+ var scene = new CCScene (mainWindow);
+ var layer = new GameLayer ();
+
+ scene.AddChild (layer);
+
+ return scene;
+ }
+ }
+}
\ No newline at end of file
diff --git a/GoneBananas/GoneBananasShared/GameOverLayer.cs b/GoneBananas/GoneBananasShared/GameOverLayer.cs
new file mode 100644
index 0000000..e8a39df
--- /dev/null
+++ b/GoneBananas/GoneBananasShared/GameOverLayer.cs
@@ -0,0 +1,81 @@
+using System;
+using System.Collections.Generic;
+using CocosSharp;
+
+namespace GoneBananas
+{
+ public class GameOverLayer : CCLayerColor
+ {
+
+ string scoreMessage = string.Empty;
+
+ public GameOverLayer (int score) //: base(new CCSize (640, 1136))
+ {
+
+ var touchListener = new CCEventListenerTouchAllAtOnce ();
+ touchListener.OnTouchesEnded = (touches, ccevent) => Window.DefaultDirector.ReplaceScene (GameLayer.GameScene (Window));
+
+ AddEventListener (touchListener, this);
+
+ scoreMessage = String.Format ("Game Over. You collected {0} bananas!", score);
+
+ Color = new CCColor3B (CCColor4B.Black);
+
+ Opacity = 255;
+ }
+
+ public void AddMonkey ()
+ {
+ var spriteSheet = new CCSpriteSheet ("animations/monkey.plist");
+ var frame = spriteSheet.Frames.Find ((x) => x.TextureFilename.StartsWith ("frame"));
+
+ var monkey = new CCSprite (frame) {
+ Position = new CCPoint (VisibleBoundsWorldspace.Size.Center.X + 20, VisibleBoundsWorldspace.Size.Center.Y + 300),
+ Scale = 0.5f
+ };
+
+ AddChild (monkey);
+ }
+
+ protected override void AddedToScene ()
+ {
+ base.AddedToScene ();
+
+ Scene.SceneResolutionPolicy = CCSceneResolutionPolicy.ShowAll;
+
+ var scoreLabel = new CCLabelTtf (scoreMessage, "arial", 22) {
+ Position = new CCPoint (VisibleBoundsWorldspace.Size.Center.X, VisibleBoundsWorldspace.Size.Center.Y + 50),
+ Color = new CCColor3B (CCColor4B.Yellow),
+ HorizontalAlignment = CCTextAlignment.Center,
+ VerticalAlignment = CCVerticalTextAlignment.Center,
+ AnchorPoint = CCPoint.AnchorMiddle,
+ Dimensions = ContentSize
+ };
+
+ AddChild (scoreLabel);
+
+ var playAgainLabel = new CCLabelTtf ("Tap to Play Again", "arial", 22) {
+ Position = VisibleBoundsWorldspace.Size.Center,
+ Color = new CCColor3B (CCColor4B.Green),
+ HorizontalAlignment = CCTextAlignment.Center,
+ VerticalAlignment = CCVerticalTextAlignment.Center,
+ AnchorPoint = CCPoint.AnchorMiddle,
+ Dimensions = ContentSize
+ };
+
+ AddChild (playAgainLabel);
+
+ AddMonkey ();
+ }
+
+ public static CCScene SceneWithScore (CCWindow mainWindow, int score)
+ {
+ var scene = new CCScene (mainWindow);
+ var layer = new GameOverLayer (score);
+
+ scene.AddChild (layer);
+
+ return scene;
+ }
+ }
+}
\ No newline at end of file
diff --git a/GoneBananas/GoneBananasShared/GameStartLayer.cs b/GoneBananas/GoneBananasShared/GameStartLayer.cs
new file mode 100644
index 0000000..317174e
--- /dev/null
+++ b/GoneBananas/GoneBananasShared/GameStartLayer.cs
@@ -0,0 +1,48 @@
+using System;
+using System.Collections.Generic;
+using CocosSharp;
+
+namespace GoneBananas
+{
+ public class GameStartLayer : CCLayerColor
+ {
+ public GameStartLayer () : base ()
+ {
+ var touchListener = new CCEventListenerTouchAllAtOnce ();
+ touchListener.OnTouchesEnded = (touches, ccevent) => Window.DefaultDirector.ReplaceScene (GameLayer.GameScene (Window));
+
+ AddEventListener (touchListener, this);
+
+ Color = CCColor3B.Black;
+ Opacity = 255;
+ }
+
+ protected override void AddedToScene ()
+ {
+ base.AddedToScene ();
+
+ Scene.SceneResolutionPolicy = CCSceneResolutionPolicy.ShowAll;
+
+ var label = new CCLabelTtf ("Tap Screen to Go Bananas!", "arial", 22) {
+ Position = VisibleBoundsWorldspace.Center,
+ Color = CCColor3B.Green,
+ HorizontalAlignment = CCTextAlignment.Center,
+ VerticalAlignment = CCVerticalTextAlignment.Center,
+ AnchorPoint = CCPoint.AnchorMiddle,
+ Dimensions = ContentSize
+ };
+
+ AddChild (label);
+ }
+
+ public static CCScene GameStartLayerScene (CCWindow mainWindow)
+ {
+ var scene = new CCScene (mainWindow);
+ var layer = new GameStartLayer ();
+
+ scene.AddChild (layer);
+
+ return scene;
+ }
+ }
+}
\ No newline at end of file
diff --git a/GoneBananas/GoneBananasShared/GoneBananasApplicationDelegate.cs b/GoneBananas/GoneBananasShared/GoneBananasApplicationDelegate.cs
new file mode 100644
index 0000000..8f48b3a
--- /dev/null
+++ b/GoneBananas/GoneBananasShared/GoneBananasApplicationDelegate.cs
@@ -0,0 +1,42 @@
+using CocosDenshion;
+using CocosSharp;
+
+namespace GoneBananas
+{
+ public class GoneBananasApplicationDelegate : CCApplicationDelegate
+ {
+
+ public override void ApplicationDidFinishLaunching (CCApplication application, CCWindow mainWindow)
+ {
+ application.PreferMultiSampling = false;
+ application.ContentRootDirectory = "Content";
+
+ mainWindow.SupportedDisplayOrientations = CCDisplayOrientation.Portrait;
+
+ application.ContentSearchPaths.Add("hd");
+
+ CCSimpleAudioEngine.SharedEngine.PreloadEffect ("Sounds/tap");
+
+ CCScene scene = GameStartLayer.GameStartLayerScene(mainWindow);
+ mainWindow.RunWithScene (scene);
+ }
+
+ public override void ApplicationDidEnterBackground (CCApplication application)
+ {
+ // stop all of the animation actions that are running.
+ application.PauseGame ();
+
+ // if you use SimpleAudioEngine, your music must be paused
+ CCSimpleAudioEngine.SharedEngine.PauseBackgroundMusic ();
+ }
+
+ public override void ApplicationWillEnterForeground (CCApplication application)
+ {
+ application.ResumeGame ();
+
+
+ // if you use SimpleAudioEngine, your background music track must resume here.
+ CCSimpleAudioEngine.SharedEngine.ResumeBackgroundMusic ();
+ }
+ }
+}
\ No newline at end of file
diff --git a/GoneBananas/GoneBananasShared/GoneBananasShared.projitems b/GoneBananas/GoneBananasShared/GoneBananasShared.projitems
new file mode 100644
index 0000000..2f6d56c
--- /dev/null
+++ b/GoneBananas/GoneBananasShared/GoneBananasShared.projitems
@@ -0,0 +1,18 @@
+
+
+
+ $(MSBuildAllProjects);$(MSBuildThisFileFullPath)
+ true
+ {7187ABEC-F6E0-4CF4-8E8C-481DBE6DA18B}
+
+
+ GoneBananasShared
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/GoneBananas/GoneBananasShared/GoneBananasShared.shproj b/GoneBananas/GoneBananasShared/GoneBananasShared.shproj
new file mode 100644
index 0000000..0948daf
--- /dev/null
+++ b/GoneBananas/GoneBananasShared/GoneBananasShared.shproj
@@ -0,0 +1,11 @@
+
+
+
+ {7187ABEC-F6E0-4CF4-8E8C-481DBE6DA18B}
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/GoneBananas/GoneBananasiOS/AppDelegate.cs b/GoneBananas/GoneBananasiOS/AppDelegate.cs
new file mode 100644
index 0000000..2daab18
--- /dev/null
+++ b/GoneBananas/GoneBananasiOS/AppDelegate.cs
@@ -0,0 +1,18 @@
+using System;
+using MonoTouch.Foundation;
+using MonoTouch.UIKit;
+using CocosSharp;
+
+namespace GoneBananas
+{
+ [Register ("AppDelegate")]
+ public partial class AppDelegate : UIApplicationDelegate
+ {
+ public override void FinishedLaunching (UIApplication app)
+ {
+ var application = new CCApplication ();
+ application.ApplicationDelegate = new GoneBananasApplicationDelegate ();
+ application.StartGame ();
+ }
+ }
+}
\ No newline at end of file
diff --git a/GoneBananas/GoneBananasiOS/Content/Sounds/tap.mp3 b/GoneBananas/GoneBananasiOS/Content/Sounds/tap.mp3
new file mode 100644
index 0000000..6d7665a
Binary files /dev/null and b/GoneBananas/GoneBananasiOS/Content/Sounds/tap.mp3 differ
diff --git a/GoneBananas/GoneBananasiOS/Content/fonts/arial-22.xnb b/GoneBananas/GoneBananasiOS/Content/fonts/arial-22.xnb
new file mode 100644
index 0000000..49748e6
Binary files /dev/null and b/GoneBananas/GoneBananasiOS/Content/fonts/arial-22.xnb differ
diff --git a/GoneBananas/GoneBananasiOS/Content/hd/animations/monkey.plist b/GoneBananas/GoneBananasiOS/Content/hd/animations/monkey.plist
new file mode 100644
index 0000000..b45f18b
--- /dev/null
+++ b/GoneBananas/GoneBananasiOS/Content/hd/animations/monkey.plist
@@ -0,0 +1,139 @@
+
+
+
+
+ frames
+
+ Banana-hd.png
+
+ frame
+ {{2,2},{44,108}}
+ offset
+ {0,0}
+ rotated
+
+ sourceColorRect
+ {{0,0},{44,108}}
+ sourceSize
+ {44,108}
+
+ frame-1.png
+
+ frame
+ {{48,2},{391,555}}
+ offset
+ {0,0}
+ rotated
+
+ sourceColorRect
+ {{0,0},{391,555}}
+ sourceSize
+ {391,555}
+
+ frame-2.png
+
+ frame
+ {{441,2},{390,553}}
+ offset
+ {0,0}
+ rotated
+
+ sourceColorRect
+ {{0,0},{390,553}}
+ sourceSize
+ {390,553}
+
+ frame-3.png
+
+ frame
+ {{833,2},{387,566}}
+ offset
+ {0,0}
+ rotated
+
+ sourceColorRect
+ {{0,0},{387,566}}
+ sourceSize
+ {387,566}
+
+ frame-4.png
+
+ frame
+ {{1222,2},{386,579}}
+ offset
+ {0,0}
+ rotated
+
+ sourceColorRect
+ {{0,0},{386,579}}
+ sourceSize
+ {386,579}
+
+ frame-5.png
+
+ frame
+ {{1610,2},{387,573}}
+ offset
+ {0,0}
+ rotated
+
+ sourceColorRect
+ {{0,0},{387,573}}
+ sourceSize
+ {387,573}
+
+ frame-6.png
+
+ frame
+ {{2,583},{389,560}}
+ offset
+ {0,0}
+ rotated
+
+ sourceColorRect
+ {{0,0},{389,560}}
+ sourceSize
+ {389,560}
+
+ frame-7.png
+
+ frame
+ {{393,583},{390,553}}
+ offset
+ {0,0}
+ rotated
+
+ sourceColorRect
+ {{0,0},{390,553}}
+ sourceSize
+ {390,553}
+
+ frame-8.png
+
+ frame
+ {{785,583},{389,557}}
+ offset
+ {0,0}
+ rotated
+
+ sourceColorRect
+ {{0,0},{389,557}}
+ sourceSize
+ {389,557}
+
+
+ metadata
+
+ format
+ 2
+ realTextureFileName
+ monkey.png
+ size
+ {2048,2048}
+ smartupdate
+ $TexturePacker:SmartUpdate:c63ac17999f746ee253cb9e63215058f:7b9d55d9c4db1e73987b80a4545fa776:c408e1678cc8476d89ba18c5256b3484$
+ textureFileName
+ monkey.png
+
+
+
diff --git a/GoneBananas/GoneBananasiOS/Content/hd/animations/monkey.png b/GoneBananas/GoneBananasiOS/Content/hd/animations/monkey.png
new file mode 100644
index 0000000..7aecb29
Binary files /dev/null and b/GoneBananas/GoneBananasiOS/Content/hd/animations/monkey.png differ
diff --git a/GoneBananas/GoneBananasiOS/Content/hd/balls.png b/GoneBananas/GoneBananasiOS/Content/hd/balls.png
new file mode 100755
index 0000000..2ba46b5
Binary files /dev/null and b/GoneBananas/GoneBananasiOS/Content/hd/balls.png differ
diff --git a/GoneBananas/GoneBananasiOS/Content/hd/cloud.png b/GoneBananas/GoneBananasiOS/Content/hd/cloud.png
new file mode 100644
index 0000000..8957f1e
Binary files /dev/null and b/GoneBananas/GoneBananasiOS/Content/hd/cloud.png differ
diff --git a/GoneBananas/GoneBananasiOS/Content/hd/grass.png b/GoneBananas/GoneBananasiOS/Content/hd/grass.png
new file mode 100644
index 0000000..147b844
Binary files /dev/null and b/GoneBananas/GoneBananasiOS/Content/hd/grass.png differ
diff --git a/GoneBananas/GoneBananasiOS/GoneBananasiOS.csproj b/GoneBananas/GoneBananasiOS/GoneBananasiOS.csproj
new file mode 100644
index 0000000..5e9912f
--- /dev/null
+++ b/GoneBananas/GoneBananasiOS/GoneBananasiOS.csproj
@@ -0,0 +1,203 @@
+
+
+
+ Debug
+ iPhoneSimulator
+ 8.0.30703
+ 2.0
+ {0F682923-EE76-4240-BBEB-56BF44B82A57}
+ {6BC8ED88-2882-458C-8E55-DFD12B67127B};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}
+ Exe
+ GoneBananas
+ Resources
+
+
+ true
+ full
+ false
+ bin\iPhoneSimulator\Debug
+ DEBUG;IOS;
+ prompt
+ 4
+ None
+ false
+ true
+ GoneBananasiOS
+
+
+ full
+ true
+ bin\iPhoneSimulator\Release
+ prompt
+ 4
+ None
+ false
+ GoneBananasiOS
+
+
+ true
+ full
+ false
+ bin\iPhone\Debug
+ DEBUG;
+ prompt
+ 4
+ true
+ false
+ iPhone Developer
+ GoneBananas
+
+
+
+
+ full
+ true
+ bin\iPhone\Release
+ prompt
+ 4
+ iPhone Developer
+ false
+ GoneBananas
+
+
+ full
+ true
+ bin\iPhone\Ad-Hoc
+ prompt
+ 4
+ iPhone Distribution
+ true
+ false
+ Automatic:AdHoc
+ GoneBananas
+
+
+ full
+ true
+ bin\iPhone\AppStore
+ prompt
+ 4
+ iPhone Distribution
+ false
+ Automatic:AppStore
+ GoneBananas
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/GoneBananas/GoneBananasiOS/Info.plist b/GoneBananas/GoneBananasiOS/Info.plist
new file mode 100644
index 0000000..4606d07
--- /dev/null
+++ b/GoneBananas/GoneBananasiOS/Info.plist
@@ -0,0 +1,26 @@
+
+
+
+
+ UIDeviceFamily
+
+ 1
+
+ UISupportedInterfaceOrientations
+
+ UIInterfaceOrientationPortrait
+
+ MinimumOSVersion
+ 8.0
+ UIPrerenderedIcon
+
+ CFBundleDisplayName
+ GoneBananas
+ CFBundleIdentifier
+ com.xamarin.gonebananas
+ CFBundleShortVersionString
+ 1.0
+ XSAppIconAssets
+ Resources/Images.xcassets/AppIcons.appiconset
+
+
diff --git a/GoneBananas/GoneBananasiOS/Main.cs b/GoneBananas/GoneBananasiOS/Main.cs
new file mode 100644
index 0000000..6975aed
--- /dev/null
+++ b/GoneBananas/GoneBananasiOS/Main.cs
@@ -0,0 +1,16 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using MonoTouch.Foundation;
+using MonoTouch.UIKit;
+
+namespace GoneBananas
+{
+ public class Application
+ {
+ static void Main (string[] args)
+ {
+ UIApplication.Main (args, null, "AppDelegate");
+ }
+ }
+}
diff --git a/GoneBananas/GoneBananasiOS/Resources/Default-568h@2x.png b/GoneBananas/GoneBananasiOS/Resources/Default-568h@2x.png
new file mode 100644
index 0000000..3a34926
Binary files /dev/null and b/GoneBananas/GoneBananasiOS/Resources/Default-568h@2x.png differ
diff --git a/GoneBananas/GoneBananasiOS/Resources/Images.xcassets/AppIcons.appiconset/Contents.json b/GoneBananas/GoneBananasiOS/Resources/Images.xcassets/AppIcons.appiconset/Contents.json
new file mode 100644
index 0000000..dc41288
--- /dev/null
+++ b/GoneBananas/GoneBananasiOS/Resources/Images.xcassets/AppIcons.appiconset/Contents.json
@@ -0,0 +1 @@
+{"images":[{"idiom":"iphone","filename":"Icon-60@2x.png","size":"60x60","scale":"2x"},{"idiom":"iphone","filename":"Icon-Small-40@2x.png","size":"40x40","scale":"2x"}],"info":{"version":1,"author":"xcode"}}
\ No newline at end of file
diff --git a/GoneBananas/GoneBananasiOS/Resources/Images.xcassets/AppIcons.appiconset/Icon-60@2x.png b/GoneBananas/GoneBananasiOS/Resources/Images.xcassets/AppIcons.appiconset/Icon-60@2x.png
new file mode 100644
index 0000000..4057a1f
Binary files /dev/null and b/GoneBananas/GoneBananasiOS/Resources/Images.xcassets/AppIcons.appiconset/Icon-60@2x.png differ
diff --git a/GoneBananas/GoneBananasiOS/Resources/Images.xcassets/AppIcons.appiconset/Icon-Small-40@2x.png b/GoneBananas/GoneBananasiOS/Resources/Images.xcassets/AppIcons.appiconset/Icon-Small-40@2x.png
new file mode 100644
index 0000000..72601a2
Binary files /dev/null and b/GoneBananas/GoneBananasiOS/Resources/Images.xcassets/AppIcons.appiconset/Icon-Small-40@2x.png differ
diff --git a/GoneBananas/README.md b/GoneBananas/README.md
new file mode 100644
index 0000000..f977f7a
--- /dev/null
+++ b/GoneBananas/README.md
@@ -0,0 +1,24 @@
+Gone Bananas
+============
+
+Sample game to accompany the getting started walkthrough.
+
+![GoneBananas](screenshots/GoneBananas.png?raw=true "Gone Bananas")
+
+Demonstrates the following features:
+
+- Sprite creation
+- Actions
+- Scene transitions
+- Sprite sheet animation
+- Sprite batching
+- Parallax
+- Particles
+- Touch handling
+- Physics
+
+Future verisons will include:
+
+- Accelerometer input
+- Leaderboards
+- Multi-player
diff --git a/GoneBananas/screenshots/GoneBananas.png b/GoneBananas/screenshots/GoneBananas.png
new file mode 100644
index 0000000..4ae6270
Binary files /dev/null and b/GoneBananas/screenshots/GoneBananas.png differ