Commit e4e6f858 authored by fallenstardust's avatar fallenstardust

C++14

parent ff272af9
......@@ -1903,11 +1903,7 @@ void card::reset(uint32 id, uint32 reset_type) {
}
}
if(id & RESET_TURN_SET) {
#ifdef _IRR_ANDROID_PLATFORM_
effect* peffect = std::get<1>(refresh_control_status());
#else
effect* peffect = std::get<effect*>(refresh_control_status());
#endif
if(peffect && (!(peffect->type & EFFECT_TYPE_SINGLE) || peffect->condition)) {
effect* new_effect = pduel->new_effect();
new_effect->id = peffect->id;
......
......@@ -523,11 +523,7 @@ void field::swap_card(card* pcard1, card* pcard2) {
return swap_card(pcard1, pcard2, pcard1->current.sequence, pcard2->current.sequence);
}
void field::set_control(card* pcard, uint8 playerid, uint16 reset_phase, uint8 reset_count) {
#ifdef _IRR_ANDROID_PLATFORM_
if((core.remove_brainwashing && pcard->is_affected_by_effect(EFFECT_REMOVE_BRAINWASHING)) || std::get<0>(pcard->refresh_control_status()) == playerid)
#else
if((core.remove_brainwashing && pcard->is_affected_by_effect(EFFECT_REMOVE_BRAINWASHING)) || std::get<uint8>(pcard->refresh_control_status()) == playerid)
#endif
return;
effect* peffect = pduel->new_effect();
if(core.reason_effect)
......
......@@ -4864,13 +4864,8 @@ int32 field::adjust_step(uint16 step) {
if(!pcard) continue;
uint8 cur = pcard->current.controler;
auto res = pcard->refresh_control_status();
#ifdef _IRR_ANDROID_PLATFORM_
uint8 ref = std::get<0>(res);
effect* peffect = std::get<1>(res);
#else
uint8 ref = std::get<uint8>(res);
effect* peffect = std::get<effect*>(res);
#endif
if(cur != ref && pcard->is_capable_change_control()) {
core.control_adjust_set[p].insert(pcard);
if(peffect && (!(peffect->type & EFFECT_TYPE_SINGLE) || peffect->condition))
......
......@@ -4,7 +4,7 @@ android {
compileSdkVersion rootProject.ext.compileSdkVersion
defaultConfig {
minSdkVersion 16
minSdkVersion 21
targetSdkVersion 28
flavorDimensions "versionCode"
/* ndk {
......
APP_ABI := armeabi-v7a x86
#APP_ABI := armeabi-v7a x86
APP_PLATFORM := android-14
APP_PLATFORM := android-21
#APP_MODULES := YGOMobile
#NDK_TOOLCHAIN_VERSION=4.8
APP_ALLOW_MISSING_DEPS=true
#APP_STL := gnustl_static
APP_STL := c++_static
APP_CPPFLAGS := -Wno-error=format-security -std=gnu++11 -fpermissive -D__cplusplus=201103L
APP_CPPFLAGS := -Wno-error=format-security -std=gnu++14 -fpermissive -D__cplusplus=201402L
APP_OPTIM := release
......@@ -4,13 +4,13 @@ android {
compileSdkVersion rootProject.ext.compileSdkVersion
defaultConfig {
minSdkVersion 16
minSdkVersion 21
//noinspection ExpiredTargetSdkVersion
targetSdkVersion 22
targetSdkVersion 28
ndk {
moduleName "YGOMobile"
abiFilters "armeabi-v7a"//,"x86"
abiFilters "armeabi-v7a","x86"
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment