diff --git a/.classpath b/.classpath
deleted file mode 100644
index 36de7ba..0000000
--- a/.classpath
+++ /dev/null
@@ -1,8 +0,0 @@
-
-
-
-
-
-
-
-
diff --git a/.project b/.project
deleted file mode 100644
index 4c7a50f..0000000
--- a/.project
+++ /dev/null
@@ -1,33 +0,0 @@
-
-
- EngineWrapper
-
-
-
-
-
- com.android.ide.eclipse.adt.ResourceManagerBuilder
-
-
-
-
- com.android.ide.eclipse.adt.PreCompilerBuilder
-
-
-
-
- org.eclipse.jdt.core.javabuilder
-
-
-
-
- com.android.ide.eclipse.adt.ApkBuilder
-
-
-
-
-
- com.android.ide.eclipse.adt.AndroidNature
- org.eclipse.jdt.core.javanature
-
-
diff --git a/default.properties b/default.properties
deleted file mode 100644
index 94a5300..0000000
--- a/default.properties
+++ /dev/null
@@ -1,11 +0,0 @@
-# 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
diff --git a/jni/Android.mk b/jni/Android.mk
deleted file mode 100644
index 4b85a29..0000000
--- a/jni/Android.mk
+++ /dev/null
@@ -1,77 +0,0 @@
-# Copyright (C) 2009 The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-
-
-LPATH := $(call my-dir)
-
-ENGINE_PATH = $(SalmonEnginePathCygwin)
-
-BOOST_PATH = $(LibsPathCygwin)/boost_1_47_0
-
-OGG_PATH = $(LibsPathCygwin)/libogg-1.3.0
-
-VORBIS_PATH = $(LibsPathCygwin)/libvorbis-1.3.2
-
-SQUIRREL_PATH = $(LibsPathCygwin)/sqplus
-
-LIBPNG_PATH = $(LibsPathCygwin)/libpng_1.4.1_android
-
-ZIP_PATH = $(LibsPathCygwin)/julienr-libzip-android/jni
-
-#====== ENGINE AND LIBS =====================
-
-include $(ENGINE_PATH)/Android_Salmon_Engine.mk
-
-#================= THE GAME =======================
-
-
-LOCAL_PATH:= $(LPATH)
-
-include $(CLEAR_VARS)
-
-LOCAL_CFLAGS := -DTARGET_ANDROID -DNOSOUND -DTARGET_SALMON -std=gnu++11 --std=c++11
-LOCAL_STATIC_LIBRARIES := boost
-LOCAL_STATIC_LIBRARIES += squirrel
-LOCAL_STATIC_LIBRARIES += png_lib
-LOCAL_STATIC_LIBRARIES += zip
-LOCAL_SHARED_LIBRARIES := SalmonEngine
-LOCAL_SHARED_LIBRARIES += gnustl_shared
-LOCAL_C_INCLUDES := $(ENGINE_PATH)
-LOCAL_C_INCLUDES += $(BOOST_PATH)
-LOCAL_C_INCLUDES += $(VORBIS_PATH)/include
-LOCAL_C_INCLUDES += $(VORBIS_PATH)/include/vorbis
-LOCAL_C_INCLUDES += $(VORBIS_PATH)/lib
-LOCAL_C_INCLUDES += $(VORBIS_PATH)/lib/books
-LOCAL_C_INCLUDES += $(VORBIS_PATH)/lib/modes
-LOCAL_C_INCLUDES += $(OGG_PATH)/include
-LOCAL_C_INCLUDES += $(OGG_PATH)/include/ogg
-LOCAL_C_INCLUDES += $(SQUIRREL_PATH)/include
-LOCAL_C_INCLUDES += $(SQUIRREL_PATH)/sqplus
-LOCAL_C_INCLUDES += $(SQUIRREL_PATH)/squirrel
-LOCAL_C_INCLUDES += $(SQUIRREL_PATH)/sqstdlib
-LOCAL_C_INCLUDES += $(LIBPNG_PATH)
-LOCAL_C_INCLUDES += $(ZIP_PATH)
-LOCAL_MODULE := SalmonJniTemplate
-LOCAL_SRC_FILES := main_code.cpp
-LOCAL_SRC_FILES += android_api.cpp
-
-LOCAL_LDLIBS := -lGLESv2
-LOCAL_LDLIBS += -llog -Wl
-
-#debug
-#LOCAL_CFLAGS += -g -ggdb -O0
-#LOCAL_LDLIBS += -g -ggdb
-
-include $(BUILD_SHARED_LIBRARY)
diff --git a/jni/Application.mk b/jni/Application.mk
deleted file mode 100644
index 22476ec..0000000
--- a/jni/Application.mk
+++ /dev/null
@@ -1,3 +0,0 @@
-APP_STL := gnustl_shared
-APP_CPPFLAGS += -fexceptions
-APP_CPPFLAGS += -frtti
diff --git a/jni/android_api.cpp b/jni/android_api.cpp
deleted file mode 100644
index 294e60e..0000000
--- a/jni/android_api.cpp
+++ /dev/null
@@ -1,11 +0,0 @@
-#include "android_api.h"
-
-#include "boost/thread.hpp"
-
-#include "main_code.h"
-
-JNIEXPORT void JNICALL Java_fishrungames_salmonjnitemplate_JniWrapper_Init(JNIEnv * env, jobject obj, jint width, jint height)
-{
- JniInitApp(width, height, 320.f, 480.f);
-}
-
diff --git a/jni/android_api.h b/jni/android_api.h
deleted file mode 100644
index 0b29af5..0000000
--- a/jni/android_api.h
+++ /dev/null
@@ -1,23 +0,0 @@
-#ifndef ANDROID_API_H_INCLUDED
-#define ANDROID_API_H_INCLUDED
-
-#include
-#include
-
-#include
-#include
-#include
-
-#include "boost/shared_ptr.hpp"
-
-#include "main_code.h"
-
-using namespace SE;
-
-
-extern "C" {
- JNIEXPORT void JNICALL Java_fishrungames_salmonjnitemplate_JniWrapper_Init(JNIEnv * env, jobject obj, jint width, jint height);
-};
-
-
-#endif
diff --git a/jni/main_code.cpp b/jni/main_code.cpp
deleted file mode 100644
index 49d18da..0000000
--- a/jni/main_code.cpp
+++ /dev/null
@@ -1,435 +0,0 @@
-#include "main_code.h"
-
-#ifdef TARGET_ANDROID
-#include "android_api.h"
-#endif
-
-#include
-#include
-#include
-#include
-
-#include "include/Engine.h"
-
-#include "main_code.h"
-
-const int CONST_TUBE_COUNT = 6;
-
-const int CONST_MAX_BOXES = 50;
-
-const float CONST_VELOCITY = 2.f;
-
-int countTubes = 0;
-
-TFlexModel GenerateFlexModel(int i)
-{
- countTubes++;
-
- if (countTubes <= 5)
- {
- return ResourceManager->FlexModelManager.InstanciateModel("tube1.xml");
- }
- else
- {
- return ResourceManager->FlexModelManager.InstanciateModel("tube"+tostr(i+1)+".xml");
- }
-}
-
-TFlexModel GeneratePhysicsModel(int i)
-{
- countTubes++;
-
- if (countTubes <= 5)
- {
- return ResourceManager->FlexModelManager.InstanciateModel("tube1_physics.xml");
- }
- else
- {
- return ResourceManager->FlexModelManager.InstanciateModel("tube"+tostr(i+1)+"_physics.xml");
- }
-}
-
-
-void TMyApplication::InnerInit()
-{
-
- *Console<<"Inner init go!\n";
-
-#ifdef TARGET_ANDROID
- ST::PathToResources = "";
-#endif
-#ifdef TARGET_WIN32
-#ifdef NDEBUG
- ST::PathToResources = "resources/";
-#else
- ST::PathToResources = "../../../assets/";
-#endif
-#endif
-#ifdef TARGET_IOS
- ST::PathToResources = "assets/";
-#endif
-
- ResourceManager->TexList.AddTexture(CONST_CONSOLE_TEX_NAME);
-
- ResourceManager->ShaderManager.AddShader("DefaultShader", "gui_transparent.vertex", "gui_transparent.fragment");
-
- Renderer->PushShader("DefaultShader");
-
- ResourceManager->FontManager.AddFont("droid_sans14", "droid_sans14_font_bitmap.bmp32", "droid_sans14_font_charmap.txt");
- ResourceManager->FontManager.PushFont("droid_sans14");
-
- //ResourceManager->SoundManager.LoadMusic("level1ogg.ogg");
-
- //ResourceManager->SoundManager.LoadSound("shot.wav");
-
- //Renderer->MovePhi(pi/6);
-
- Renderer->Camera = TPitCamera();
-
- ResourceManager->LightManager.SetLightDirection(vec3(-1,0,-1));
- ResourceManager->LightManager.SetLightColor(vec4(1,0,0,1));
-
- ResourceManager->TexList.AddTexture("pit.png");
- ResourceManager->TexList.AddTexture("tube.png");
- ResourceManager->TexList.AddTexture("tube_i.png");
- //ResourceManager->FlexModelManager.LoadModelFromXml("model.xml");
- ResourceManager->FlexModelManager.LoadModelFromXml("box.xml");
- ResourceManager->FlexModelManager.LoadModelFromXml("pit.xml");
-
- ResourceManager->FlexModelManager.LoadModelFromXml("tube1.xml");
- ResourceManager->FlexModelManager.LoadModelFromXml("tube2.xml");
- ResourceManager->FlexModelManager.LoadModelFromXml("tube3.xml");
- ResourceManager->FlexModelManager.LoadModelFromXml("tube4.xml");
- ResourceManager->FlexModelManager.LoadModelFromXml("tube5.xml");
- ResourceManager->FlexModelManager.LoadModelFromXml("tube6.xml");
-
- ResourceManager->FlexModelManager.LoadModelFromXml("tube1_physics.xml");
- ResourceManager->FlexModelManager.LoadModelFromXml("tube2_physics.xml");
- ResourceManager->FlexModelManager.LoadModelFromXml("tube3_physics.xml");
- ResourceManager->FlexModelManager.LoadModelFromXml("tube4_physics.xml");
- ResourceManager->FlexModelManager.LoadModelFromXml("tube5_physics.xml");
- ResourceManager->FlexModelManager.LoadModelFromXml("tube6_physics.xml");
-
- FlexModel = ResourceManager->FlexModelManager.InstanciateModel("pit.xml");
-
-
- //FlexModel.MoveModel(vec3(0, -36.f, -105.f)); //Landscape screen
- FlexModel.MoveModel(vec3(0, -23.f, -50.f)); //Portrait screen
- FlexModel.ScaleModel(40.f);
- FlexModel.RefreshBuffer();
-
- TubeModelArr.resize(6);
- TubeBodyArr.resize(6);
-
- for (size_t i = 0; i < TubeModelArr.size(); ++i)
- {
- int modelNum = rand() % CONST_TUBE_COUNT;
- TubeModelArr[i] = GenerateFlexModel(modelNum);
-
- TubeModelArr[i].PushModelDataTriangleList();
- TubeModelArr[i].ScaleModel(25.4f);
- TubeModelArr[i].MoveModel(vec3(0, 0, -2500.f*i));
-
- TubeModelArr[i].RefreshBuffer();
-
-
-
- TubeBodyArr[i].AssignFromFlexModel(GeneratePhysicsModel(modelNum));
- TubeBodyArr[i].Scale(25.4f);
- TubeBodyArr[i].Move(vec3(0, 0, -2500.f*i));
-
-
-
- }
- /*
- for (int i=0; i< CONST_MAX_BOXES; i++)
- {
- BoxList.push_back(GenerateBox(i));
- }*/
-
- //Uncomment to start music playing
- //ResourceManager->SoundManager.PlayMusic("level1ogg.ogg");
-
- Velocity = CONST_VELOCITY;
-
- PrevCamVec = boost::get(Renderer->Camera).CamVec;
-
- RotateShift = vec2(0.f, 0.f);
-
- *Console<<"Inner init end!\n";
-}
-
-void TMyApplication::InnerDeinit()
-{
-}
-
-
-void TMyApplication::InnerDraw()
-{
-
- glClearColor(0,0,0,1);
- glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
-
- Renderer->PushPerspectiveProjectionMatrix(pi/6, Renderer->GetMatrixWidth() / Renderer->GetMatrixHeight(), 1.f, 8500.f);
-
- Renderer->PushMatrix();
-
- Renderer->SetGLCamView();
-
- for (size_t i = 0; i < TubeModelArr.size(); ++i)
- {
- TubeModelArr[i].Draw();
- }
-
- Renderer->PopMatrix();
-
- //Renderer->PopProjectionMatrix();
-
- glClear(GL_DEPTH_BUFFER_BIT);
-
- Renderer->PushMatrix();
-
- vec4 q;
-
- vec3 camVec = boost::get(Renderer->Camera).CamVec;
-
- vec4 camQuat = boost::get(Renderer->Camera).CameraQuat;
-
- vec3 n = Normalize(CrossProduct(camVec, PrevCamVec));
-
- float cos_a = min(DotProduct(camVec, PrevCamVec), 1.f);
-
- n = InverseQuat(camQuat) * vec4(n) * (camQuat);
-
- float sin_a = sqrtf(1 - cos_a*cos_a);
-
- if (sin_a > 0.001f)
- {
-
- q = vec4(n.v[0] * sin_a, n.v[1] * sin_a, n.v[2] * sin_a, cos_a);
-
- Renderer->RotateMatrix(q);
- }
- FlexModel.Draw();
-
- Renderer->PopMatrix();
-
- Renderer->PopProjectionMatrix();
-
-
-}
-
-
-void TMyApplication::InnerUpdate(cardinal dt)
-{
- vec3 camShift = boost::get(Renderer->Camera).CamShift;
-
- vec3 camVec = boost::get(Renderer->Camera).CamVec;
-
- camShift += camVec * (static_cast(dt)*Velocity);
-
- while (camShift.v[2] < -2500.f)
- {
- camShift.v[2] += 2500.f;
-
- TubeModelArr.erase(TubeModelArr.begin());
- TFlexModel model;
- model = GenerateFlexModel(rand() % CONST_TUBE_COUNT);
- model.ScaleModel(25.4f);
- TubeModelArr.push_back(model);
-
- for (size_t i = 0; i < TubeModelArr.size()-1; ++i)
- {
- TubeModelArr[i].MoveModel(vec3(0, 0, 2500.f));
- TubeModelArr[i].RefreshBuffer();
- }
-
- TubeModelArr[TubeModelArr.size()-1].MoveModel(vec3(0, 0, -2500.f*(TubeModelArr.size()-1)));
- TubeModelArr[TubeModelArr.size()-1].RefreshBuffer();
-
-
-
- TubeBodyArr.erase(TubeBodyArr.begin());
- TVolumeBody body;
- body.AssignFromFlexModel(GeneratePhysicsModel(rand() % CONST_TUBE_COUNT));
- body.Scale(25.4f);
- TubeBodyArr.push_back(body);
-
- for (size_t i = 0; i < TubeBodyArr.size()-1; ++i)
- {
- TubeBodyArr[i].Move(vec3(0, 0, 2500.f));
- }
-
- TubeBodyArr[TubeBodyArr.size()-1].Move(vec3(0, 0, -2500.f*(TubeBodyArr.size()-1)));
-
- }
-
- boost::get(Renderer->Camera).CamShift = camShift;
-
- if (Velocity != 0)
- {
-
- vec3 a = boost::get(Renderer->Camera).CamShift;
- vec3 b = a + 100.f * boost::get(Renderer->Camera).CamVec;
-
- if (a != b)
- {
- BOOST_FOREACH(TVolumeBody& body, TubeBodyArr)
- {
- if (body.CheckCollision(a,b))
- {
- Velocity = 0.f;
- }
- }
- /*
- BOOST_FOREACH(auto& i, BoxList)
- {
- if (i.second.CheckCollision(a,b))
- {
- Velocity = 0.f;
- }
- }*/
- }
- }
-
-
- //const float CONST_ROTATE_SPEED = 0.0004f;
- const float CONST_ROTATE_SPEED = 0.001f;
-
- float rotateShift = Length(RotateShift) * 0.01f / 2.f;
-
- vec4 quat = vec4(RotateAxis.v[0] * sin(rotateShift*dt*CONST_ROTATE_SPEED), RotateAxis.v[1] * sin(rotateShift*dt*CONST_ROTATE_SPEED), RotateAxis.v[2] * sin(rotateShift*dt*CONST_ROTATE_SPEED), cos(rotateShift*dt*CONST_ROTATE_SPEED));
-
- boost::get(Renderer->Camera).RotateByQuat(quat);
-
- boost::get(Renderer->Camera).CalcCamVec();
-
- UpdatePitVector(dt);
-
-
- OnUpdateSignal();
-
- OnUpdateSignal.disconnect_all_slots();
-
-}
-
-
-void TMyApplication::InnerOnMove(vec2 shift)
-{
-
- RotateShift += shift;
-
- //float len = Length(shift);
-
- vec3 rotation = Normalize(vec3(RotateShift, 0)); //Inverse
-
- //rotation.v[1] =-rotation.v[1]; //Inverse
-
- vec3 z = vec3(0,0,-1);
-
- vec4 startQuat = boost::get(Renderer->Camera).CameraQuat;
-
- RotateAxis = Normalize(CrossProduct(rotation, z));
-
- RotateAxis = startQuat * vec4(RotateAxis) * InverseQuat(startQuat);
-
- //RotateShift = len * 0.01f / 2.f;
-
- UpdatePitVector(0);
-}
-
-void TMyApplication::InnerOnTapUp(vec2 p)
-{
- RotateShift = vec2(0.f, 0.f);
-
- RotateAxis = vec3(0,0,0);
-
- if (p.v[0] < 50 && p.v[1] < 50 && Velocity == 0)
- {
- OnUpdateSignal.connect(boost::bind(&TMyApplication::RecreateLevel, this));
- }
-}
-
-void TMyApplication::InnerOnTapUpAfterMove(vec2 p)
-{
- RotateShift = vec2(0.f, 0.f);
-
- RotateAxis = vec3(0,0,0);
-}
-
-void TMyApplication::OnMouseWheel(short int delta)
-{
- OnUpdateSignal.connect(boost::bind(&TMyApplication::RecreateLevel, this));
-}
-
-void TMyApplication::UpdatePitVector(cardinal dt)
-{
-
- //Update pit vector
- vec3 camVec = boost::get(Renderer->Camera).CamVec;
-
- vec4 q;
-
- vec3 n = -Normalize(CrossProduct(camVec, PrevCamVec));
-
- float min_cos_a = min(DotProduct(camVec, PrevCamVec), 1.f);
-
- const float diff_alpha = pi/96;
-
- float angle = acos(min_cos_a);
-
-
- if (angle >= diff_alpha)
- {
- //Correcting PrevCamVec;
-
- min_cos_a = cosf(diff_alpha);
-
- vec4 quat(-n.v[0]*sin(diff_alpha/2.f), -n.v[1]*sin(diff_alpha/2.f), -n.v[2]*sin(diff_alpha/2.f), cos(diff_alpha/2.f));
-
- PrevCamVec = quat * vec4(camVec) * InverseQuat(quat);
- }
-
-
- //Catch up
-
- const float omega = 0.0002f;
-
- if (angle < omega*dt)
- {
- PrevCamVec = camVec;
- }
- else
- {
- vec4 delta_quat(n.v[0]*sin(omega * dt / 2.f), n.v[1]*sin(omega * dt / 2.f), n.v[2]*sin(omega * dt / 2.f), cos(omega * dt / 2.f));
-
- PrevCamVec = delta_quat * vec4(PrevCamVec) * InverseQuat(delta_quat);
- }
-
-
-
-}
-
-void TMyApplication::RecreateLevel()
-{
- Velocity = CONST_VELOCITY;
-
- boost::get(Renderer->Camera).CamShift = ZeroVec3;
-
- for (size_t i = 0; i < 3; ++i)
- {
- TubeModelArr[i] = GenerateFlexModel(0);
-
- TubeModelArr[i].PushModelDataTriangleList();
- TubeModelArr[i].ScaleModel(25.4f);
- TubeModelArr[i].MoveModel(vec3(0, 0, -2500.f*i));
-
- TubeModelArr[i].RefreshBuffer();
-
-
- TubeBodyArr[i].AssignFromFlexModel(GeneratePhysicsModel(0));
- TubeBodyArr[i].Scale(25.4f);
- TubeBodyArr[i].Move(vec3(0, 0, -2500.f*i));
-
- }
-}
\ No newline at end of file
diff --git a/jni/main_code.h b/jni/main_code.h
deleted file mode 100644
index 30f34c9..0000000
--- a/jni/main_code.h
+++ /dev/null
@@ -1,74 +0,0 @@
-#ifndef MAIN_CODE_H_INCLUDED
-#define MAIN_CODE_H_INCLUDED
-
-
-#include
-#include
-#include
-
-#ifdef TARGET_ANDROID
-
-#include
-#include
-#include
-#endif
-
-#include "boost/shared_ptr.hpp"
-#include "boost/thread/thread.hpp"
-#include "boost/assign.hpp"
-#include "boost/bind.hpp"
-#include "boost/asio.hpp"
-#include "boost/signal.hpp"
-
-#include "include/Engine.h"
-
-using namespace SE;
-
-class TMyApplication : public TApplication
-{
-protected:
-
-public:
- bool Inited;
-
- float Velocity;
-
- TFlexModel FlexModel;
-
- std::vector TubeModelArr;
- std::vector TubeBodyArr;
- //std::list> BoxList;
-
- vec3 PrevCamVec;
- vec3 RotateAxis;
- //float RotateShift;
- vec2 RotateShift;
-
- boost::signal OnUpdateSignal;
-
- TMyApplication() : TApplication(), Inited(false) { }
-
- virtual void InnerInit();
-
- virtual void InnerDeinit();
-
- virtual void InnerDraw();
-
- virtual void InnerUpdate(cardinal dt);
-
- bool IsInited() { return Inited; }
-
- virtual void InnerOnMove(vec2 shift);
- virtual void InnerOnTapUp(vec2 p);
- virtual void InnerOnTapUpAfterMove(vec2 p);
-
- virtual void OnMouseWheel(short int delta);
-
- void UpdatePitVector(cardinal dt);
-
- void RecreateLevel();
-
-};
-
-
-#endif
diff --git a/proj.android-studio/app/.gitignore b/proj.android-studio/app/.gitignore
new file mode 100755
index 0000000..796b96d
--- /dev/null
+++ b/proj.android-studio/app/.gitignore
@@ -0,0 +1 @@
+/build
diff --git a/proj.android-studio/app/CMakeLists.txt b/proj.android-studio/app/CMakeLists.txt
new file mode 100755
index 0000000..3fb40f2
--- /dev/null
+++ b/proj.android-studio/app/CMakeLists.txt
@@ -0,0 +1,96 @@
+# Sets the minimum version of CMake required to build the native
+# library. You should either keep the default value or only pass a
+# value of 3.4.0 or lower.
+
+cmake_minimum_required(VERSION 3.4.1)
+
+# Creates and names a library, sets it as either STATIC
+# or SHARED, and provides the relative paths to its source code.
+# You can define multiple libraries, and CMake builds it for you.
+# Gradle automatically packages shared libraries with your APK.
+
+
+add_definitions(-DTARGET_ANDROID)
+
+set(BOOST_PATH ${CMAKE_CURRENT_SOURCE_DIR}/../../../boost_1_63_0)
+
+set(BOOST_GIL_PATH ${CMAKE_CURRENT_SOURCE_DIR}/../../../libs/boost-gil-extension)
+
+set(ZIP_PATH ${CMAKE_CURRENT_SOURCE_DIR}/../../../libs/julienr-libzip-android/jni)
+
+set(LIBPNG_PATH ${CMAKE_CURRENT_SOURCE_DIR}/../../../libs/libpng_1.4.1_android)
+
+set(LIBJPEG_PATH "${CMAKE_CURRENT_SOURCE_DIR}/../../../libs/jpeg-9")
+
+
+include_directories(${CMAKE_CURRENT_SOURCE_DIR}/../../../engine)
+
+include_directories(${BOOST_PATH})
+include_directories(${LIBPNG_PATH})
+include_directories(${LIBJPEG_PATH})
+include_directories(${ZIP_PATH})
+
+include_directories(${BOOST_GIL_PATH})
+
+add_library( engine
+ SHARED
+ IMPORTED )
+
+set_target_properties( # Specifies the target library.
+ engine
+
+ # Specifies the parameter you want to define.
+ PROPERTIES IMPORTED_LOCATION
+
+ # Provides the path to the library you want to import.
+ ${CMAKE_CURRENT_SOURCE_DIR}/build/intermediates/exploded-aar/proj.android-studio/SalmonEngineAndroid/unspecified/jni/${ANDROID_ABI}/libengine.so )
+
+
+
+
+add_library( # Sets the name of the library.
+ Tunnel
+
+ # Sets the library as a shared library.
+ SHARED
+
+ # Provides a relative path to your source file(s).
+ # Associated headers in the same location as their source
+ # file are automatically included.
+ ${CMAKE_CURRENT_SOURCE_DIR}/../../game/android_api.cpp
+ ${CMAKE_CURRENT_SOURCE_DIR}/../../game/main_code.cpp
+ )
+
+
+
+# Searches for a specified prebuilt library and stores the path as a
+# variable. Because system libraries are included in the search path by
+# default, you only need to specify the name of the public NDK library
+# you want to add. CMake verifies that the library exists before
+# completing its build.
+
+find_library( # Sets the name of the path variable.
+ log-lib
+
+ # Specifies the name of the NDK library that
+ # you want CMake to locate.
+ log )
+
+find_library( # Sets the name of the path variable.
+ GLESv2-lib
+
+ # Specifies the name of the NDK library that
+ # you want CMake to locate.
+ GLESv2 )
+
+
+# Specifies libraries CMake should link to your target library. You
+# can link multiple libraries, such as libraries you define in the
+# build script, prebuilt third-party libraries, or system libraries.
+
+target_link_libraries( # Specifies the target library.
+ Tunnel
+
+ # Links the target library to the log library
+ # included in the NDK.
+ ${log-lib} ${GLESv2-lib} engine )
diff --git a/proj.android-studio/app/build.gradle b/proj.android-studio/app/build.gradle
new file mode 100755
index 0000000..ed49a8b
--- /dev/null
+++ b/proj.android-studio/app/build.gradle
@@ -0,0 +1,46 @@
+apply plugin: 'com.android.application'
+
+android {
+ compileSdkVersion 24
+ buildToolsVersion "24.0.1"
+ defaultConfig {
+ applicationId "fishrungames.tunnel"
+ minSdkVersion 15
+ targetSdkVersion 24
+ versionCode 1
+ versionName "1.0"
+ testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
+ externalNativeBuild {
+ cmake {
+ cppFlags "-std=c++11 -frtti -fexceptions -fsigned-char -Wno-c++11-narrowing"
+ }
+ }
+ }
+ buildTypes {
+ release {
+ minifyEnabled false
+ proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
+ }
+ }
+ externalNativeBuild {
+ cmake {
+ path "CMakeLists.txt"
+ }
+ }
+ sourceSets {
+ main {
+ assets.srcDirs = ['../../assets/']
+ }
+ }
+}
+
+dependencies {
+ compile fileTree(dir: 'libs', include: ['*.jar'])
+ androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.2', {
+ exclude group: 'com.android.support', module: 'support-annotations'
+ })
+ compile 'com.android.support:appcompat-v7:24.2.1'
+ testCompile 'junit:junit:4.12'
+
+ compile project(':SalmonEngineAndroid')
+}
diff --git a/proj.android-studio/app/proguard-rules.pro b/proj.android-studio/app/proguard-rules.pro
new file mode 100755
index 0000000..8a2f402
--- /dev/null
+++ b/proj.android-studio/app/proguard-rules.pro
@@ -0,0 +1,17 @@
+# Add project specific ProGuard rules here.
+# By default, the flags in this file are appended to flags specified
+# in C:\Android\sdk/tools/proguard/proguard-android.txt
+# You can edit the include path and order by changing the proguardFiles
+# directive in build.gradle.
+#
+# For more details, see
+# http://developer.android.com/guide/developing/tools/proguard.html
+
+# Add any project specific keep options here:
+
+# If your project uses WebView with JS, uncomment the following
+# and specify the fully qualified class name to the JavaScript interface
+# class:
+#-keepclassmembers class fqcn.of.javascript.interface.for.webview {
+# public *;
+#}
diff --git a/proj.android-studio/app/src/androidTest/java/fishrungames/tunnel/ExampleInstrumentedTest.java b/proj.android-studio/app/src/androidTest/java/fishrungames/tunnel/ExampleInstrumentedTest.java
new file mode 100755
index 0000000..97b7bf2
--- /dev/null
+++ b/proj.android-studio/app/src/androidTest/java/fishrungames/tunnel/ExampleInstrumentedTest.java
@@ -0,0 +1,26 @@
+package fishrungames.tunnel;
+
+import android.content.Context;
+import android.support.test.InstrumentationRegistry;
+import android.support.test.runner.AndroidJUnit4;
+
+import org.junit.Test;
+import org.junit.runner.RunWith;
+
+import static org.junit.Assert.*;
+
+/**
+ * Instrumentation test, which will execute on an Android device.
+ *
+ * @see Testing documentation
+ */
+@RunWith(AndroidJUnit4.class)
+public class ExampleInstrumentedTest {
+ @Test
+ public void useAppContext() throws Exception {
+ // Context of the app under test.
+ Context appContext = InstrumentationRegistry.getTargetContext();
+
+ assertEquals("fishrungames.salmonandroidtemplate", appContext.getPackageName());
+ }
+}
diff --git a/AndroidManifest.xml b/proj.android-studio/app/src/main/AndroidManifest.xml
old mode 100644
new mode 100755
similarity index 85%
rename from AndroidManifest.xml
rename to proj.android-studio/app/src/main/AndroidManifest.xml
index a4d56a2..84d37d3
--- a/AndroidManifest.xml
+++ b/proj.android-studio/app/src/main/AndroidManifest.xml
@@ -1,39 +1,39 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/fishrungames/salmonjnitemplate/GLView.java b/proj.android-studio/app/src/main/java/fishrungames/tunnel/GLView.java
old mode 100644
new mode 100755
similarity index 88%
rename from src/fishrungames/salmonjnitemplate/GLView.java
rename to proj.android-studio/app/src/main/java/fishrungames/tunnel/GLView.java
index 2242b0f..a306c57
--- a/src/fishrungames/salmonjnitemplate/GLView.java
+++ b/proj.android-studio/app/src/main/java/fishrungames/tunnel/GLView.java
@@ -1,72 +1,72 @@
-package fishrungames.salmonjnitemplate;
-
-
-import java.util.Calendar;
-
-import android.content.Context;
-import android.opengl.GLSurfaceView;
-
-import javax.microedition.khronos.egl.EGLConfig;
-import javax.microedition.khronos.opengles.GL10;
-
-import fishrungames.engine.GLViewAncestor;
-import fishrungames.engine.EngineWrapper;
-
-
-class GLView extends GLViewAncestor
-{
- static long lastTimeStamp;
- static boolean gameIsInited = false;
-
- public GLView(Context context)
- {
- //Change this method? Don't forget to change method below!
- super(context);
-
- //init(false, 0, 0);
- init(false, 8, 0); //Add depth buffer!
- }
-
- public GLView(Context context, boolean translucent, int depth, int stencil)
- {
- //Change this method? Don't forget to change method above!
- super(context);
- init(translucent, depth, stencil);
- }
-
- public void init(boolean translucent, int depth, int stencil)
- {
- super.init(translucent, depth, stencil);
- setRenderer(new Renderer());
- Calendar c = Calendar.getInstance();
- lastTimeStamp = c.getTimeInMillis();
- gameIsInited = true;
- }
-
- private static class Renderer implements GLSurfaceView.Renderer
- {
- public void onDrawFrame(GL10 gl)
- {
- if (gameIsInited)
- {
- Calendar c = Calendar.getInstance();
-
- long currentTimeStamp = c.getTimeInMillis();
-
- EngineWrapper.Update(currentTimeStamp - lastTimeStamp);
-
- lastTimeStamp = currentTimeStamp;
- }
- }
-
- public void onSurfaceChanged(GL10 gl, int width, int height)
- {
- JniWrapper.Init(width,height);
- }
-
- public void onSurfaceCreated(GL10 gl, EGLConfig config)
- {
- //Do nothing.
- }
- }
+package fishrungames.tunnel;
+
+
+import java.util.Calendar;
+
+import android.content.Context;
+import android.opengl.GLSurfaceView;
+
+import javax.microedition.khronos.egl.EGLConfig;
+import javax.microedition.khronos.opengles.GL10;
+
+import fishrungames.salmonengineandroid.GLViewAncestor;
+import fishrungames.salmonengineandroid.EngineWrapper;
+
+
+class GLView extends GLViewAncestor
+{
+ static long lastTimeStamp;
+ static boolean gameIsInited = false;
+
+ public GLView(Context context)
+ {
+ //Change this method? Don't forget to change method below!
+ super(context);
+
+ //init(false, 0, 0);
+ init(false, 8, 0); //Add depth buffer!
+ }
+
+ public GLView(Context context, boolean translucent, int depth, int stencil)
+ {
+ //Change this method? Don't forget to change method above!
+ super(context);
+ init(translucent, depth, stencil);
+ }
+
+ public void init(boolean translucent, int depth, int stencil)
+ {
+ super.init(translucent, depth, stencil);
+ setRenderer(new Renderer());
+ Calendar c = Calendar.getInstance();
+ lastTimeStamp = c.getTimeInMillis();
+ gameIsInited = true;
+ }
+
+ private static class Renderer implements GLSurfaceView.Renderer
+ {
+ public void onDrawFrame(GL10 gl)
+ {
+ if (gameIsInited)
+ {
+ Calendar c = Calendar.getInstance();
+
+ long currentTimeStamp = c.getTimeInMillis();
+
+ EngineWrapper.Update(currentTimeStamp - lastTimeStamp);
+
+ lastTimeStamp = currentTimeStamp;
+ }
+ }
+
+ public void onSurfaceChanged(GL10 gl, int width, int height)
+ {
+ JniWrapper.Init(width,height);
+ }
+
+ public void onSurfaceCreated(GL10 gl, EGLConfig config)
+ {
+ //Do nothing.
+ }
+ }
}
\ No newline at end of file
diff --git a/src/fishrungames/salmonjnitemplate/JniWrapper.java b/proj.android-studio/app/src/main/java/fishrungames/tunnel/JniWrapper.java
old mode 100644
new mode 100755
similarity index 53%
rename from src/fishrungames/salmonjnitemplate/JniWrapper.java
rename to proj.android-studio/app/src/main/java/fishrungames/tunnel/JniWrapper.java
index e7022b8..d8d8c11
--- a/src/fishrungames/salmonjnitemplate/JniWrapper.java
+++ b/proj.android-studio/app/src/main/java/fishrungames/tunnel/JniWrapper.java
@@ -1,12 +1,12 @@
-package fishrungames.salmonjnitemplate;
-
-public class JniWrapper
-{
- static {
- System.loadLibrary("SalmonJniTemplate");
- }
-
-
- public static native void Init(int width, int height);
-
+package fishrungames.tunnel;
+
+public class JniWrapper
+{
+ static {
+ System.loadLibrary("Tunnel");
+ }
+
+
+ public static native void Init(int width, int height);
+
}
\ No newline at end of file
diff --git a/src/fishrungames/salmonjnitemplate/MainActivity.java b/proj.android-studio/app/src/main/java/fishrungames/tunnel/MainActivity.java
old mode 100644
new mode 100755
similarity index 88%
rename from src/fishrungames/salmonjnitemplate/MainActivity.java
rename to proj.android-studio/app/src/main/java/fishrungames/tunnel/MainActivity.java
index c2bed66..ba4a21a
--- a/src/fishrungames/salmonjnitemplate/MainActivity.java
+++ b/proj.android-studio/app/src/main/java/fishrungames/tunnel/MainActivity.java
@@ -1,112 +1,112 @@
-package fishrungames.salmonjnitemplate;
-
-import fishrungames.engine.EngineWrapper;
-
-//Deprecated
-//import fishrungames.androidjnitemplate.R;
-
-import android.app.Activity;
-import android.content.pm.ApplicationInfo;
-import android.content.pm.PackageManager;
-import android.content.pm.PackageManager.NameNotFoundException;
-import android.os.Bundle;
-
-import android.view.GestureDetector;
-import android.view.KeyEvent;
-import android.view.GestureDetector.SimpleOnGestureListener;
-import android.view.MotionEvent;
-/*
-import android.content.res.Resources;
-import android.content.res.XmlResourceParser;
-import android.util.AttributeSet;
-import android.util.Xml;
-import android.inputmethodservice.Keyboard;
-import android.inputmethodservice.KeyboardView;
-import android.view.ViewGroup.LayoutParams;
-import android.widget.LinearLayout;
-*/
-
-//Deprecated
-//import java.lang.reflect.Field;
-
-import java.lang.Math;
-
-public class MainActivity extends Activity
-{
-
- GLView mView;
-
- @Override
- protected void onCreate(Bundle icicle)
- {
-
- super.onCreate(icicle);
-
- EngineWrapper.LoadSalmonEngineLibrary();
-
- EngineWrapper.SetActivityInstance(this);
- EngineWrapper.SetupEnviroment();
-
-
- String apkFilePath = null;
- ApplicationInfo appInfo = null;
- PackageManager packMgmr = this.getPackageManager();
- try {
- appInfo = packMgmr.getApplicationInfo("fishrungames.salmonjnitemplate", 0);
- } catch (NameNotFoundException e) {
-
- e.printStackTrace();
- throw new RuntimeException("Unable to locate assets, aborting...");
- }
- apkFilePath = appInfo.sourceDir;
-
- EngineWrapper.SetupApkFilePath(apkFilePath);
-
- mView = new GLView(getApplication());
-
-
- setContentView(mView);
-
- EngineWrapper.SetView(mView);
-
- }
-
-
- @Override
- protected void onPause()
- {
-
- EngineWrapper.CallDestroy();
- super.onPause();
- mView.onPause();
- }
-
- @Override
- protected void onResume()
- {
- //Don't write anything here!
- super.onResume();
- mView.onResume();
- }
-
- @Override
- protected void onStop()
- {
- //Don't write anything here!
- super.onStop();
- }
-
- public boolean onKeyDown(int keyCode, KeyEvent event)
- {
- EngineWrapper.ProcessKeyDown(keyCode, event);
- return super.onKeyDown(keyCode, event);
- }
-
- public boolean onTouchEvent(MotionEvent event)
- {
- EngineWrapper.ProcessTouchEvent(event);
- return true;
- }
-
-
+package fishrungames.tunnel;
+
+import fishrungames.salmonengineandroid.EngineWrapper;
+
+//Deprecated
+//import fishrungames.androidjnitemplate.R;
+
+import android.app.Activity;
+import android.content.pm.ApplicationInfo;
+import android.content.pm.PackageManager;
+import android.content.pm.PackageManager.NameNotFoundException;
+import android.os.Bundle;
+
+import android.view.GestureDetector;
+import android.view.KeyEvent;
+import android.view.GestureDetector.SimpleOnGestureListener;
+import android.view.MotionEvent;
+/*
+import android.content.res.Resources;
+import android.content.res.XmlResourceParser;
+import android.util.AttributeSet;
+import android.util.Xml;
+import android.inputmethodservice.Keyboard;
+import android.inputmethodservice.KeyboardView;
+import android.view.ViewGroup.LayoutParams;
+import android.widget.LinearLayout;
+*/
+
+//Deprecated
+//import java.lang.reflect.Field;
+
+import java.lang.Math;
+
+public class MainActivity extends Activity
+{
+
+ GLView mView;
+
+ @Override
+ protected void onCreate(Bundle icicle)
+ {
+
+ super.onCreate(icicle);
+
+ EngineWrapper.LoadSalmonEngineLibrary();
+
+ EngineWrapper.SetActivityInstance(this);
+ EngineWrapper.SetupEnviroment();
+
+
+ String apkFilePath = null;
+ ApplicationInfo appInfo = null;
+ PackageManager packMgmr = this.getPackageManager();
+ try {
+ appInfo = packMgmr.getApplicationInfo("fishrungames.tunnel", 0);
+ } catch (NameNotFoundException e) {
+
+ e.printStackTrace();
+ throw new RuntimeException("Unable to locate assets, aborting...");
+ }
+ apkFilePath = appInfo.sourceDir;
+
+ EngineWrapper.SetupApkFilePath(apkFilePath);
+
+ mView = new GLView(getApplication());
+
+
+ setContentView(mView);
+
+ EngineWrapper.SetView(mView);
+
+ }
+
+
+ @Override
+ protected void onPause()
+ {
+
+ EngineWrapper.CallDestroy();
+ super.onPause();
+ mView.onPause();
+ }
+
+ @Override
+ protected void onResume()
+ {
+ //Don't write anything here!
+ super.onResume();
+ mView.onResume();
+ }
+
+ @Override
+ protected void onStop()
+ {
+ //Don't write anything here!
+ super.onStop();
+ }
+
+ public boolean onKeyDown(int keyCode, KeyEvent event)
+ {
+ EngineWrapper.ProcessKeyDown(keyCode, event);
+ return super.onKeyDown(keyCode, event);
+ }
+
+ public boolean onTouchEvent(MotionEvent event)
+ {
+ EngineWrapper.ProcessTouchEvent(event);
+ return true;
+ }
+
+
}
\ No newline at end of file
diff --git a/res/drawable-hdpi/ic_menu_template.png b/proj.android-studio/app/src/main/res/drawable-hdpi/ic_menu_template.png
similarity index 100%
rename from res/drawable-hdpi/ic_menu_template.png
rename to proj.android-studio/app/src/main/res/drawable-hdpi/ic_menu_template.png
diff --git a/res/drawable-ldpi/ic_menu_template.png b/proj.android-studio/app/src/main/res/drawable-ldpi/ic_menu_template.png
similarity index 100%
rename from res/drawable-ldpi/ic_menu_template.png
rename to proj.android-studio/app/src/main/res/drawable-ldpi/ic_menu_template.png
diff --git a/res/drawable-mdpi/ic_menu_template.png b/proj.android-studio/app/src/main/res/drawable-mdpi/ic_menu_template.png
similarity index 100%
rename from res/drawable-mdpi/ic_menu_template.png
rename to proj.android-studio/app/src/main/res/drawable-mdpi/ic_menu_template.png
diff --git a/res/values/strings.xml b/proj.android-studio/app/src/main/res/values/strings.xml
similarity index 96%
rename from res/values/strings.xml
rename to proj.android-studio/app/src/main/res/values/strings.xml
index 33d1455..b8fcfcd 100644
--- a/res/values/strings.xml
+++ b/proj.android-studio/app/src/main/res/values/strings.xml
@@ -1,4 +1,4 @@
-
-
- AndroidJniTemplate
-
+
+
+ AndroidJniTemplate
+
diff --git a/proj.android-studio/app/src/test/java/fishrungames/tunnel/ExampleUnitTest.java b/proj.android-studio/app/src/test/java/fishrungames/tunnel/ExampleUnitTest.java
new file mode 100755
index 0000000..2a1c8ba
--- /dev/null
+++ b/proj.android-studio/app/src/test/java/fishrungames/tunnel/ExampleUnitTest.java
@@ -0,0 +1,17 @@
+package fishrungames.tunnel;
+
+import org.junit.Test;
+
+import static org.junit.Assert.*;
+
+/**
+ * Example local unit test, which will execute on the development machine (host).
+ *
+ * @see Testing documentation
+ */
+public class ExampleUnitTest {
+ @Test
+ public void addition_isCorrect() throws Exception {
+ assertEquals(4, 2 + 2);
+ }
+}
\ No newline at end of file
diff --git a/proj.android-studio/build.gradle b/proj.android-studio/build.gradle
new file mode 100755
index 0000000..74b2ab0
--- /dev/null
+++ b/proj.android-studio/build.gradle
@@ -0,0 +1,23 @@
+// Top-level build file where you can add configuration options common to all sub-projects/modules.
+
+buildscript {
+ repositories {
+ jcenter()
+ }
+ dependencies {
+ classpath 'com.android.tools.build:gradle:2.2.3'
+
+ // NOTE: Do not place your application dependencies here; they belong
+ // in the individual module build.gradle files
+ }
+}
+
+allprojects {
+ repositories {
+ jcenter()
+ }
+}
+
+task clean(type: Delete) {
+ delete rootProject.buildDir
+}
diff --git a/proj.android-studio/gradle.properties b/proj.android-studio/gradle.properties
new file mode 100755
index 0000000..aac7c9b
--- /dev/null
+++ b/proj.android-studio/gradle.properties
@@ -0,0 +1,17 @@
+# Project-wide Gradle settings.
+
+# IDE (e.g. Android Studio) users:
+# Gradle settings configured through the IDE *will override*
+# any settings specified in this file.
+
+# For more details on how to configure your build environment visit
+# http://www.gradle.org/docs/current/userguide/build_environment.html
+
+# Specifies the JVM arguments used for the daemon process.
+# The setting is particularly useful for tweaking memory settings.
+org.gradle.jvmargs=-Xmx1536m
+
+# When configured, Gradle will run in incubating parallel mode.
+# This option should only be used with decoupled projects. More details, visit
+# http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects
+# org.gradle.parallel=true
diff --git a/proj.android-studio/gradle/wrapper/gradle-wrapper.jar b/proj.android-studio/gradle/wrapper/gradle-wrapper.jar
new file mode 100755
index 0000000..13372ae
Binary files /dev/null and b/proj.android-studio/gradle/wrapper/gradle-wrapper.jar differ
diff --git a/proj.android-studio/gradle/wrapper/gradle-wrapper.properties b/proj.android-studio/gradle/wrapper/gradle-wrapper.properties
new file mode 100755
index 0000000..04e285f
--- /dev/null
+++ b/proj.android-studio/gradle/wrapper/gradle-wrapper.properties
@@ -0,0 +1,6 @@
+#Mon Dec 28 10:00:20 PST 2015
+distributionBase=GRADLE_USER_HOME
+distributionPath=wrapper/dists
+zipStoreBase=GRADLE_USER_HOME
+zipStorePath=wrapper/dists
+distributionUrl=https\://services.gradle.org/distributions/gradle-2.14.1-all.zip
diff --git a/proj.android-studio/gradlew b/proj.android-studio/gradlew
new file mode 100755
index 0000000..9d82f78
--- /dev/null
+++ b/proj.android-studio/gradlew
@@ -0,0 +1,160 @@
+#!/usr/bin/env bash
+
+##############################################################################
+##
+## Gradle start up script for UN*X
+##
+##############################################################################
+
+# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
+DEFAULT_JVM_OPTS=""
+
+APP_NAME="Gradle"
+APP_BASE_NAME=`basename "$0"`
+
+# Use the maximum available, or set MAX_FD != -1 to use that value.
+MAX_FD="maximum"
+
+warn ( ) {
+ echo "$*"
+}
+
+die ( ) {
+ echo
+ echo "$*"
+ echo
+ exit 1
+}
+
+# OS specific support (must be 'true' or 'false').
+cygwin=false
+msys=false
+darwin=false
+case "`uname`" in
+ CYGWIN* )
+ cygwin=true
+ ;;
+ Darwin* )
+ darwin=true
+ ;;
+ MINGW* )
+ msys=true
+ ;;
+esac
+
+# Attempt to set APP_HOME
+# Resolve links: $0 may be a link
+PRG="$0"
+# Need this for relative symlinks.
+while [ -h "$PRG" ] ; do
+ ls=`ls -ld "$PRG"`
+ link=`expr "$ls" : '.*-> \(.*\)$'`
+ if expr "$link" : '/.*' > /dev/null; then
+ PRG="$link"
+ else
+ PRG=`dirname "$PRG"`"/$link"
+ fi
+done
+SAVED="`pwd`"
+cd "`dirname \"$PRG\"`/" >/dev/null
+APP_HOME="`pwd -P`"
+cd "$SAVED" >/dev/null
+
+CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar
+
+# Determine the Java command to use to start the JVM.
+if [ -n "$JAVA_HOME" ] ; then
+ if [ -x "$JAVA_HOME/jre/sh/java" ] ; then
+ # IBM's JDK on AIX uses strange locations for the executables
+ JAVACMD="$JAVA_HOME/jre/sh/java"
+ else
+ JAVACMD="$JAVA_HOME/bin/java"
+ fi
+ if [ ! -x "$JAVACMD" ] ; then
+ die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME
+
+Please set the JAVA_HOME variable in your environment to match the
+location of your Java installation."
+ fi
+else
+ JAVACMD="java"
+ which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
+
+Please set the JAVA_HOME variable in your environment to match the
+location of your Java installation."
+fi
+
+# Increase the maximum file descriptors if we can.
+if [ "$cygwin" = "false" -a "$darwin" = "false" ] ; then
+ MAX_FD_LIMIT=`ulimit -H -n`
+ if [ $? -eq 0 ] ; then
+ if [ "$MAX_FD" = "maximum" -o "$MAX_FD" = "max" ] ; then
+ MAX_FD="$MAX_FD_LIMIT"
+ fi
+ ulimit -n $MAX_FD
+ if [ $? -ne 0 ] ; then
+ warn "Could not set maximum file descriptor limit: $MAX_FD"
+ fi
+ else
+ warn "Could not query maximum file descriptor limit: $MAX_FD_LIMIT"
+ fi
+fi
+
+# For Darwin, add options to specify how the application appears in the dock
+if $darwin; then
+ GRADLE_OPTS="$GRADLE_OPTS \"-Xdock:name=$APP_NAME\" \"-Xdock:icon=$APP_HOME/media/gradle.icns\""
+fi
+
+# For Cygwin, switch paths to Windows format before running java
+if $cygwin ; then
+ APP_HOME=`cygpath --path --mixed "$APP_HOME"`
+ CLASSPATH=`cygpath --path --mixed "$CLASSPATH"`
+ JAVACMD=`cygpath --unix "$JAVACMD"`
+
+ # We build the pattern for arguments to be converted via cygpath
+ ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null`
+ SEP=""
+ for dir in $ROOTDIRSRAW ; do
+ ROOTDIRS="$ROOTDIRS$SEP$dir"
+ SEP="|"
+ done
+ OURCYGPATTERN="(^($ROOTDIRS))"
+ # Add a user-defined pattern to the cygpath arguments
+ if [ "$GRADLE_CYGPATTERN" != "" ] ; then
+ OURCYGPATTERN="$OURCYGPATTERN|($GRADLE_CYGPATTERN)"
+ fi
+ # Now convert the arguments - kludge to limit ourselves to /bin/sh
+ i=0
+ for arg in "$@" ; do
+ CHECK=`echo "$arg"|egrep -c "$OURCYGPATTERN" -`
+ CHECK2=`echo "$arg"|egrep -c "^-"` ### Determine if an option
+
+ if [ $CHECK -ne 0 ] && [ $CHECK2 -eq 0 ] ; then ### Added a condition
+ eval `echo args$i`=`cygpath --path --ignore --mixed "$arg"`
+ else
+ eval `echo args$i`="\"$arg\""
+ fi
+ i=$((i+1))
+ done
+ case $i in
+ (0) set -- ;;
+ (1) set -- "$args0" ;;
+ (2) set -- "$args0" "$args1" ;;
+ (3) set -- "$args0" "$args1" "$args2" ;;
+ (4) set -- "$args0" "$args1" "$args2" "$args3" ;;
+ (5) set -- "$args0" "$args1" "$args2" "$args3" "$args4" ;;
+ (6) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" ;;
+ (7) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" ;;
+ (8) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" ;;
+ (9) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" "$args8" ;;
+ esac
+fi
+
+# Split up the JVM_OPTS And GRADLE_OPTS values into an array, following the shell quoting and substitution rules
+function splitJvmOpts() {
+ JVM_OPTS=("$@")
+}
+eval splitJvmOpts $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS
+JVM_OPTS[${#JVM_OPTS[*]}]="-Dorg.gradle.appname=$APP_BASE_NAME"
+
+exec "$JAVACMD" "${JVM_OPTS[@]}" -classpath "$CLASSPATH" org.gradle.wrapper.GradleWrapperMain "$@"
diff --git a/proj.android-studio/gradlew.bat b/proj.android-studio/gradlew.bat
new file mode 100755
index 0000000..8a0b282
--- /dev/null
+++ b/proj.android-studio/gradlew.bat
@@ -0,0 +1,90 @@
+@if "%DEBUG%" == "" @echo off
+@rem ##########################################################################
+@rem
+@rem Gradle startup script for Windows
+@rem
+@rem ##########################################################################
+
+@rem Set local scope for the variables with windows NT shell
+if "%OS%"=="Windows_NT" setlocal
+
+@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
+set DEFAULT_JVM_OPTS=
+
+set DIRNAME=%~dp0
+if "%DIRNAME%" == "" set DIRNAME=.
+set APP_BASE_NAME=%~n0
+set APP_HOME=%DIRNAME%
+
+@rem Find java.exe
+if defined JAVA_HOME goto findJavaFromJavaHome
+
+set JAVA_EXE=java.exe
+%JAVA_EXE% -version >NUL 2>&1
+if "%ERRORLEVEL%" == "0" goto init
+
+echo.
+echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
+echo.
+echo Please set the JAVA_HOME variable in your environment to match the
+echo location of your Java installation.
+
+goto fail
+
+:findJavaFromJavaHome
+set JAVA_HOME=%JAVA_HOME:"=%
+set JAVA_EXE=%JAVA_HOME%/bin/java.exe
+
+if exist "%JAVA_EXE%" goto init
+
+echo.
+echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%
+echo.
+echo Please set the JAVA_HOME variable in your environment to match the
+echo location of your Java installation.
+
+goto fail
+
+:init
+@rem Get command-line arguments, handling Windowz variants
+
+if not "%OS%" == "Windows_NT" goto win9xME_args
+if "%@eval[2+2]" == "4" goto 4NT_args
+
+:win9xME_args
+@rem Slurp the command line arguments.
+set CMD_LINE_ARGS=
+set _SKIP=2
+
+:win9xME_args_slurp
+if "x%~1" == "x" goto execute
+
+set CMD_LINE_ARGS=%*
+goto execute
+
+:4NT_args
+@rem Get arguments from the 4NT Shell from JP Software
+set CMD_LINE_ARGS=%$
+
+:execute
+@rem Setup the command line
+
+set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar
+
+@rem Execute Gradle
+"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS%
+
+:end
+@rem End local scope for the variables with windows NT shell
+if "%ERRORLEVEL%"=="0" goto mainEnd
+
+:fail
+rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of
+rem the _cmd.exe /c_ return code!
+if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1
+exit /b 1
+
+:mainEnd
+if "%OS%"=="Windows_NT" endlocal
+
+:omega
diff --git a/proj.android-studio/settings.gradle b/proj.android-studio/settings.gradle
new file mode 100755
index 0000000..f82ab8b
--- /dev/null
+++ b/proj.android-studio/settings.gradle
@@ -0,0 +1,7 @@
+include ':SalmonEngineAndroid'
+project(':SalmonEngineAndroid').projectDir =new File(settingsDir, '../../engine/SalmonEngineAndroid/app')
+
+
+include ':app'
+
+