ios stuff
This commit is contained in:
parent
f2dca8749b
commit
4e695fe902
@ -1,52 +1,55 @@
|
|||||||
#include "include/Engine.h"
|
#include "include/Engine.h"
|
||||||
#include "main_code.h"
|
#include "main_code.h"
|
||||||
|
|
||||||
TMyApplication App;
|
TMyApplication* App;
|
||||||
|
|
||||||
|
|
||||||
extern "C" void AppInit()
|
extern "C" void AppInit()
|
||||||
{
|
{
|
||||||
|
CreateEngine();
|
||||||
|
App = new TMyApplication;
|
||||||
|
App->OuterInit(480, 320, 480, 320);
|
||||||
|
|
||||||
App.OuterInit(480, 320, 480, 320);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
extern "C" void AppDeinit()
|
extern "C" void AppDeinit()
|
||||||
{
|
{
|
||||||
App.OuterDeinit();
|
|
||||||
|
App->OuterDeinit();
|
||||||
|
delete App;
|
||||||
|
DestroyEngine();
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
extern "C" void AppUpdate(int dt)
|
extern "C" void AppUpdate(int dt)
|
||||||
{
|
{
|
||||||
App.OuterUpdate(dt);
|
App->OuterUpdate(dt);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
extern "C" void AppDraw()
|
extern "C" void AppDraw()
|
||||||
{
|
{
|
||||||
App.OuterDraw();
|
App->OuterDraw();
|
||||||
}
|
}
|
||||||
|
|
||||||
extern "C" void AppOnTapDown(int posx, int posy)
|
extern "C" void AppOnTapDown(int posx, int posy)
|
||||||
{
|
{
|
||||||
App.OuterOnTapDown(vec2(posx, posy));
|
App->OuterOnTapDown(vec2(posx, posy));
|
||||||
}
|
}
|
||||||
|
|
||||||
extern "C" void AppOnTapUp(int posx, int posy)
|
extern "C" void AppOnTapUp(int posx, int posy)
|
||||||
{
|
{
|
||||||
App.OuterOnTapUp(vec2(posx, posy));
|
App->OuterOnTapUp(vec2(posx, posy));
|
||||||
}
|
}
|
||||||
|
|
||||||
extern "C" void AppOnTapUpAfterScroll(int posx, int posy)
|
extern "C" void AppOnTapUpAfterScroll(int posx, int posy)
|
||||||
{
|
{
|
||||||
App.OuterOnTapUpAfterShift(vec2(posx, posy));
|
App->OuterOnTapUpAfterShift(vec2(posx, posy));
|
||||||
}
|
}
|
||||||
|
|
||||||
extern "C" void AppOnScroll(int shiftx, int shifty)
|
extern "C" void AppOnScroll(int shiftx, int shifty)
|
||||||
{
|
{
|
||||||
App.OuterOnMove(vec2(shiftx, shifty));
|
App->OuterOnMove(vec2(shiftx, shifty));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -41,7 +41,7 @@ LOCAL_PATH:= $(LPATH)
|
|||||||
|
|
||||||
include $(CLEAR_VARS)
|
include $(CLEAR_VARS)
|
||||||
|
|
||||||
LOCAL_CFLAGS := -DTARGET_ANDROID -DNOSOUND -DTARGET_SALMON -std=gnu++11 --std=c++11
|
LOCAL_CFLAGS := -DTARGET_ANDROID -DNOSOUND -std=gnu++11 --std=c++11
|
||||||
LOCAL_STATIC_LIBRARIES := boost
|
LOCAL_STATIC_LIBRARIES := boost
|
||||||
LOCAL_STATIC_LIBRARIES += squirrel
|
LOCAL_STATIC_LIBRARIES += squirrel
|
||||||
LOCAL_STATIC_LIBRARIES += png_lib
|
LOCAL_STATIC_LIBRARIES += png_lib
|
||||||
|
@ -49,7 +49,7 @@
|
|||||||
<WarningLevel>Level3</WarningLevel>
|
<WarningLevel>Level3</WarningLevel>
|
||||||
<Optimization>Disabled</Optimization>
|
<Optimization>Disabled</Optimization>
|
||||||
<AdditionalIncludeDirectories>../../../jni;$(SalmonEnginePath);$(LibsPath)\boost_1_52_0;$(LibsPath)\libogg-1.3.0\include;$(LibsPath)\libvorbis-1.3.2\include;$(LibsPath)\sqplus\sqplus;$(LibsPath)\sqplus\include;$(LibsPath)\DirectXsdk\Include;$(LibsPath)\lpng1510</AdditionalIncludeDirectories>
|
<AdditionalIncludeDirectories>../../../jni;$(SalmonEnginePath);$(LibsPath)\boost_1_52_0;$(LibsPath)\libogg-1.3.0\include;$(LibsPath)\libvorbis-1.3.2\include;$(LibsPath)\sqplus\sqplus;$(LibsPath)\sqplus\include;$(LibsPath)\DirectXsdk\Include;$(LibsPath)\lpng1510</AdditionalIncludeDirectories>
|
||||||
<PreprocessorDefinitions>TARGET_WIN32;TARGET_SALMON;WIN32_LEAN_AND_MEAN;_WIN32_WINNT=0x0501;DEBUG</PreprocessorDefinitions>
|
<PreprocessorDefinitions>TARGET_WIN32;WIN32_LEAN_AND_MEAN;_WIN32_WINNT=0x0501;DEBUG</PreprocessorDefinitions>
|
||||||
<DisableSpecificWarnings>4503</DisableSpecificWarnings>
|
<DisableSpecificWarnings>4503</DisableSpecificWarnings>
|
||||||
</ClCompile>
|
</ClCompile>
|
||||||
<Link>
|
<Link>
|
||||||
@ -65,7 +65,7 @@
|
|||||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||||
<AdditionalIncludeDirectories>../../../jni;$(SalmonEnginePath);$(LibsPath)\boost_1_52_0;$(LibsPath)\libogg-1.3.0\include;$(LibsPath)\libvorbis-1.3.2\include;$(LibsPath)\sqplus\sqplus;$(LibsPath)\sqplus\include;$(LibsPath)\DirectXsdk\Include;$(LibsPath)\lpng1510</AdditionalIncludeDirectories>
|
<AdditionalIncludeDirectories>../../../jni;$(SalmonEnginePath);$(LibsPath)\boost_1_52_0;$(LibsPath)\libogg-1.3.0\include;$(LibsPath)\libvorbis-1.3.2\include;$(LibsPath)\sqplus\sqplus;$(LibsPath)\sqplus\include;$(LibsPath)\DirectXsdk\Include;$(LibsPath)\lpng1510</AdditionalIncludeDirectories>
|
||||||
<PreprocessorDefinitions>TARGET_WIN32;TARGET_SALMON;WIN32_LEAN_AND_MEAN;_WIN32_WINNT=0x0501;NDEBUG</PreprocessorDefinitions>
|
<PreprocessorDefinitions>TARGET_WIN32;WIN32_LEAN_AND_MEAN;_WIN32_WINNT=0x0501;NDEBUG</PreprocessorDefinitions>
|
||||||
<DisableSpecificWarnings>4503</DisableSpecificWarnings>
|
<DisableSpecificWarnings>4503</DisableSpecificWarnings>
|
||||||
</ClCompile>
|
</ClCompile>
|
||||||
<Link>
|
<Link>
|
||||||
|
Loading…
Reference in New Issue
Block a user