Commit ac587dec authored by fallenstardust's avatar fallenstardust

整理

parent 85c661c3
......@@ -3312,12 +3312,24 @@ int32 card::is_removeable(uint8 playerid) {
return TRUE;
}
int32 card::is_removeable_as_cost(uint8 playerid) {
uint32 redirect = 0;
uint32 dest = LOCATION_REMOVED;
if(current.location == LOCATION_REMOVED)
return FALSE;
if(is_affected_by_effect(EFFECT_CANNOT_USE_AS_COST))
return FALSE;
if(!is_removeable(playerid))
return FALSE;
auto op_param = sendto_param;
sendto_param.location = dest;
if(current.location & LOCATION_ONFIELD)
redirect = leave_field_redirect(REASON_COST) & 0xffff;
if(redirect) dest = redirect;
redirect = destination_redirect(dest, REASON_COST) & 0xffff;
if(redirect) dest = redirect;
sendto_param = op_param;
if(dest != LOCATION_REMOVED)
return FALSE;
return TRUE;
}
int32 card::is_releasable_by_summon(uint8 playerid, card *pcard) {
......
......@@ -28,7 +28,7 @@
2.开放单人模式——离线人机★
3.复制约战口令即可快捷加房★
修复:
1.删除房间无法取消的问题;
1.删除房间确认时无法取消的问题;
2.已知若干卡图错误;
3.游戏房间准备界面无法发送聊天消息的问题;
优化:
......
......@@ -8,7 +8,7 @@ android {
applicationId "cn.garymb.ygomobile"
minSdkVersion 16
targetSdkVersion 22
versionCode 33000529
versionCode 33000530
versionName "3.3.0"
flavorDimensions "versionCode"
vectorDrawables.useSupportLibrary = true
......
......@@ -155,13 +155,14 @@ abstract class HomeActivity extends BaseActivity implements NavigationView.OnNav
switch (id) {
case R.id.nav_donation: {
final DialogPlus dialog = new DialogPlus(getContext());
final DialogPlus dialog = new DialogPlus(getContext());
dialog.setContentView(R.layout.dialog_alipay_or_wechat);
dialog.setTitle(R.string.logo_text);
dialog.show();
View viewDialog= dialog.getContentView();
Button btnalipay= viewDialog.findViewById(R.id.button_alipay);
Button btnwechat= viewDialog.findViewById(R.id.button_wechat);
View viewDialog = dialog.getContentView();
Button btnalipay = viewDialog.findViewById(R.id.button_alipay);
Button btnwechat = viewDialog.findViewById(R.id.button_wechat);
Button btnpaypal = viewDialog.findViewById(R.id.button_paypal);
btnalipay.setOnClickListener((v) -> {
AlipayPayUtils.openAlipayPayPage(getContext(), Constants.ALIPAY_URL);
......@@ -173,7 +174,12 @@ abstract class HomeActivity extends BaseActivity implements NavigationView.OnNav
AlipayPayUtils.inputMoney(HomeActivity.this);
dialog.dismiss();
});
btnpaypal.setOnClickListener((v) -> {
Uri uri = Uri.parse("https://www.paypal.me/YGOmobile3");
Intent intent = new Intent(Intent.ACTION_VIEW, uri);
startActivity(intent);
dialog.dismiss();
});
}
break;
case R.id.action_game:
......
......@@ -26,5 +26,16 @@
android:layout_height="50dp"
android:background="@drawable/wechat" />
<TextView
android:layout_width="@dimen/label_width_middle"
android:layout_height="wrap_content"
android:textAppearance="@style/TextAppearance.AppCompat.Body1"
android:textColor="@color/gold" />
<Button
android:id="@+id/button_paypal"
android:layout_width="50dp"
android:layout_height="50dp"
android:background="@drawable/paypal" />
</LinearLayout>
</LinearLayout>
\ No newline at end of file
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