first commit
10
.claude/settings.local.json
Normal file
@ -0,0 +1,10 @@
|
||||
{
|
||||
"permissions": {
|
||||
"allow": [
|
||||
"Bash(mkdir:*)",
|
||||
"Bash(cp:*)",
|
||||
"Bash(rm:*)"
|
||||
],
|
||||
"deny": []
|
||||
}
|
||||
}
|
||||
15
.gitignore
vendored
Normal file
@ -0,0 +1,15 @@
|
||||
*.iml
|
||||
.gradle
|
||||
/local.properties
|
||||
/.idea/caches
|
||||
/.idea/libraries
|
||||
/.idea/modules.xml
|
||||
/.idea/workspace.xml
|
||||
/.idea/navEditor.xml
|
||||
/.idea/assetWizardSettings.xml
|
||||
.DS_Store
|
||||
/build
|
||||
/captures
|
||||
.externalNativeBuild
|
||||
.cxx
|
||||
local.properties
|
||||
3
.idea/.gitignore
generated
vendored
Normal file
@ -0,0 +1,3 @@
|
||||
# Default ignored files
|
||||
/shelf/
|
||||
/workspace.xml
|
||||
1
.idea/.name
generated
Normal file
@ -0,0 +1 @@
|
||||
Minesweeper Go
|
||||
6
.idea/AndroidProjectSystem.xml
generated
Normal file
@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="AndroidProjectSystem">
|
||||
<option name="providerId" value="com.android.tools.idea.GradleProjectSystem" />
|
||||
</component>
|
||||
</project>
|
||||
6
.idea/compiler.xml
generated
Normal file
@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="CompilerConfiguration">
|
||||
<bytecodeTargetLevel target="21" />
|
||||
</component>
|
||||
</project>
|
||||
10
.idea/deploymentTargetSelector.xml
generated
Normal file
@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="deploymentTargetSelector">
|
||||
<selectionStates>
|
||||
<SelectionState runConfigName="app">
|
||||
<option name="selectionMode" value="DROPDOWN" />
|
||||
</SelectionState>
|
||||
</selectionStates>
|
||||
</component>
|
||||
</project>
|
||||
19
.idea/gradle.xml
generated
Normal file
@ -0,0 +1,19 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="GradleMigrationSettings" migrationVersion="1" />
|
||||
<component name="GradleSettings">
|
||||
<option name="linkedExternalProjectsSettings">
|
||||
<GradleProjectSettings>
|
||||
<option name="testRunner" value="CHOOSE_PER_TEST" />
|
||||
<option name="externalProjectPath" value="$PROJECT_DIR$" />
|
||||
<option name="gradleJvm" value="#GRADLE_LOCAL_JAVA_HOME" />
|
||||
<option name="modules">
|
||||
<set>
|
||||
<option value="$PROJECT_DIR$" />
|
||||
<option value="$PROJECT_DIR$/app" />
|
||||
</set>
|
||||
</option>
|
||||
</GradleProjectSettings>
|
||||
</option>
|
||||
</component>
|
||||
</project>
|
||||
61
.idea/inspectionProfiles/Project_Default.xml
generated
Normal file
@ -0,0 +1,61 @@
|
||||
<component name="InspectionProjectProfileManager">
|
||||
<profile version="1.0">
|
||||
<option name="myName" value="Project Default" />
|
||||
<inspection_tool class="ComposePreviewDimensionRespectsLimit" enabled="true" level="WARNING" enabled_by_default="true">
|
||||
<option name="composableFile" value="true" />
|
||||
<option name="previewFile" value="true" />
|
||||
</inspection_tool>
|
||||
<inspection_tool class="ComposePreviewMustBeTopLevelFunction" enabled="true" level="ERROR" enabled_by_default="true">
|
||||
<option name="composableFile" value="true" />
|
||||
<option name="previewFile" value="true" />
|
||||
</inspection_tool>
|
||||
<inspection_tool class="ComposePreviewNeedsComposableAnnotation" enabled="true" level="ERROR" enabled_by_default="true">
|
||||
<option name="composableFile" value="true" />
|
||||
<option name="previewFile" value="true" />
|
||||
</inspection_tool>
|
||||
<inspection_tool class="ComposePreviewNotSupportedInUnitTestFiles" enabled="true" level="ERROR" enabled_by_default="true">
|
||||
<option name="composableFile" value="true" />
|
||||
<option name="previewFile" value="true" />
|
||||
</inspection_tool>
|
||||
<inspection_tool class="GlancePreviewDimensionRespectsLimit" enabled="true" level="WARNING" enabled_by_default="true">
|
||||
<option name="composableFile" value="true" />
|
||||
</inspection_tool>
|
||||
<inspection_tool class="GlancePreviewMustBeTopLevelFunction" enabled="true" level="ERROR" enabled_by_default="true">
|
||||
<option name="composableFile" value="true" />
|
||||
</inspection_tool>
|
||||
<inspection_tool class="GlancePreviewNeedsComposableAnnotation" enabled="true" level="ERROR" enabled_by_default="true">
|
||||
<option name="composableFile" value="true" />
|
||||
</inspection_tool>
|
||||
<inspection_tool class="GlancePreviewNotSupportedInUnitTestFiles" enabled="true" level="ERROR" enabled_by_default="true">
|
||||
<option name="composableFile" value="true" />
|
||||
</inspection_tool>
|
||||
<inspection_tool class="PreviewAnnotationInFunctionWithParameters" enabled="true" level="ERROR" enabled_by_default="true">
|
||||
<option name="composableFile" value="true" />
|
||||
<option name="previewFile" value="true" />
|
||||
</inspection_tool>
|
||||
<inspection_tool class="PreviewApiLevelMustBeValid" enabled="true" level="ERROR" enabled_by_default="true">
|
||||
<option name="composableFile" value="true" />
|
||||
<option name="previewFile" value="true" />
|
||||
</inspection_tool>
|
||||
<inspection_tool class="PreviewDeviceShouldUseNewSpec" enabled="true" level="WEAK WARNING" enabled_by_default="true">
|
||||
<option name="composableFile" value="true" />
|
||||
<option name="previewFile" value="true" />
|
||||
</inspection_tool>
|
||||
<inspection_tool class="PreviewFontScaleMustBeGreaterThanZero" enabled="true" level="ERROR" enabled_by_default="true">
|
||||
<option name="composableFile" value="true" />
|
||||
<option name="previewFile" value="true" />
|
||||
</inspection_tool>
|
||||
<inspection_tool class="PreviewMultipleParameterProviders" enabled="true" level="ERROR" enabled_by_default="true">
|
||||
<option name="composableFile" value="true" />
|
||||
<option name="previewFile" value="true" />
|
||||
</inspection_tool>
|
||||
<inspection_tool class="PreviewParameterProviderOnFirstParameter" enabled="true" level="ERROR" enabled_by_default="true">
|
||||
<option name="composableFile" value="true" />
|
||||
<option name="previewFile" value="true" />
|
||||
</inspection_tool>
|
||||
<inspection_tool class="PreviewPickerAnnotation" enabled="true" level="ERROR" enabled_by_default="true">
|
||||
<option name="composableFile" value="true" />
|
||||
<option name="previewFile" value="true" />
|
||||
</inspection_tool>
|
||||
</profile>
|
||||
</component>
|
||||
6
.idea/kotlinc.xml
generated
Normal file
@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="KotlinJpsPluginSettings">
|
||||
<option name="version" value="1.9.0" />
|
||||
</component>
|
||||
</project>
|
||||
10
.idea/migrations.xml
generated
Normal file
@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="ProjectMigrations">
|
||||
<option name="MigrateToGradleLocalJavaHome">
|
||||
<set>
|
||||
<option value="$PROJECT_DIR$" />
|
||||
</set>
|
||||
</option>
|
||||
</component>
|
||||
</project>
|
||||
14
.idea/misc.xml
generated
Normal file
@ -0,0 +1,14 @@
|
||||
<project version="4">
|
||||
<component name="CMakeSettings">
|
||||
<configurations>
|
||||
<configuration PROFILE_NAME="Debug" CONFIG_NAME="Debug" />
|
||||
</configurations>
|
||||
</component>
|
||||
<component name="ExternalStorageConfigurationManager" enabled="true" />
|
||||
<component name="ProjectRootManager" version="2" languageLevel="JDK_21" default="true" project-jdk-name="jbr-21" project-jdk-type="JavaSDK">
|
||||
<output url="file://$PROJECT_DIR$/build/classes" />
|
||||
</component>
|
||||
<component name="ProjectType">
|
||||
<option name="id" value="Android" />
|
||||
</component>
|
||||
</project>
|
||||
17
.idea/runConfigurations.xml
generated
Normal file
@ -0,0 +1,17 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="RunConfigurationProducerService">
|
||||
<option name="ignoredProducers">
|
||||
<set>
|
||||
<option value="com.intellij.execution.junit.AbstractAllInDirectoryConfigurationProducer" />
|
||||
<option value="com.intellij.execution.junit.AllInPackageConfigurationProducer" />
|
||||
<option value="com.intellij.execution.junit.PatternConfigurationProducer" />
|
||||
<option value="com.intellij.execution.junit.TestInClassConfigurationProducer" />
|
||||
<option value="com.intellij.execution.junit.UniqueIdConfigurationProducer" />
|
||||
<option value="com.intellij.execution.junit.testDiscovery.JUnitTestDiscoveryConfigurationProducer" />
|
||||
<option value="org.jetbrains.kotlin.idea.junit.KotlinJUnitRunConfigurationProducer" />
|
||||
<option value="org.jetbrains.kotlin.idea.junit.KotlinPatternConfigurationProducer" />
|
||||
</set>
|
||||
</option>
|
||||
</component>
|
||||
</project>
|
||||
1
app/.gitignore
vendored
Normal file
@ -0,0 +1 @@
|
||||
/build
|
||||
124
app/build.gradle.kts
Normal file
@ -0,0 +1,124 @@
|
||||
import groovy.xml.XmlParser
|
||||
import java.text.SimpleDateFormat
|
||||
import java.util.Date
|
||||
|
||||
|
||||
plugins {
|
||||
alias(libs.plugins.android.application)
|
||||
alias(libs.plugins.jetbrains.kotlin.android)
|
||||
id("com.google.gms.google-services")
|
||||
id("com.google.firebase.crashlytics")
|
||||
}
|
||||
// 生成时间戳(格式 MMddHHmm)
|
||||
val timestamp: String = SimpleDateFormat("MMddHHmm").format(Date())
|
||||
|
||||
fun getAppNameFromStringsFile(): String {
|
||||
val stringsFile = file("src/main/res/values/strings.xml")
|
||||
if (!stringsFile.exists()) {
|
||||
return "UnknownApp"
|
||||
}
|
||||
|
||||
val xmlParser = XmlParser()
|
||||
val rootNode = xmlParser.parse(stringsFile)
|
||||
|
||||
return rootNode.children()
|
||||
.filterIsInstance<groovy.util.Node>()
|
||||
.find { it.attribute("name") == "app_name" }
|
||||
?.text() ?: "UnknownApp"
|
||||
}
|
||||
android {
|
||||
namespace = "com.gogame.minesweeper"
|
||||
compileSdk = 36
|
||||
|
||||
defaultConfig {
|
||||
applicationId = "com.gogame.minesweeper"
|
||||
minSdk = 24
|
||||
targetSdk = 36
|
||||
versionCode = 3
|
||||
versionName = "1.0.3"
|
||||
|
||||
testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner"
|
||||
|
||||
setProperty("archivesBaseName", "${getAppNameFromStringsFile()}-$versionName($versionCode)-${timestamp}")
|
||||
}
|
||||
|
||||
buildTypes {
|
||||
release {
|
||||
isMinifyEnabled = true
|
||||
proguardFiles(
|
||||
getDefaultProguardFile("proguard-android-optimize.txt"),
|
||||
"proguard-rules.pro"
|
||||
)
|
||||
}
|
||||
}
|
||||
compileOptions {
|
||||
sourceCompatibility = JavaVersion.VERSION_11
|
||||
targetCompatibility = JavaVersion.VERSION_11
|
||||
}
|
||||
kotlinOptions {
|
||||
jvmTarget = "11"
|
||||
}
|
||||
buildFeatures {
|
||||
viewBinding = true
|
||||
}
|
||||
}
|
||||
|
||||
dependencies {
|
||||
implementation(files("libs/UpLoadLibrary_12_03_15_13-release.aar"))
|
||||
implementation(libs.androidx.core.ktx)
|
||||
implementation(libs.androidx.appcompat)
|
||||
implementation(libs.material)
|
||||
implementation(libs.androidx.constraintlayout)
|
||||
implementation(libs.androidx.navigation.fragment.ktx)
|
||||
implementation(libs.androidx.navigation.ui.ktx)
|
||||
testImplementation(libs.junit)
|
||||
androidTestImplementation(libs.androidx.junit)
|
||||
androidTestImplementation(libs.androidx.espresso.core)
|
||||
implementation(libs.gson)
|
||||
implementation("androidx.lifecycle:lifecycle-runtime-ktx:2.6.2")
|
||||
// Import the Firebase BoM
|
||||
implementation(platform("com.google.firebase:firebase-bom:34.6.0"))
|
||||
implementation("com.google.firebase:firebase-crashlytics-ndk")
|
||||
implementation("com.google.firebase:firebase-analytics")
|
||||
// google ads
|
||||
implementation ("com.google.android.gms:play-services-ads-identifier:18.0.1")
|
||||
// okhttp
|
||||
implementation ("com.squareup.okhttp3:okhttp:4.12.0")
|
||||
implementation("com.squareup.okhttp3:logging-interceptor:4.12.0")
|
||||
|
||||
//TU (Necessary)
|
||||
api("com.thinkup.sdk:core-tpn:6.5.16")
|
||||
api("com.thinkup.sdk:nativead-tpn:6.5.16")
|
||||
api("com.thinkup.sdk:banner-tpn:6.5.16")
|
||||
api("com.thinkup.sdk:interstitial-tpn:6.5.16")
|
||||
api("com.thinkup.sdk:rewardedvideo-tpn:6.5.16")
|
||||
api("com.thinkup.sdk:splash-tpn:6.5.16")
|
||||
//Androidx (Necessary)
|
||||
api("androidx.appcompat:appcompat:1.6.1")
|
||||
api("androidx.browser:browser:1.4.0")
|
||||
//Vungle
|
||||
api("com.thinkup.sdk:adapter-tpn-vungle:6.5.16")
|
||||
api("com.vungle:vungle-ads:7.5.0")
|
||||
api("com.google.android.gms:play-services-basement:18.1.0")
|
||||
api("com.google.android.gms:play-services-ads-identifier:18.0.1")
|
||||
//UnityAds
|
||||
api("com.thinkup.sdk:adapter-tpn-unityads:6.5.16")
|
||||
api("com.unity3d.ads:unity-ads:4.14.0")
|
||||
//Ironsource
|
||||
api("com.thinkup.sdk:adapter-tpn-ironsource:6.5.16")
|
||||
api("com.ironsource.sdk:mediationsdk:8.7.0")
|
||||
api("com.google.android.gms:play-services-appset:16.0.2")
|
||||
api("com.google.android.gms:play-services-ads-identifier:18.0.1")
|
||||
api("com.google.android.gms:play-services-basement:18.1.0")
|
||||
//Bigo
|
||||
api("com.thinkup.sdk:adapter-tpn-bigo:6.5.16.1")
|
||||
api("com.bigossp:bigo-ads:5.5.1")
|
||||
//Mintegral
|
||||
api("com.thinkup.sdk:adapter-tpn-mintegral:6.5.16.1")
|
||||
api("com.mbridge.msdk.oversea:mbridge_android_sdk:16.9.91")
|
||||
api("androidx.recyclerview:recyclerview:1.1.0")
|
||||
//Pangle
|
||||
api("com.thinkup.sdk:adapter-tpn-pangle:6.5.16.2")
|
||||
api("com.pangle.global:pag-sdk:7.6.0.2")
|
||||
api("com.google.android.gms:play-services-ads-identifier:18.0.1")
|
||||
}
|
||||
29
app/google-services.json
Normal file
@ -0,0 +1,29 @@
|
||||
{
|
||||
"project_info": {
|
||||
"project_number": "500252155158",
|
||||
"project_id": "minesweeper-go-1e611",
|
||||
"storage_bucket": "minesweeper-go-1e611.firebasestorage.app"
|
||||
},
|
||||
"client": [
|
||||
{
|
||||
"client_info": {
|
||||
"mobilesdk_app_id": "1:500252155158:android:9296fdaa061e12de05c437",
|
||||
"android_client_info": {
|
||||
"package_name": "com.gogame.minesweeper"
|
||||
}
|
||||
},
|
||||
"oauth_client": [],
|
||||
"api_key": [
|
||||
{
|
||||
"current_key": "AIzaSyDdKXNF1RXKY_9WbrQYKZbWFs4tMr8ajKI"
|
||||
}
|
||||
],
|
||||
"services": {
|
||||
"appinvite_service": {
|
||||
"other_platform_oauth_client": []
|
||||
}
|
||||
}
|
||||
}
|
||||
],
|
||||
"configuration_version": "1"
|
||||
}
|
||||
BIN
app/libs/UpLoadLibrary_12_03_15_13-release.aar
Normal file
93
app/proguard-rules.pro
vendored
Normal file
@ -0,0 +1,93 @@
|
||||
#start topon 聚合混淆
|
||||
# Vungle
|
||||
-dontwarn com.vungle.ads.**
|
||||
-keepclassmembers class com.vungle.ads.** {
|
||||
*;
|
||||
}
|
||||
-keep class com.vungle.ads.**
|
||||
|
||||
|
||||
|
||||
# Google
|
||||
-keep class com.google.android.gms.** { *; }
|
||||
-dontwarn com.google.android.gms.**
|
||||
|
||||
|
||||
|
||||
|
||||
# START OkHttp + Okio
|
||||
# JSR 305 annotations are for embedding nullability information.
|
||||
-dontwarn javax.annotation.**
|
||||
|
||||
|
||||
# A resource is loaded with a relative path so the package of this class must be preserved.
|
||||
-adaptresourcefilenames okhttp3/internal/publicsuffix/PublicSuffixDatabase.gz
|
||||
|
||||
|
||||
# Animal Sniffer compileOnly dependency to ensure APIs are compatible with older versions of Java.
|
||||
-dontwarn org.codehaus.mojo.animal_sniffer.*
|
||||
|
||||
|
||||
# OkHttp platform used only on JVM and when Conscrypt and other security providers are available.
|
||||
-dontwarn okhttp3.internal.platform.**
|
||||
-dontwarn org.conscrypt.**
|
||||
-dontwarn org.bouncycastle.**
|
||||
-dontwarn org.openjsse.**
|
||||
|
||||
|
||||
# Animal Sniffer compileOnly dependency to ensure APIs are compatible with older versions of Java.
|
||||
-dontwarn org.codehaus.mojo.animal_sniffer.*
|
||||
|
||||
|
||||
# END OkHttp + Okio
|
||||
|
||||
|
||||
# START Protobuf
|
||||
-dontwarn com.google.protobuf.**
|
||||
-keepclassmembers class com.google.protobuf.** {
|
||||
*;
|
||||
}
|
||||
-keep class * extends com.google.protobuf.GeneratedMessageLite { *; }
|
||||
|
||||
|
||||
# END Protobuf
|
||||
-keepclassmembers class com.ironsource.sdk.controller.IronSourceWebView$JSInterface {
|
||||
public *;
|
||||
}
|
||||
-keepclassmembers class * implements android.os.Parcelable {
|
||||
public static final android.os.Parcelable$Creator *;
|
||||
}
|
||||
-keep public class com.google.android.gms.ads.** {
|
||||
public *;
|
||||
}
|
||||
-keep class com.ironsource.adapters.** { *;
|
||||
}
|
||||
-dontwarn com.ironsource.mediationsdk.**
|
||||
-dontwarn com.ironsource.adapters.**
|
||||
-keepattributes JavascriptInterface
|
||||
-keepclassmembers class * {
|
||||
@android.webkit.JavascriptInterface <methods>;
|
||||
}
|
||||
-keepattributes Signature
|
||||
-keepattributes *Annotation*
|
||||
-keep class com.mbridge.** {*; }
|
||||
-keep interface com.mbridge.** {*; }
|
||||
-dontwarn com.mbridge.**
|
||||
-keepclassmembers class **.R$* { public static final int mbridge*; }
|
||||
|
||||
-keep public class com.mbridge.* extends androidx.** { *; }
|
||||
-keep public class androidx.viewpager.widget.PagerAdapter{*;}
|
||||
-keep public class androidx.viewpager.widget.ViewPager.OnPageChangeListener{*;}
|
||||
-keep interface androidx.annotation.IntDef{*;}
|
||||
-keep interface androidx.annotation.Nullable{*;}
|
||||
-keep interface androidx.annotation.CheckResult{*;}
|
||||
-keep interface androidx.annotation.NonNull{*;}
|
||||
-keep public class androidx.fragment.app.Fragment{*;}
|
||||
-keep public class androidx.core.content.FileProvider{*;}
|
||||
-keep public class androidx.core.app.NotificationCompat{*;}
|
||||
-keep public class androidx.appcompat.widget.AppCompatImageView {*;}
|
||||
-keep public class androidx.recyclerview.*{*;}
|
||||
-keep class com.mbridge.msdk.foundation.tools.FastKV{*;}
|
||||
-keep class com.mbridge.msdk.foundation.tools.FastKV$Builder{*;}
|
||||
-keep class com.bytedance.sdk.** { *; }
|
||||
#end topon 聚合混淆
|
||||
BIN
app/release/Minesweeper Go-1.0.3(3)-12041449-release.apk
Normal file
BIN
app/release/Minesweeper Go-1.0.3(3)-12041501-release.aab
Normal file
37
app/release/output-metadata.json
Normal file
@ -0,0 +1,37 @@
|
||||
{
|
||||
"version": 3,
|
||||
"artifactType": {
|
||||
"type": "APK",
|
||||
"kind": "Directory"
|
||||
},
|
||||
"applicationId": "com.gogame.minesweeper",
|
||||
"variantName": "release",
|
||||
"elements": [
|
||||
{
|
||||
"type": "SINGLE",
|
||||
"filters": [],
|
||||
"attributes": [],
|
||||
"versionCode": 3,
|
||||
"versionName": "1.0.3",
|
||||
"outputFile": "Minesweeper Go-1.0.3(3)-12041449-release.apk"
|
||||
}
|
||||
],
|
||||
"elementType": "File",
|
||||
"baselineProfiles": [
|
||||
{
|
||||
"minApi": 28,
|
||||
"maxApi": 30,
|
||||
"baselineProfiles": [
|
||||
"baselineProfiles/1/Minesweeper Go-1.0.3(3)-12041449-release.dm"
|
||||
]
|
||||
},
|
||||
{
|
||||
"minApi": 31,
|
||||
"maxApi": 2147483647,
|
||||
"baselineProfiles": [
|
||||
"baselineProfiles/0/Minesweeper Go-1.0.3(3)-12041449-release.dm"
|
||||
]
|
||||
}
|
||||
],
|
||||
"minSdkVersionForDexing": 24
|
||||
}
|
||||
@ -0,0 +1,24 @@
|
||||
package com.gogame.minesweeper
|
||||
|
||||
import androidx.test.platform.app.InstrumentationRegistry
|
||||
import androidx.test.ext.junit.runners.AndroidJUnit4
|
||||
|
||||
import org.junit.Test
|
||||
import org.junit.runner.RunWith
|
||||
|
||||
import org.junit.Assert.*
|
||||
|
||||
/**
|
||||
* Instrumented test, which will execute on an Android device.
|
||||
*
|
||||
* See [testing documentation](http://d.android.com/tools/testing).
|
||||
*/
|
||||
@RunWith(AndroidJUnit4::class)
|
||||
class ExampleInstrumentedTest {
|
||||
@Test
|
||||
fun useAppContext() {
|
||||
// Context of the app under test.
|
||||
val appContext = InstrumentationRegistry.getInstrumentation().targetContext
|
||||
assertEquals("com.gogame.minesweeper", appContext.packageName)
|
||||
}
|
||||
}
|
||||
45
app/src/main/AndroidManifest.xml
Normal file
@ -0,0 +1,45 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools">
|
||||
|
||||
<uses-permission android:name="android.permission.INTERNET" />
|
||||
<uses-permission android:name="android.permission.ACCESS_WIFI_STATE" />
|
||||
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
|
||||
|
||||
<application
|
||||
android:name=".App"
|
||||
android:allowBackup="true"
|
||||
android:dataExtractionRules="@xml/data_extraction_rules"
|
||||
android:fullBackupContent="@xml/backup_rules"
|
||||
android:icon="@mipmap/app_logo"
|
||||
android:label="@string/app_name"
|
||||
android:roundIcon="@mipmap/app_logo_round"
|
||||
android:supportsRtl="true"
|
||||
android:theme="@style/Theme.MinesweeperGo"
|
||||
tools:targetApi="31">
|
||||
<activity
|
||||
android:name=".SplashActivity"
|
||||
android:exported="true"
|
||||
android:theme="@style/Theme.MinesweeperGo">
|
||||
<intent-filter>
|
||||
<action android:name="android.intent.action.MAIN" />
|
||||
|
||||
<category android:name="android.intent.category.LAUNCHER" />
|
||||
</intent-filter>
|
||||
</activity>
|
||||
|
||||
<uses-library
|
||||
android:name="org.apache.http.legacy"
|
||||
android:required="false" />
|
||||
|
||||
<activity
|
||||
android:name=".MainActivity"
|
||||
android:screenOrientation="portrait"
|
||||
tools:ignore="DiscouragedApi,LockedOrientationActivity" />
|
||||
<activity
|
||||
android:name=".swipe.SwipeActivity"
|
||||
android:screenOrientation="portrait"
|
||||
tools:ignore="DiscouragedApi,LockedOrientationActivity" />
|
||||
</application>
|
||||
|
||||
</manifest>
|
||||
BIN
app/src/main/app_logo-playstore.png
Normal file
|
After Width: | Height: | Size: 20 KiB |
28
app/src/main/java/com/gogame/minesweeper/App.kt
Normal file
@ -0,0 +1,28 @@
|
||||
package com.gogame.minesweeper
|
||||
|
||||
import android.app.Application
|
||||
import android.content.Context
|
||||
import com.thinkup.core.api.TUSDK
|
||||
import com.up.uploadlibrary.UpLoadManager
|
||||
|
||||
class App : Application() {
|
||||
|
||||
companion object {
|
||||
private lateinit var instance: App
|
||||
|
||||
fun getInstance(): App = instance
|
||||
|
||||
fun getContext(): Context = instance.applicationContext
|
||||
}
|
||||
|
||||
override fun onCreate() {
|
||||
super.onCreate()
|
||||
// 上传
|
||||
UpLoadManager.init(context = this, tag = "PRApp_minesweeper_task") { _, _ -> }
|
||||
initAd()
|
||||
}
|
||||
|
||||
private fun initAd() {
|
||||
TUSDK.init(this,"h692ffae5586bf","a764e3497a06ccd54a03aef53f022ef74")
|
||||
}
|
||||
}
|
||||
36
app/src/main/java/com/gogame/minesweeper/BaseActivity.kt
Normal file
@ -0,0 +1,36 @@
|
||||
package com.gogame.minesweeper
|
||||
|
||||
import android.os.Bundle
|
||||
import androidx.activity.OnBackPressedCallback
|
||||
import androidx.appcompat.app.AppCompatActivity
|
||||
|
||||
open class BaseActivity: AppCompatActivity() {
|
||||
protected var backPressedCallback: OnBackPressedCallback? = null
|
||||
/** 子类是否需要拦截返回 */
|
||||
protected open fun shouldInterceptBackPress(): Boolean = false
|
||||
|
||||
/** 子类定义拦截后的操作(例如弹窗) */
|
||||
protected open fun onInterceptBackPressed() {}
|
||||
|
||||
override fun onCreate(savedInstanceState: Bundle?) {
|
||||
super.onCreate(savedInstanceState)
|
||||
setupBackPressedCallback()//初始化back事件
|
||||
}
|
||||
private fun setupBackPressedCallback() {
|
||||
backPressedCallback = object : OnBackPressedCallback(true) {
|
||||
override fun handleOnBackPressed() {
|
||||
if (shouldInterceptBackPress()) {
|
||||
// 由子类处理拦截动作
|
||||
onInterceptBackPressed()
|
||||
} else {
|
||||
// 不拦截:关闭自己
|
||||
isEnabled = false
|
||||
onBackPressedDispatcher.onBackPressed()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
onBackPressedDispatcher.addCallback(this, backPressedCallback!!)
|
||||
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,8 @@
|
||||
package com.gogame.minesweeper
|
||||
|
||||
enum class DifficultyLevel(val xLength: Int, val yLength: Int, val mineNum: Int) {
|
||||
BEGINNER(9, 9, 10), // 新手难度
|
||||
INTERMEDIATE(16, 16, 40), // 中等难度
|
||||
EXPERT(24, 24, 99), // 专家难度
|
||||
MASTER(50, 50, 450) // 大师难度
|
||||
}
|
||||
114
app/src/main/java/com/gogame/minesweeper/MainActivity.kt
Normal file
@ -0,0 +1,114 @@
|
||||
package com.gogame.minesweeper
|
||||
|
||||
import android.content.Context
|
||||
import android.content.Intent
|
||||
import android.os.Bundle
|
||||
import android.view.View
|
||||
import androidx.core.view.ViewCompat
|
||||
import androidx.core.view.WindowCompat
|
||||
import androidx.core.view.WindowInsetsCompat
|
||||
import com.gogame.minesweeper.bean.GameState
|
||||
import com.gogame.minesweeper.databinding.ActivityMainBinding
|
||||
import com.gogame.minesweeper.swipe.SwipeActivity
|
||||
import com.google.gson.Gson
|
||||
|
||||
class MainActivity : BaseActivity() {
|
||||
|
||||
private lateinit var binding: ActivityMainBinding
|
||||
|
||||
private lateinit var difficultyLevels: Array<DifficultyLevel>
|
||||
private var currentDifficultyIndex = 0
|
||||
|
||||
override fun onCreate(savedInstanceState: Bundle?) {
|
||||
super.onCreate(savedInstanceState)
|
||||
binding = ActivityMainBinding.inflate(layoutInflater)
|
||||
setContentView(binding.root)
|
||||
immersionBar()
|
||||
initView()
|
||||
}
|
||||
|
||||
private fun immersionBar() {
|
||||
//自适应沉浸式
|
||||
ViewCompat.setOnApplyWindowInsetsListener(findViewById(R.id.main)) { v, insets ->
|
||||
val systemBars = insets.getInsets(WindowInsetsCompat.Type.systemBars())
|
||||
v.setPadding(systemBars.left, systemBars.top, systemBars.right, systemBars.bottom)
|
||||
insets
|
||||
}
|
||||
|
||||
val windowInsetsController = WindowCompat.getInsetsController(window, window.decorView)
|
||||
windowInsetsController.isAppearanceLightStatusBars = true//状态栏文字颜色
|
||||
}
|
||||
|
||||
private fun initView() {
|
||||
// 设置难度级别
|
||||
difficultyLevels = DifficultyLevel.entries.toTypedArray() // 获取所有的难度级别
|
||||
|
||||
// 显示初始难度
|
||||
binding.tvDifficulty.text = difficultyLevels[currentDifficultyIndex].name
|
||||
|
||||
binding.btnPrevious.setOnClickListener {
|
||||
if (currentDifficultyIndex > 0) {
|
||||
currentDifficultyIndex--
|
||||
binding.tvDifficulty.text = difficultyLevels[currentDifficultyIndex].name
|
||||
}
|
||||
updateContinueState()
|
||||
}
|
||||
|
||||
binding.btnNext.setOnClickListener {
|
||||
if (currentDifficultyIndex < difficultyLevels.size - 1) {
|
||||
currentDifficultyIndex++
|
||||
binding.tvDifficulty.text = difficultyLevels[currentDifficultyIndex].name
|
||||
}
|
||||
updateContinueState()
|
||||
}
|
||||
|
||||
binding.newGameBtn.setOnClickListener {
|
||||
startGameWithDifficulty()
|
||||
}
|
||||
binding.continueBtn.setOnClickListener {
|
||||
continuePreviousGame()
|
||||
}
|
||||
}
|
||||
|
||||
override fun onResume() {
|
||||
super.onResume()
|
||||
updateContinueState()
|
||||
}
|
||||
|
||||
private fun startGameWithDifficulty() {
|
||||
val intent = Intent(this, SwipeActivity::class.java)
|
||||
// 传递当前难度给 SwipeActivity
|
||||
intent.putExtra(
|
||||
"difficulty",
|
||||
difficultyLevels[currentDifficultyIndex]
|
||||
) // 直接传递 DifficultyLevel
|
||||
intent.putExtra("isNewGame", true)
|
||||
startActivity(intent)
|
||||
}
|
||||
|
||||
private fun continuePreviousGame() {
|
||||
val intent = Intent(this, SwipeActivity::class.java)
|
||||
// 传递当前难度给 SwipeActivity
|
||||
intent.putExtra(
|
||||
"difficulty",
|
||||
difficultyLevels[currentDifficultyIndex]
|
||||
) // 直接传递 DifficultyLevel
|
||||
intent.putExtra("isNewGame", false)
|
||||
startActivity(intent)
|
||||
}
|
||||
|
||||
private fun updateContinueState() {
|
||||
val sharedPreferences = getSharedPreferences("minesweeper_prefs", Context.MODE_PRIVATE)
|
||||
val gameStateJson = sharedPreferences.getString("game_state", null)
|
||||
if (gameStateJson.isNullOrEmpty()) {
|
||||
binding.continueBtn.visibility = View.GONE
|
||||
return
|
||||
}
|
||||
val gameState: GameState = Gson().fromJson(gameStateJson, GameState::class.java)
|
||||
if (gameState.difficulty == difficultyLevels[currentDifficultyIndex]) {
|
||||
binding.continueBtn.visibility = View.VISIBLE
|
||||
} else {
|
||||
binding.continueBtn.visibility = View.GONE
|
||||
}
|
||||
}
|
||||
}
|
||||
107
app/src/main/java/com/gogame/minesweeper/SplashActivity.kt
Normal file
@ -0,0 +1,107 @@
|
||||
package com.gogame.minesweeper
|
||||
|
||||
import android.content.Intent
|
||||
import android.os.Bundle
|
||||
import android.os.Handler
|
||||
import android.os.Looper
|
||||
import androidx.activity.enableEdgeToEdge
|
||||
import androidx.core.view.ViewCompat
|
||||
import androidx.core.view.WindowCompat
|
||||
import androidx.core.view.WindowInsetsCompat
|
||||
import com.gogame.minesweeper.ad.AdShowFailed
|
||||
import com.gogame.minesweeper.ad.AdsInsUtil
|
||||
import com.gogame.minesweeper.ad.LoadListener
|
||||
import com.gogame.minesweeper.ad.ShowListener
|
||||
import com.gogame.minesweeper.databinding.ActivitySplashBinding
|
||||
import com.thinkup.core.api.TUAdInfo
|
||||
import kotlin.random.Random
|
||||
|
||||
class SplashActivity : BaseActivity() {
|
||||
|
||||
companion object {
|
||||
private const val AD_TIMEOUT = 15000L // 广告加载超时时间 15 秒
|
||||
}
|
||||
|
||||
private lateinit var binding: ActivitySplashBinding
|
||||
override fun onCreate(savedInstanceState: Bundle?) {
|
||||
super.onCreate(savedInstanceState)
|
||||
binding = ActivitySplashBinding.inflate(layoutInflater)
|
||||
enableEdgeToEdge()
|
||||
setContentView(binding.root)
|
||||
ViewCompat.setOnApplyWindowInsetsListener(findViewById(R.id.main)) { v, insets ->
|
||||
val systemBars = insets.getInsets(WindowInsetsCompat.Type.systemBars())
|
||||
v.setPadding(systemBars.left, systemBars.top, systemBars.right, systemBars.bottom)
|
||||
insets
|
||||
}
|
||||
val windowInsetsController = WindowCompat.getInsetsController(window, window.decorView)
|
||||
windowInsetsController.isAppearanceLightStatusBars = true//状态栏文字颜色
|
||||
loadSplashAd()
|
||||
}
|
||||
|
||||
|
||||
private val adHandler = Handler(Looper.getMainLooper())
|
||||
private val adTimeoutRunnable = Runnable {
|
||||
navigateToNext() // 超时直接跳转
|
||||
}
|
||||
|
||||
private fun loadSplashAd() {
|
||||
adHandler.postDelayed(adTimeoutRunnable, AD_TIMEOUT)
|
||||
|
||||
// 生成一个随机索引
|
||||
val randomIndex = Random.nextInt(AdsInsUtil.Placement.adPlaceAllList.size)
|
||||
// 获取随机的广告位
|
||||
val randomAdPlace = AdsInsUtil.Placement.adPlaceAllList[randomIndex]
|
||||
AdsInsUtil.loadAd(
|
||||
act = this,
|
||||
adID =randomAdPlace,
|
||||
loadListener = object : LoadListener {
|
||||
override fun loaded(ad: TUAdInfo) {
|
||||
adHandler.removeCallbacks(adTimeoutRunnable)
|
||||
showSplashAd(randomAdPlace)
|
||||
}
|
||||
|
||||
override fun loadFailed(error: String) {
|
||||
adHandler.removeCallbacks(adTimeoutRunnable)
|
||||
navigateToNext() // 加载失败直接跳转
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
private fun showSplashAd(randomAdPlace: String) {
|
||||
AdsInsUtil.showAd(
|
||||
act = this,
|
||||
adID = randomAdPlace,
|
||||
listener = object : ShowListener {
|
||||
override fun onAdShown(ad: TUAdInfo?) {
|
||||
}
|
||||
|
||||
override fun onAdShowFailed(error: AdShowFailed?) {
|
||||
navigateToNext() // 展示失败也直接跳转
|
||||
}
|
||||
|
||||
override fun onAdClosed() {
|
||||
navigateToNext() // 广告关闭后跳转
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
private var hasNavigated = false
|
||||
|
||||
//保证只跳转一次
|
||||
private fun navigateToNext() {
|
||||
if (hasNavigated) return
|
||||
hasNavigated = true
|
||||
startActivity(Intent(this, MainActivity::class.java))
|
||||
finish()
|
||||
}
|
||||
|
||||
override fun shouldInterceptBackPress(): Boolean = true
|
||||
override fun onInterceptBackPressed() {
|
||||
|
||||
}
|
||||
|
||||
override fun onDestroy() {
|
||||
super.onDestroy()
|
||||
adHandler.removeCallbacks(adTimeoutRunnable)
|
||||
}
|
||||
}
|
||||
68
app/src/main/java/com/gogame/minesweeper/ad/AdInstLoad.kt
Normal file
@ -0,0 +1,68 @@
|
||||
package com.gogame.minesweeper.ad
|
||||
|
||||
import android.app.Activity
|
||||
import android.util.Log
|
||||
import com.thinkup.core.api.AdError
|
||||
import com.thinkup.core.api.TUAdInfo
|
||||
import com.thinkup.interstitial.api.TUInterstitial
|
||||
import com.thinkup.interstitial.api.TUInterstitialListener
|
||||
|
||||
class AdInstLoad {
|
||||
private var mPlace: String
|
||||
private var adLoadListener: LoadListener? = null
|
||||
private var activity: Activity? = null
|
||||
|
||||
constructor(activity: Activity, place: String, listener: LoadListener?) {
|
||||
this.mPlace = place
|
||||
this.adLoadListener = listener
|
||||
this.activity = activity
|
||||
init()
|
||||
}
|
||||
|
||||
constructor(place: String, listener: LoadListener?) {
|
||||
this.mPlace = place
|
||||
this.adLoadListener = listener
|
||||
init()
|
||||
}
|
||||
|
||||
private fun init() {
|
||||
val mInterstitialAd = TUInterstitial(activity,mPlace)
|
||||
mInterstitialAd.setAdListener(object : TUInterstitialListener{
|
||||
override fun onInterstitialAdLoaded() {
|
||||
Log.d("ocean", "load ad loaded")
|
||||
val info = mInterstitialAd.checkAdStatus().tuTopAdInfo
|
||||
if (info != null) {
|
||||
InstAdCacheManager.instance.setAdCache(mPlace, mInterstitialAd)
|
||||
adLoadListener?.loaded(info)
|
||||
} else {
|
||||
adLoadListener?.loadFailed("AdInfo null")
|
||||
}
|
||||
}
|
||||
|
||||
override fun onInterstitialAdLoadFail(adError: AdError?) {
|
||||
adLoadListener?.loadFailed("code:${adError?.code}")
|
||||
Log.d("ocean", "load ad onError->${adError.toString()}")
|
||||
}
|
||||
|
||||
override fun onInterstitialAdClicked(p0: TUAdInfo?) {
|
||||
}
|
||||
|
||||
override fun onInterstitialAdShow(p0: TUAdInfo?) {
|
||||
}
|
||||
|
||||
override fun onInterstitialAdClose(p0: TUAdInfo?) {
|
||||
}
|
||||
|
||||
override fun onInterstitialAdVideoStart(p0: TUAdInfo?) {
|
||||
}
|
||||
|
||||
override fun onInterstitialAdVideoEnd(p0: TUAdInfo?) {
|
||||
}
|
||||
|
||||
override fun onInterstitialAdVideoError(p0: AdError?) {
|
||||
}
|
||||
|
||||
})
|
||||
mInterstitialAd.load()
|
||||
}
|
||||
}
|
||||
71
app/src/main/java/com/gogame/minesweeper/ad/AdInstShower.kt
Normal file
@ -0,0 +1,71 @@
|
||||
package com.gogame.minesweeper.ad
|
||||
|
||||
import android.app.Activity
|
||||
import android.util.Log
|
||||
import com.thinkup.core.api.AdError
|
||||
import com.thinkup.core.api.TUAdInfo
|
||||
import com.thinkup.interstitial.api.TUInterstitialListener
|
||||
|
||||
class AdInstShower {
|
||||
private var mPlace: String
|
||||
private var showListener: ShowListener? = null
|
||||
private var activity: Activity? = null
|
||||
|
||||
constructor(activity: Activity, place: String, showListener: ShowListener?) {
|
||||
this.mPlace = place
|
||||
this.showListener = showListener
|
||||
this.activity = activity
|
||||
init()
|
||||
}
|
||||
|
||||
constructor(place: String, showListener: ShowListener?) {
|
||||
this.mPlace = place
|
||||
this.showListener = showListener
|
||||
init()
|
||||
}
|
||||
|
||||
private fun init() {
|
||||
val atInterstitial = InstAdCacheManager.instance.getAdCache(mPlace)
|
||||
atInterstitial?.setAdListener(object : TUInterstitialListener {
|
||||
override fun onInterstitialAdLoaded() {
|
||||
|
||||
}
|
||||
|
||||
override fun onInterstitialAdLoadFail(p0: AdError?) {
|
||||
|
||||
}
|
||||
|
||||
override fun onInterstitialAdClicked(p0: TUAdInfo?) {
|
||||
showListener?.onAdClicked()
|
||||
Log.d("ocean", "广告点击回调")
|
||||
}
|
||||
|
||||
override fun onInterstitialAdShow(p0: TUAdInfo?) {
|
||||
showListener?.onAdShown(p0)
|
||||
Log.d("ocean", "广告展示回调")
|
||||
}
|
||||
|
||||
override fun onInterstitialAdClose(p0: TUAdInfo?) {
|
||||
showListener?.onAdClosed()
|
||||
Log.d("ocean", "广告关闭回调")
|
||||
}
|
||||
|
||||
override fun onInterstitialAdVideoStart(p0: TUAdInfo?) {
|
||||
Log.d("ocean", "视频广告开始播放回调")
|
||||
}
|
||||
|
||||
override fun onInterstitialAdVideoEnd(p0: TUAdInfo?) {
|
||||
Log.d("ocean", "视频广告播放结束回调")
|
||||
}
|
||||
|
||||
override fun onInterstitialAdVideoError(adError: AdError?) {
|
||||
Log.d("ocean", "视频广告播放失败回调->${adError.toString()}")
|
||||
showListener?.onAdShowFailed(AdShowFailed(adError.toString()))
|
||||
}
|
||||
|
||||
})
|
||||
if (atInterstitial?.isAdReady == true) {
|
||||
atInterstitial.show(activity)
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,5 @@
|
||||
package com.gogame.minesweeper.ad
|
||||
|
||||
data class AdShowFailed(
|
||||
val msg: String = "",
|
||||
)
|
||||
34
app/src/main/java/com/gogame/minesweeper/ad/AdsInsUtil.kt
Normal file
@ -0,0 +1,34 @@
|
||||
package com.gogame.minesweeper.ad
|
||||
|
||||
import android.app.Activity
|
||||
|
||||
object AdsInsUtil {
|
||||
|
||||
object Placement {
|
||||
const val TOP_ON_AD_ONE = "n692ffb09edbb6"
|
||||
const val TOP_ON_AD_TOW = "n692ffb09bc89d"
|
||||
const val TOP_ON_AD_THREE = "n692ffb098d0d5"
|
||||
|
||||
val adPlaceAllList = listOf(
|
||||
TOP_ON_AD_ONE,
|
||||
TOP_ON_AD_TOW,
|
||||
TOP_ON_AD_THREE
|
||||
)
|
||||
}
|
||||
|
||||
fun loadAd(
|
||||
act: Activity,
|
||||
adID: String,
|
||||
loadListener: LoadListener?
|
||||
): AdInstLoad {
|
||||
return AdInstLoad(act, adID, loadListener)
|
||||
}
|
||||
|
||||
fun showAd(
|
||||
act: Activity,
|
||||
adID: String,
|
||||
listener: ShowListener?
|
||||
): AdInstShower {
|
||||
return AdInstShower(act, adID, listener)
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,36 @@
|
||||
package com.gogame.minesweeper.ad
|
||||
|
||||
import com.thinkup.interstitial.api.TUInterstitial
|
||||
|
||||
|
||||
class InstAdCacheManager {
|
||||
private val mAdCacheDict: MutableMap<String, TUInterstitial> = mutableMapOf()
|
||||
|
||||
companion object {
|
||||
val instance: InstAdCacheManager by lazy(mode = LazyThreadSafetyMode.SYNCHRONIZED) {
|
||||
InstAdCacheManager()
|
||||
}
|
||||
}
|
||||
|
||||
fun setAdCache(place: String, adCache: TUInterstitial) {
|
||||
mAdCacheDict[place] = adCache
|
||||
}
|
||||
|
||||
fun getAdCache(place: String): TUInterstitial? {
|
||||
return mAdCacheDict[place]
|
||||
}
|
||||
|
||||
fun getLoadedInstCount(): Int {
|
||||
var count = 0
|
||||
try {
|
||||
mAdCacheDict.forEach { (key, value) ->
|
||||
if (value.isAdReady) {
|
||||
count += 1
|
||||
}
|
||||
}
|
||||
} catch (_: Exception) {
|
||||
|
||||
}
|
||||
return count
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,8 @@
|
||||
package com.gogame.minesweeper.ad
|
||||
|
||||
import com.thinkup.core.api.TUAdInfo
|
||||
|
||||
interface LoadListener {
|
||||
fun loadFailed(error: String) {}
|
||||
fun loaded(ad: TUAdInfo) {}
|
||||
}
|
||||
10
app/src/main/java/com/gogame/minesweeper/ad/ShowListener.kt
Normal file
@ -0,0 +1,10 @@
|
||||
package com.gogame.minesweeper.ad
|
||||
|
||||
import com.thinkup.core.api.TUAdInfo
|
||||
|
||||
interface ShowListener {
|
||||
fun onAdShown(ad: TUAdInfo?) {}
|
||||
fun onAdShowFailed(error: AdShowFailed?) {}
|
||||
fun onAdClosed() {}
|
||||
fun onAdClicked() {}
|
||||
}
|
||||
@ -0,0 +1,7 @@
|
||||
package com.gogame.minesweeper.bean
|
||||
|
||||
data class CellState(
|
||||
var logicState: Int, // 逻辑状态
|
||||
var viewState: Int, // 视图状态
|
||||
var around: Int // 周围雷数
|
||||
)
|
||||
32
app/src/main/java/com/gogame/minesweeper/bean/GameState.kt
Normal file
@ -0,0 +1,32 @@
|
||||
package com.gogame.minesweeper.bean
|
||||
|
||||
import com.gogame.minesweeper.DifficultyLevel
|
||||
|
||||
data class GameState(
|
||||
val grid: Array<Array<CellState>>, // 游戏网格
|
||||
val remainingMines: Int, // 剩余雷数
|
||||
val difficulty: DifficultyLevel, // 难度
|
||||
val minutes : Int,
|
||||
val seconds : Int,
|
||||
) {
|
||||
override fun equals(other: Any?): Boolean {
|
||||
if (this === other) return true
|
||||
if (javaClass != other?.javaClass) return false
|
||||
|
||||
other as GameState
|
||||
|
||||
if (!grid.contentDeepEquals(other.grid)) return false
|
||||
if (remainingMines != other.remainingMines) return false
|
||||
if (difficulty != other.difficulty) return false
|
||||
|
||||
return true
|
||||
}
|
||||
|
||||
override fun hashCode(): Int {
|
||||
var result = grid.contentDeepHashCode()
|
||||
result = 31 * result + remainingMines
|
||||
result = 31 * result + difficulty.hashCode()
|
||||
return result
|
||||
}
|
||||
|
||||
}
|
||||
@ -0,0 +1,66 @@
|
||||
package com.gogame.minesweeper.swipe
|
||||
|
||||
import android.annotation.SuppressLint
|
||||
import java.util.*
|
||||
|
||||
object LogicHelper {
|
||||
fun randomMines(xlength: Int, ylength: Int, x: Int, y: Int, count: Int): ArrayList<Int> {
|
||||
val total = xlength * ylength - 1
|
||||
if (count >= total || count <= 0) {
|
||||
throw IllegalArgumentException("Invalid mine count: $count")
|
||||
}
|
||||
|
||||
val random = Random()
|
||||
val randoms = hashSetOf(getIndexByXY(xlength, ylength, x, y)) // 用HashSet防止重复
|
||||
|
||||
while (randoms.size < count + 1) {
|
||||
val next = random.nextInt(xlength * ylength)
|
||||
randoms.add(next) // HashSet 自动忽略重复的数字
|
||||
}
|
||||
|
||||
randoms.remove(getIndexByXY(xlength, ylength, x, y)) // 移除点击位置
|
||||
return ArrayList(randoms)
|
||||
}
|
||||
|
||||
|
||||
fun getIndexByXY(xlength: Int, ylength: Int, x: Int, y: Int): Int {
|
||||
return x + y * xlength
|
||||
}
|
||||
|
||||
fun getXYbyIndex(xlength:Int,ylength:Int,index:Int):IntArray{
|
||||
val x = index%ylength
|
||||
val y = index/ylength
|
||||
return intArrayOf(x,y)
|
||||
}
|
||||
|
||||
fun getAroundItems(xLength: Int, yLength: Int, index: Int): List<Int> {
|
||||
val result = mutableListOf<Int>()
|
||||
val x = index % xLength // 根据列数获取x坐标
|
||||
val y = index / xLength // 根据行数获取y坐标
|
||||
|
||||
// 检查周围的8个格子
|
||||
for (i in -1..1) {
|
||||
for (j in -1..1) {
|
||||
if (i == 0 && j == 0) continue // 跳过当前格子
|
||||
val newX = x + i
|
||||
val newY = y + j
|
||||
// 检查边界
|
||||
if (newX in 0 until xLength && newY in 0 until yLength) {
|
||||
result.add(newY * xLength + newX)
|
||||
}
|
||||
}
|
||||
}
|
||||
return result
|
||||
}
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* 转换成三位数文字
|
||||
*/
|
||||
@SuppressLint("DefaultLocale")
|
||||
fun int2String(int: Int): String {
|
||||
return String.format("%03d", int)
|
||||
}
|
||||
|
||||
}
|
||||
134
app/src/main/java/com/gogame/minesweeper/swipe/SingleView.kt
Normal file
@ -0,0 +1,134 @@
|
||||
package com.gogame.minesweeper.swipe
|
||||
|
||||
import android.annotation.SuppressLint
|
||||
import android.content.Context
|
||||
import android.media.MediaPlayer
|
||||
import android.util.AttributeSet
|
||||
import android.view.MotionEvent
|
||||
import android.view.View
|
||||
import android.view.View.OnTouchListener
|
||||
import android.widget.ImageView
|
||||
import com.gogame.minesweeper.R
|
||||
|
||||
@SuppressLint("AppCompatCustomView")
|
||||
class SingleView(context: Context?, attrs: AttributeSet?, defStyleAttr: Int) :
|
||||
ImageView(context, attrs, defStyleAttr), View.OnClickListener, View.OnLongClickListener{
|
||||
|
||||
|
||||
companion object {
|
||||
//常量定义
|
||||
const val VIEWSTATE_DEFAULT = 0
|
||||
const val VIEWSTATE_FLAG = 1//标记这里是雷
|
||||
const val VIEWSTATE_UNSURE = 2//? 不确定
|
||||
const val VIEWSTATE_TIP = 3//显示周围雷数 需要配合around参数
|
||||
const val VIEWSTATE_THUNDER = 4//游戏结束的时候显示这里的确是雷
|
||||
const val VIEWSTATE_BOMB = 5//游戏失败时最后点到的雷
|
||||
|
||||
const val LOGICSTATE_NOT_INITED = -1
|
||||
const val LOGICSTATE_BOMB = -2
|
||||
}
|
||||
|
||||
// val mPaint = Paint()
|
||||
var around = 0
|
||||
//周围有几颗雷
|
||||
set(value) {
|
||||
if (value > 8)
|
||||
throw IllegalArgumentException("around should not be this value:$value")
|
||||
else
|
||||
field = value
|
||||
}
|
||||
var viewState = 0
|
||||
var logicState = LOGICSTATE_NOT_INITED//-1 未初始化 0~8周围地雷数 -2雷 只有这几种可能
|
||||
var enable = true//点击过以后不能再次点击 或者也有可能设置不可点击就行了?
|
||||
var gridX = -1
|
||||
var gridY = -1
|
||||
lateinit var mGrid: SwipeGridLayout
|
||||
|
||||
|
||||
init {
|
||||
isClickable = true
|
||||
setOnClickListener(this)
|
||||
setOnLongClickListener(this)
|
||||
setBackgroundResource(R.drawable.sel_bg_single)
|
||||
scaleType = ScaleType.CENTER_CROP
|
||||
|
||||
updateInsideImg()
|
||||
if (attrs != null) {
|
||||
//nothing to do
|
||||
}
|
||||
}
|
||||
|
||||
constructor(context: Context?, x: Int, y: Int, mGridLayout: SwipeGridLayout) : this(context) {
|
||||
this.gridX = x
|
||||
this.gridY = y
|
||||
this.mGrid = mGridLayout
|
||||
}
|
||||
|
||||
constructor(context: Context?, attrs: AttributeSet?) : this(context, attrs, 0)
|
||||
constructor(context: Context?) : this(context, null)
|
||||
|
||||
fun updateInsideImg(): Unit {
|
||||
setImageResource(
|
||||
when (viewState) {
|
||||
VIEWSTATE_DEFAULT -> R.mipmap.tile
|
||||
VIEWSTATE_BOMB -> R.mipmap.mine_exploded
|
||||
VIEWSTATE_THUNDER -> R.mipmap.mine
|
||||
VIEWSTATE_FLAG -> R.mipmap.flag
|
||||
VIEWSTATE_UNSURE -> R.mipmap.unsuer
|
||||
VIEWSTATE_TIP -> when (around) {
|
||||
0 -> R.mipmap.empty
|
||||
1 -> R.mipmap.n1
|
||||
2 -> R.mipmap.n2
|
||||
3 -> R.mipmap.n3
|
||||
4 -> R.mipmap.n4
|
||||
5 -> R.mipmap.n5
|
||||
6 -> R.mipmap.n6
|
||||
7 -> R.mipmap.n7
|
||||
8 -> R.mipmap.n8
|
||||
else -> throw IllegalArgumentException("illegal around")
|
||||
}
|
||||
|
||||
else -> throw IllegalArgumentException("illegal viewState")
|
||||
}
|
||||
)
|
||||
invalidate()//理论上应该都是在主线程调用的该方法
|
||||
}
|
||||
|
||||
override fun onClick(v: View?) {
|
||||
if (!enable)
|
||||
return
|
||||
if (viewState == VIEWSTATE_FLAG)//fix 插旗以后应该不再能点开了,防误触
|
||||
return
|
||||
|
||||
mGrid.onChildClicked(this, gridX, gridY)
|
||||
}
|
||||
|
||||
override fun onLongClick(v: View?): Boolean {
|
||||
if (!enable)
|
||||
return true
|
||||
if (!mGrid.started)
|
||||
return true
|
||||
|
||||
viewState = when (viewState) {
|
||||
VIEWSTATE_DEFAULT -> VIEWSTATE_FLAG
|
||||
VIEWSTATE_FLAG -> VIEWSTATE_UNSURE
|
||||
VIEWSTATE_UNSURE -> VIEWSTATE_DEFAULT
|
||||
else -> viewState
|
||||
}
|
||||
updateInsideImg()
|
||||
|
||||
mGrid.onChildLongClicked(this, gridX, gridY, viewState)
|
||||
return true
|
||||
}
|
||||
|
||||
fun reset() {
|
||||
viewState = VIEWSTATE_DEFAULT
|
||||
logicState = LOGICSTATE_NOT_INITED
|
||||
around = 0
|
||||
enable = true
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
368
app/src/main/java/com/gogame/minesweeper/swipe/SwipeActivity.kt
Normal file
@ -0,0 +1,368 @@
|
||||
package com.gogame.minesweeper.swipe
|
||||
|
||||
import android.app.Dialog
|
||||
import android.content.Context
|
||||
import android.media.MediaPlayer
|
||||
import android.os.Bundle
|
||||
import android.os.Handler
|
||||
import android.os.Looper
|
||||
import android.view.View
|
||||
import android.widget.ImageView
|
||||
import android.widget.TextView
|
||||
import androidx.core.view.ViewCompat
|
||||
import androidx.core.view.WindowCompat
|
||||
import androidx.core.view.WindowInsetsCompat
|
||||
import com.gogame.minesweeper.DifficultyLevel
|
||||
import com.gogame.minesweeper.R
|
||||
import com.gogame.minesweeper.databinding.ActivitySwipeBinding
|
||||
import com.gogame.minesweeper.BaseActivity
|
||||
import com.gogame.minesweeper.ad.AdShowFailed
|
||||
import com.gogame.minesweeper.ad.AdsInsUtil
|
||||
import com.gogame.minesweeper.ad.LoadListener
|
||||
import com.gogame.minesweeper.ad.ShowListener
|
||||
import com.gogame.minesweeper.bean.GameState
|
||||
import com.google.gson.Gson
|
||||
import com.ironsource.fa
|
||||
import com.thinkup.core.api.TUAdInfo
|
||||
import kotlin.random.Random
|
||||
|
||||
class SwipeActivity : BaseActivity() {
|
||||
|
||||
private lateinit var binding: ActivitySwipeBinding
|
||||
|
||||
private var minutes = 0
|
||||
private var seconds = 0
|
||||
private var isRunning = false
|
||||
private var pausedTime = 0L // 暂停时保存的时间戳
|
||||
private var isGameStarted = false //游戏是否开始了
|
||||
private var isGameOver = false //游戏是否结束了(不管成功还是失败)
|
||||
private val handler = Handler(Looper.getMainLooper())
|
||||
private lateinit var runnable: Runnable
|
||||
private lateinit var winSoundPlayer: MediaPlayer
|
||||
private lateinit var loseSoundPlayer: MediaPlayer
|
||||
private var isNewGame = true
|
||||
|
||||
override fun onCreate(savedInstanceState: Bundle?) {
|
||||
super.onCreate(savedInstanceState)
|
||||
binding = ActivitySwipeBinding.inflate(layoutInflater)
|
||||
setContentView(binding.root)
|
||||
loadAd()
|
||||
immersionBar()
|
||||
winSoundPlayer = MediaPlayer.create(this, R.raw.win)
|
||||
loseSoundPlayer = MediaPlayer.create(this, R.raw.explosion)
|
||||
|
||||
var difficulty = intent.getSerializableExtra("difficulty") as? DifficultyLevel
|
||||
if (difficulty == null) {
|
||||
difficulty = DifficultyLevel.BEGINNER
|
||||
}
|
||||
isNewGame = intent.getBooleanExtra("isNewGame", true)
|
||||
initTimeRun()
|
||||
|
||||
resetTimer()
|
||||
|
||||
val sharedPreferences = getSharedPreferences("minesweeper_prefs", Context.MODE_PRIVATE)
|
||||
val gameStateJson = sharedPreferences.getString("game_state", null)
|
||||
|
||||
binding.gridSwipe.postDelayed({
|
||||
binding.gridSwipe.setDifficulty(difficulty)
|
||||
setNumberImage(binding.gridSwipe.mineNum, binding.hundreds, binding.tens, binding.ones)
|
||||
binding.gridSwipe.fillAll()
|
||||
|
||||
if (!isNewGame) {
|
||||
if (!gameStateJson.isNullOrEmpty()) {
|
||||
val gameState: GameState = Gson().fromJson(gameStateJson, GameState::class.java)
|
||||
minutes = gameState.minutes
|
||||
seconds = gameState.seconds
|
||||
|
||||
startTimeRun()
|
||||
}
|
||||
binding.gridSwipe.loadGameState()
|
||||
}
|
||||
}, 120)
|
||||
|
||||
binding.btnStart.setOnClickListener {
|
||||
handleButtonClick()
|
||||
}
|
||||
binding.gridSwipe.listener = object : SwipeGridLayout.GameStateChange {
|
||||
override fun onStart(rest: Int) {
|
||||
isGameStarted = true
|
||||
binding.stateImg.setImageResource(R.mipmap.smile)
|
||||
startTimeRun()
|
||||
}
|
||||
|
||||
override fun onFlagsChange(flags: Int, rest: Int) {
|
||||
setNumberImage(rest, binding.hundreds, binding.tens, binding.ones)
|
||||
}
|
||||
|
||||
override fun victory() {
|
||||
isGameOver = true
|
||||
playWinSound()
|
||||
showResultDialog(true)
|
||||
stopTimer()
|
||||
|
||||
binding.gridSwipe.clearGameStateSP()
|
||||
}
|
||||
|
||||
override fun defeat() {
|
||||
isGameOver = true
|
||||
playLoseSound()
|
||||
binding.stateImg.setImageResource(R.mipmap.sorrow)
|
||||
showResultDialog(false)
|
||||
stopTimer()
|
||||
|
||||
binding.gridSwipe.clearGameStateSP()
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
private fun immersionBar() {
|
||||
//自适应沉浸式
|
||||
ViewCompat.setOnApplyWindowInsetsListener(findViewById(R.id.main)) { v, insets ->
|
||||
val systemBars = insets.getInsets(WindowInsetsCompat.Type.systemBars())
|
||||
v.setPadding(systemBars.left, systemBars.top, systemBars.right, systemBars.bottom)
|
||||
insets
|
||||
}
|
||||
|
||||
val windowInsetsController = WindowCompat.getInsetsController(window, window.decorView)
|
||||
windowInsetsController.isAppearanceLightStatusBars = true//状态栏文字颜色
|
||||
}
|
||||
|
||||
private val successImages = arrayOf(
|
||||
R.drawable.win_emoji_partying_face, // 替换为你的成功图片资源
|
||||
R.drawable.win_emoji_cowboy_hat_face,
|
||||
R.drawable.win_emoji_smiling_face_with_sunglasses,
|
||||
R.drawable.win_emoji_beaming_face_with_smiling_eyes
|
||||
)
|
||||
|
||||
private val failureImages = arrayOf(
|
||||
R.drawable.lose_emoji_bomb, // 替换为你的失败图片资源
|
||||
R.drawable.lose_emoji_confounded_face,
|
||||
R.drawable.lose_emoji_anguished_face,
|
||||
R.drawable.lose_emoji_exploding_head, // 替换为你的失败图片资源
|
||||
R.drawable.lose_emoji_grimacing_face,
|
||||
R.drawable.lose_emoji_downcast_face_with_sweat,
|
||||
R.drawable.lose_emoji_face_with_head_bandage,
|
||||
R.drawable.lose_emoji_sad_but_relieved_face
|
||||
)
|
||||
|
||||
private fun showResultDialog(isVictory: Boolean) {
|
||||
val dialog = Dialog(this)
|
||||
dialog.setContentView(R.layout.dialog_result)
|
||||
|
||||
val imageView = dialog.findViewById<ImageView>(R.id.imageView)
|
||||
val titleTextView = dialog.findViewById<TextView>(R.id.textViewTitle)
|
||||
val messageTextView = dialog.findViewById<TextView>(R.id.textViewMessage)
|
||||
|
||||
if (isVictory) {
|
||||
val randomSuccessImage = successImages[Random.nextInt(successImages.size)]
|
||||
imageView.setImageResource(randomSuccessImage)
|
||||
titleTextView.text = getString(R.string.you_win)
|
||||
messageTextView.text = getString(R.string.win_desc)
|
||||
} else {
|
||||
val randomFailureImage = failureImages[Random.nextInt(failureImages.size)]
|
||||
imageView.setImageResource(randomFailureImage)
|
||||
titleTextView.text = getString(R.string.you_lose)
|
||||
messageTextView.text = getString(R.string.lose_desc)
|
||||
}
|
||||
|
||||
val btn = dialog.findViewById<TextView>(R.id.newGameBtn)
|
||||
btn.setOnClickListener {
|
||||
handleButtonClick()
|
||||
dialog.dismiss()
|
||||
|
||||
showAd(randomAdPlace)
|
||||
}
|
||||
dialog.setCancelable(false)
|
||||
dialog.show()
|
||||
}
|
||||
|
||||
|
||||
private fun playWinSound() {
|
||||
if (!winSoundPlayer.isPlaying) {
|
||||
winSoundPlayer.start()
|
||||
}
|
||||
}
|
||||
|
||||
private fun playLoseSound() {
|
||||
if (!loseSoundPlayer.isPlaying) {
|
||||
loseSoundPlayer.start()
|
||||
}
|
||||
}
|
||||
|
||||
private fun handleButtonClick() {
|
||||
binding.stateImg.setImageResource(R.mipmap.smile)
|
||||
binding.gridSwipe.reset() // 复位逻辑
|
||||
setNumberImage(
|
||||
binding.gridSwipe.mineNum, binding.hundreds, binding.tens, binding.ones
|
||||
) // 设置数字图片
|
||||
stopTimer() // 停止计时器
|
||||
resetTimer() // 重置计时器
|
||||
}
|
||||
|
||||
private fun startTimeRun() {
|
||||
if (!isRunning) {
|
||||
isRunning = true
|
||||
handler.post(runnable)
|
||||
}
|
||||
}
|
||||
|
||||
// 停止计时并移除 runnable
|
||||
private fun stopTimer() {
|
||||
isRunning = false
|
||||
handler.removeCallbacks(runnable) // 移除 runnable,防止继续执行
|
||||
}
|
||||
|
||||
private fun initTimeRun() {
|
||||
// 初始化计时器
|
||||
runnable = object : Runnable {
|
||||
override fun run() {
|
||||
if (isRunning) {
|
||||
incrementTime()
|
||||
updateTimeImage()
|
||||
handler.postDelayed(this, 1000) // 每秒更新一次
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
private fun setNumberImage(
|
||||
number: Int,
|
||||
hundredsImageView: ImageView,
|
||||
tensImageView: ImageView,
|
||||
onesImageView: ImageView
|
||||
) {
|
||||
// 数字限制在1-999
|
||||
if (number < 1 || number > 999) return
|
||||
|
||||
// 获取百位、十位、个位
|
||||
val hundreds = number / 100
|
||||
val tens = (number % 100) / 10
|
||||
val ones = number % 10
|
||||
|
||||
// 根据数字设置图片资源ID,假设图片资源名为c0到c9
|
||||
val resIdHundreds = getResourceIdForNumber(hundreds)
|
||||
val resIdTens = getResourceIdForNumber(tens)
|
||||
val resIdOnes = getResourceIdForNumber(ones)
|
||||
|
||||
// 设置ImageView的图片资源
|
||||
hundredsImageView.setImageResource(resIdHundreds)
|
||||
tensImageView.setImageResource(resIdTens)
|
||||
onesImageView.setImageResource(resIdOnes)
|
||||
}
|
||||
|
||||
// 获取数字对应的资源ID
|
||||
private fun getResourceIdForNumber(num: Int): Int {
|
||||
return when (num) {
|
||||
0 -> R.mipmap.c0
|
||||
1 -> R.mipmap.c1
|
||||
2 -> R.mipmap.c2
|
||||
3 -> R.mipmap.c3
|
||||
4 -> R.mipmap.c4
|
||||
5 -> R.mipmap.c5
|
||||
6 -> R.mipmap.c6
|
||||
7 -> R.mipmap.c7
|
||||
8 -> R.mipmap.c8
|
||||
9 -> R.mipmap.c9
|
||||
else -> R.mipmap.c0 // 默认值,数字应为0-9
|
||||
}
|
||||
}
|
||||
|
||||
// 增加时间
|
||||
private fun incrementTime() {
|
||||
seconds++
|
||||
if (seconds == 60) {
|
||||
seconds = 0
|
||||
minutes++
|
||||
}
|
||||
|
||||
binding.gridSwipe.setTime(minutes, seconds)
|
||||
}
|
||||
|
||||
// 更新时间的图片显示
|
||||
private fun updateTimeImage() {
|
||||
val minuteTens = minutes / 10
|
||||
val minuteOnes = minutes % 10
|
||||
val secondTens = seconds / 10
|
||||
val secondOnes = seconds % 10
|
||||
|
||||
binding.minuteTens.setImageResource(getResourceIdForNumber(minuteTens))
|
||||
binding.minuteOnes.setImageResource(getResourceIdForNumber(minuteOnes))
|
||||
binding.secondTens.setImageResource(getResourceIdForNumber(secondTens))
|
||||
binding.secondOnes.setImageResource(getResourceIdForNumber(secondOnes))
|
||||
}
|
||||
|
||||
override fun onResume() {
|
||||
super.onResume()
|
||||
//如果游戏开始了并且游戏没有结束
|
||||
if (isGameStarted && !isGameOver) {
|
||||
if (pausedTime > 0L) {
|
||||
// 继续计时
|
||||
handler.post(runnable)
|
||||
isRunning = true
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
override fun onPause() {
|
||||
super.onPause()
|
||||
|
||||
// 保存当前的计时状态
|
||||
pausedTime = System.currentTimeMillis()
|
||||
isRunning = false
|
||||
handler.removeCallbacks(runnable) // 停止计时
|
||||
}
|
||||
|
||||
override fun onDestroy() {
|
||||
super.onDestroy()
|
||||
// 重置计时器
|
||||
resetTimer()
|
||||
//释放资源
|
||||
binding.gridSwipe.onPlayerRelease()
|
||||
winSoundPlayer.release()
|
||||
loseSoundPlayer.release()
|
||||
}
|
||||
|
||||
// 重置计时器为00:00
|
||||
private fun resetTimer() {
|
||||
minutes = 0
|
||||
seconds = 0
|
||||
updateTimeImage()
|
||||
}
|
||||
|
||||
private var randomAdPlace = ""
|
||||
private fun loadAd() {
|
||||
// 生成一个随机索引
|
||||
val randomIndex = Random.nextInt(AdsInsUtil.Placement.adPlaceAllList.size)
|
||||
// 获取随机的广告位
|
||||
randomAdPlace = AdsInsUtil.Placement.adPlaceAllList[randomIndex]
|
||||
AdsInsUtil.loadAd(
|
||||
act = this,
|
||||
adID = randomAdPlace,
|
||||
loadListener = object : LoadListener {
|
||||
override fun loaded(ad: TUAdInfo) {
|
||||
}
|
||||
|
||||
override fun loadFailed(error: String) {
|
||||
}
|
||||
})
|
||||
}
|
||||
private fun showAd(randomAdPlace: String) {
|
||||
AdsInsUtil.showAd(
|
||||
act = this,
|
||||
adID = randomAdPlace,
|
||||
listener = object : ShowListener {
|
||||
override fun onAdShown(ad: TUAdInfo?) {
|
||||
}
|
||||
|
||||
override fun onAdShowFailed(error: AdShowFailed?) {
|
||||
loadAd()
|
||||
}
|
||||
|
||||
override fun onAdClosed() {
|
||||
loadAd()
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,518 @@
|
||||
package com.gogame.minesweeper.swipe
|
||||
|
||||
import android.content.Context
|
||||
import android.graphics.Canvas
|
||||
import android.graphics.Color
|
||||
import android.graphics.Paint
|
||||
import android.media.MediaPlayer
|
||||
import android.util.AttributeSet
|
||||
import android.util.Log
|
||||
import android.view.MotionEvent
|
||||
import android.view.ScaleGestureDetector
|
||||
import android.widget.GridLayout
|
||||
import com.gogame.minesweeper.bean.CellState
|
||||
import com.gogame.minesweeper.DifficultyLevel
|
||||
import com.gogame.minesweeper.bean.GameState
|
||||
import com.gogame.minesweeper.R
|
||||
import com.google.gson.Gson
|
||||
import kotlin.math.abs
|
||||
|
||||
|
||||
class SwipeGridLayout @JvmOverloads constructor(
|
||||
context: Context,
|
||||
attrs: AttributeSet? = null,
|
||||
defStyleAttr: Int = 0,
|
||||
var xLength: Int = 9, // 网格的行数
|
||||
var yLength: Int = 9, // 网格的列数
|
||||
var mineNum: Int = 10 // 地雷的数量
|
||||
) : GridLayout(context, attrs, defStyleAttr) {
|
||||
private val sharedPreferences =
|
||||
context.getSharedPreferences("minesweeper_prefs", Context.MODE_PRIVATE)
|
||||
private var myLevel = DifficultyLevel.BEGINNER
|
||||
private var minutes = 0
|
||||
private var seconds = 0
|
||||
|
||||
// 固定格子初始大小
|
||||
private var fixedSize = 98
|
||||
|
||||
// 点击音效的MediaPlayer
|
||||
private var clickSoundPlayer: MediaPlayer = MediaPlayer.create(context, R.raw.tile)
|
||||
|
||||
// 长按音效的MediaPlayer
|
||||
private var clickLongSoundPlayer: MediaPlayer = MediaPlayer.create(context, R.raw.flag)
|
||||
|
||||
private fun playClickSound() {
|
||||
if (!clickSoundPlayer.isPlaying) {
|
||||
clickSoundPlayer.start()
|
||||
}
|
||||
}
|
||||
|
||||
private fun playLongClickSound() {
|
||||
if (!clickLongSoundPlayer.isPlaying) {
|
||||
clickLongSoundPlayer.start()
|
||||
}
|
||||
}
|
||||
|
||||
var goods: Int//标记剩余未点开的非雷格子,用于判断游戏胜利
|
||||
var started = false//是否已经点击过第一个格子
|
||||
private var scaleFactor = 1.0f // 初始缩放比例
|
||||
private var scaleGestureDetector: ScaleGestureDetector
|
||||
private var isScaling = false // 是否正在缩放
|
||||
|
||||
init {
|
||||
goods = xLength * yLength - mineNum// 初始化非雷格子数
|
||||
|
||||
// 初始化缩放手势检测器
|
||||
scaleGestureDetector = ScaleGestureDetector(context, ScaleListener())
|
||||
}
|
||||
|
||||
|
||||
private inner class ScaleListener : ScaleGestureDetector.SimpleOnScaleGestureListener() {
|
||||
override fun onScaleBegin(detector: ScaleGestureDetector): Boolean {
|
||||
// 缩放开始时,设置标志位为 true
|
||||
isScaling = true
|
||||
return super.onScaleBegin(detector)
|
||||
}
|
||||
|
||||
override fun onScale(detector: ScaleGestureDetector): Boolean {
|
||||
// 更新缩放比例
|
||||
scaleFactor *= detector.scaleFactor
|
||||
|
||||
// 限制缩放比例在 0.5x 到 3x 之间
|
||||
scaleFactor = scaleFactor.coerceIn(0.5f, 1.5f)
|
||||
|
||||
// 请求重新布局
|
||||
requestLayout()
|
||||
return true
|
||||
}
|
||||
|
||||
override fun onScaleEnd(detector: ScaleGestureDetector) {
|
||||
// 缩放结束时,重置标志位为 false
|
||||
isScaling = false
|
||||
super.onScaleEnd(detector)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// 在填充格子时,初始化为固定大小
|
||||
fun fillAll() {
|
||||
removeAllViews()
|
||||
rowCount = xLength
|
||||
columnCount = yLength
|
||||
for (j in 0 until xLength) {
|
||||
for (i in 0 until yLength) {
|
||||
val one = SingleView(context, i, j, this)
|
||||
addView(one, fixedSize, fixedSize) // 使用固定大小
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private var lastX = 0f
|
||||
private var lastY = 0f
|
||||
override fun onInterceptTouchEvent(event: MotionEvent): Boolean {
|
||||
val x = event.x
|
||||
val y = event.y
|
||||
|
||||
|
||||
when (event.action) {
|
||||
MotionEvent.ACTION_DOWN -> {
|
||||
lastX = x
|
||||
lastY = y
|
||||
|
||||
Log.d("ocean", "onInterceptTouchEvent ACTION_DOWN")
|
||||
Log.d(
|
||||
"ocean",
|
||||
"onInterceptTouchEvent ACTION_DOWN width->${width} height->${height}"
|
||||
)
|
||||
}
|
||||
|
||||
MotionEvent.ACTION_MOVE -> {
|
||||
val deltaX = x - lastX
|
||||
val deltaY = y - lastY
|
||||
|
||||
// 判断是否已经拖动,并且是否超过最小拖动距离
|
||||
if (abs(deltaX) > 10 || abs(deltaY) > 10) {
|
||||
Log.d("ocean", "onInterceptTouchEvent ACTION_MOVE")
|
||||
// 开始处理拖动时,拦截事件
|
||||
return true
|
||||
}
|
||||
}
|
||||
}
|
||||
return super.onInterceptTouchEvent(event)
|
||||
}
|
||||
|
||||
override fun onLayout(
|
||||
changed: Boolean,
|
||||
left: Int,
|
||||
top: Int,
|
||||
right: Int,
|
||||
bottom: Int
|
||||
) {
|
||||
super.onLayout(changed, left, top, right, bottom)
|
||||
|
||||
// 遍历所有的子视图,调整每个格子的大小
|
||||
val childSize = (fixedSize * scaleFactor).toInt() // 缩放后的格子大小
|
||||
for (i in 0 until childCount) {
|
||||
val child = getChildAt(i)
|
||||
val row = i / columnCount
|
||||
val col = i % columnCount
|
||||
|
||||
// 根据缩放后的大小设置每个子视图的位置和大小
|
||||
val childLeft = col * childSize
|
||||
val childTop = row * childSize
|
||||
child.layout(
|
||||
childLeft,
|
||||
childTop,
|
||||
childLeft + childSize,
|
||||
childTop + childSize
|
||||
)
|
||||
}
|
||||
}
|
||||
|
||||
override fun requestLayout() {
|
||||
super.requestLayout()
|
||||
invalidate()
|
||||
}
|
||||
|
||||
override fun onTouchEvent(event: MotionEvent): Boolean {
|
||||
|
||||
// 让 scaleGestureDetector 处理缩放事件
|
||||
scaleGestureDetector.onTouchEvent(event)
|
||||
// 如果正在缩放,阻止其他事件处理
|
||||
if (isScaling) {
|
||||
return true
|
||||
}
|
||||
|
||||
val x = event.x
|
||||
val y = event.y
|
||||
|
||||
when (event.action) {
|
||||
MotionEvent.ACTION_DOWN -> {
|
||||
Log.d("ocean", "onTouchEvent ACTION_DOWN")
|
||||
lastX = x
|
||||
lastY = y
|
||||
}
|
||||
|
||||
MotionEvent.ACTION_MOVE -> {
|
||||
Log.d("ocean", "onTouchEvent ACTION_MOVE x->${event.x} y->${event.y}")
|
||||
Log.d("ocean", "onTouchEvent ACTION_MOVE lastX->${lastX} lastY->${lastY}")
|
||||
val dx = event.x - lastX
|
||||
val dy = event.y - lastY
|
||||
// 移动整个布局
|
||||
scrollBy(-dx.toInt(), -dy.toInt())
|
||||
lastX = event.x
|
||||
lastY = event.y
|
||||
|
||||
Log.d("ocean", "onTouchEvent ACTION_MOVE dx->$dx dy->$dy")
|
||||
return true
|
||||
}
|
||||
|
||||
MotionEvent.ACTION_UP -> {
|
||||
Log.d("ocean", "onTouchEvent ACTION_UP")
|
||||
}
|
||||
|
||||
MotionEvent.ACTION_CANCEL -> {
|
||||
Log.d("ocean", "onTouchEvent ACTION_CANCEL")
|
||||
}
|
||||
}
|
||||
return super.onTouchEvent(event)
|
||||
}
|
||||
|
||||
// 处理网格点击事件
|
||||
fun onChildClicked(v: SingleView, x: Int, y: Int) {
|
||||
|
||||
playClickSound()
|
||||
// 如果这是第一个点击,初始化游戏
|
||||
if (!started) {
|
||||
initCurGame(x, y)
|
||||
started = true
|
||||
listener?.onStart(mineNum)
|
||||
}
|
||||
// 初始化完游戏之后 每一次(包括第一次)按下之后的逻辑
|
||||
when (v.logicState) {
|
||||
SingleView.LOGICSTATE_BOMB -> {
|
||||
doEachSingle { singleView ->
|
||||
if (singleView.logicState == SingleView.LOGICSTATE_BOMB) {
|
||||
singleView.viewState = SingleView.VIEWSTATE_THUNDER
|
||||
}
|
||||
singleView.enable = false
|
||||
}
|
||||
v.viewState = SingleView.VIEWSTATE_BOMB
|
||||
listener?.defeat()
|
||||
|
||||
clearGameStateSP()
|
||||
}
|
||||
|
||||
in 1..8 -> { // 显示周围的雷数
|
||||
v.viewState = SingleView.VIEWSTATE_TIP
|
||||
goods--
|
||||
}
|
||||
|
||||
0 -> {// 如果点击的格子周围没有雷,展开周围的格子
|
||||
openAround(v, LogicHelper.getIndexByXY(xLength, yLength, x, y))
|
||||
}
|
||||
}
|
||||
|
||||
v.enable = false // 禁止再次点击已经翻开的格子
|
||||
doEachSingle { singleView -> singleView.updateInsideImg() }
|
||||
// 判断是否胜利
|
||||
if (goods <= 0) {
|
||||
listener?.victory()
|
||||
doEachSingle { singleView -> singleView.enable = false }
|
||||
|
||||
clearGameStateSP()
|
||||
}
|
||||
}
|
||||
|
||||
// 打开周围的非雷格子
|
||||
private fun openAround(v: SingleView, index: Int) {
|
||||
v.enable = false
|
||||
v.viewState = SingleView.VIEWSTATE_TIP
|
||||
goods--
|
||||
for (around in LogicHelper.getAroundItems(xLength, yLength, index)) {
|
||||
val item = getChildByIndex(around)
|
||||
if (item.viewState == SingleView.VIEWSTATE_DEFAULT && item.logicState >= 0) {
|
||||
if (item.around == 0) {
|
||||
openAround(getChildByIndex(around), around)
|
||||
} else {
|
||||
item.enable = false
|
||||
item.viewState = SingleView.VIEWSTATE_TIP
|
||||
goods--
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// 初始化当前游戏,设置地雷
|
||||
private fun initCurGame(firstX: Int, firstY: Int) {
|
||||
goods = xLength * yLength - mineNum
|
||||
//初始化所有格子
|
||||
initAllChildBefore()
|
||||
// 随机布雷,确保第一个点击的不是雷
|
||||
val randomMines = LogicHelper.randomMines(xLength, yLength, firstX, firstY, mineNum)
|
||||
for (i: Int in randomMines) {
|
||||
val singleView = getChildByIndex(i)
|
||||
singleView.logicState = SingleView.LOGICSTATE_BOMB
|
||||
singleView.viewState = SingleView.VIEWSTATE_DEFAULT//test 显示雷
|
||||
singleView.updateInsideImg()
|
||||
}
|
||||
calMinesAround(randomMines)
|
||||
}
|
||||
|
||||
// 计算每个格子周围的雷数
|
||||
private fun calMinesAround(randomMines: ArrayList<Int>) {
|
||||
for (i: Int in randomMines) {
|
||||
for (j in LogicHelper.getAroundItems(xLength, yLength, i)) {
|
||||
val view = getChildByIndex(j)
|
||||
view.around++
|
||||
if (view.logicState >= 0)//如果不是雷的话
|
||||
view.logicState = view.around
|
||||
view.updateInsideImg()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private fun getChildByIndex(index: Int): SingleView {
|
||||
return getChildAt(index) as SingleView
|
||||
}
|
||||
|
||||
private fun initAllChildBefore() {
|
||||
doEachSingle { singleView: SingleView ->
|
||||
singleView.logicState = 0//初始化逻辑状态 Default
|
||||
singleView.viewState = SingleView.VIEWSTATE_DEFAULT//
|
||||
singleView.around = 0
|
||||
singleView.updateInsideImg()
|
||||
}
|
||||
}
|
||||
|
||||
var flags = 0
|
||||
fun onChildLongClicked(v: SingleView, x: Int, y: Int, viewState: Int) {
|
||||
playLongClickSound()
|
||||
when (viewState) {
|
||||
SingleView.VIEWSTATE_FLAG -> flags++
|
||||
SingleView.VIEWSTATE_UNSURE -> flags--
|
||||
}
|
||||
listener?.onFlagsChange(flags, mineNum - flags)
|
||||
}
|
||||
|
||||
fun getChildByXY(x: Int, y: Int): SingleView {
|
||||
return getChildAt(y * columnCount + x) as SingleView
|
||||
}
|
||||
|
||||
private fun doEachSingle(m: (singleView: SingleView) -> Unit) {
|
||||
for (i in 0..childCount - 1) {
|
||||
m(getChildByIndex(i))
|
||||
}
|
||||
}
|
||||
|
||||
//传送难度数据
|
||||
fun setDifficulty(level: DifficultyLevel) {
|
||||
this.xLength = level.xLength
|
||||
this.yLength = level.yLength
|
||||
this.mineNum = level.mineNum
|
||||
this.myLevel = level
|
||||
}
|
||||
|
||||
//传送时间
|
||||
fun setTime(min: Int, sec: Int) {
|
||||
this.minutes = min
|
||||
this.seconds = sec
|
||||
|
||||
//每一秒都进行存储
|
||||
saveGameState()
|
||||
}
|
||||
|
||||
/**
|
||||
* 开始
|
||||
*/
|
||||
fun reset() {
|
||||
doEachSingle { singleView ->
|
||||
flags = 0
|
||||
goods = xLength * yLength - mineNum
|
||||
started = false//要点击第一个之后才会变成true
|
||||
singleView.reset()
|
||||
singleView.updateInsideImg()
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
var listener: GameStateChange? = null
|
||||
|
||||
interface GameStateChange {
|
||||
fun onStart(rest: Int)
|
||||
fun onFlagsChange(flags: Int, rest: Int)
|
||||
fun victory()
|
||||
fun defeat()
|
||||
}
|
||||
|
||||
/**
|
||||
* 画分割线
|
||||
*/
|
||||
override fun dispatchDraw(canvas: Canvas) {
|
||||
super.dispatchDraw(canvas)
|
||||
if (childCount <= 0) return
|
||||
val column = columnCount
|
||||
val childCount = childCount
|
||||
val localPaint = Paint()
|
||||
localPaint.style = Paint.Style.STROKE
|
||||
localPaint.setColor(Color.parseColor("#303030"))
|
||||
localPaint.isAntiAlias = true
|
||||
localPaint.strokeWidth = 1f
|
||||
for (i in 0 until childCount) {
|
||||
val cellView = getChildAt(i)
|
||||
if (i < columnCount) {
|
||||
canvas.drawLine(
|
||||
cellView.left.toFloat(),
|
||||
cellView.top.toFloat(),
|
||||
cellView.right.toFloat(),
|
||||
cellView.top.toFloat(),
|
||||
localPaint
|
||||
)
|
||||
}
|
||||
if (i % columnCount == 0) {
|
||||
canvas.drawLine(
|
||||
cellView.left.toFloat(),
|
||||
cellView.top.toFloat(),
|
||||
cellView.left.toFloat(),
|
||||
cellView.bottom.toFloat(),
|
||||
localPaint
|
||||
)
|
||||
}
|
||||
canvas.drawLine(
|
||||
cellView.right.toFloat(),
|
||||
cellView.top.toFloat(),
|
||||
cellView.right.toFloat(),
|
||||
cellView.bottom.toFloat(),
|
||||
localPaint
|
||||
)
|
||||
canvas.drawLine(
|
||||
cellView.left.toFloat(),
|
||||
cellView.bottom.toFloat(),
|
||||
cellView.right.toFloat(),
|
||||
cellView.bottom.toFloat(),
|
||||
localPaint
|
||||
)
|
||||
}
|
||||
if (childCount % column != 0) {
|
||||
for (j in 0 until column - childCount % column) {
|
||||
val lastView = getChildAt(childCount - 1)
|
||||
canvas.drawLine(
|
||||
(lastView.right + lastView.width * j).toFloat(),
|
||||
lastView.top.toFloat(),
|
||||
(lastView.right + lastView.width * j).toFloat(),
|
||||
lastView.bottom.toFloat(),
|
||||
localPaint
|
||||
)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
fun onPlayerRelease() {
|
||||
clickSoundPlayer.release() // 释放资源
|
||||
clickLongSoundPlayer.release()
|
||||
}
|
||||
|
||||
fun clearGameStateSP() {
|
||||
val editor = sharedPreferences.edit()
|
||||
editor.remove("game_state")
|
||||
editor.apply()
|
||||
}
|
||||
|
||||
fun saveGameState() {
|
||||
val gridState = Array(xLength) {
|
||||
Array(yLength) {
|
||||
CellState(
|
||||
0,
|
||||
SingleView.VIEWSTATE_DEFAULT, 0
|
||||
)
|
||||
}
|
||||
}
|
||||
|
||||
// 填充格子的状态
|
||||
for (y in 0 until xLength) {
|
||||
for (x in 0 until yLength) {
|
||||
val singleView = getChildByXY(x, y)
|
||||
gridState[y][x] =
|
||||
CellState(singleView.logicState, singleView.viewState, singleView.around)
|
||||
}
|
||||
}
|
||||
|
||||
val gameState = GameState(gridState, goods, myLevel, minutes, seconds)
|
||||
val json = Gson().toJson(gameState)
|
||||
|
||||
|
||||
val editor = sharedPreferences.edit()
|
||||
// 保存的游戏状态json
|
||||
editor.putString("game_state", json)
|
||||
// 提交保存
|
||||
editor.apply()
|
||||
}
|
||||
|
||||
fun loadGameState() {
|
||||
// 获取保存的游戏状态 JSON 字符串
|
||||
val gameStateJson = sharedPreferences.getString("game_state", null)
|
||||
if (gameStateJson.isNullOrEmpty()) {
|
||||
return
|
||||
}
|
||||
val gameState: GameState = Gson().fromJson(gameStateJson, GameState::class.java)
|
||||
//如果保存的难度和进来的难度不一致则不往下执行。
|
||||
if (gameState.difficulty != myLevel) {
|
||||
return
|
||||
}
|
||||
// 恢复格子的状态
|
||||
for (y in 0 until xLength) {
|
||||
for (x in 0 until yLength) {
|
||||
val singleView = getChildByXY(x, y)
|
||||
val cellState = gameState.grid[y][x]
|
||||
singleView.logicState = cellState.logicState
|
||||
singleView.viewState = cellState.viewState
|
||||
singleView.around = cellState.around
|
||||
singleView.updateInsideImg() // 更新格子显示
|
||||
}
|
||||
}
|
||||
goods = gameState.remainingMines
|
||||
mineNum = gameState.difficulty.mineNum
|
||||
started = true
|
||||
}
|
||||
|
||||
}
|
||||
7
app/src/main/res/color/text_color_selector.xml
Normal file
@ -0,0 +1,7 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<!-- 按下时的文字颜色 -->
|
||||
<item android:color="@color/white" android:state_pressed="true" />
|
||||
<!-- 默认文字颜色 -->
|
||||
<item android:color="@color/black_text_color" />
|
||||
</selector>
|
||||
30
app/src/main/res/drawable-v24/ic_launcher_foreground.xml
Normal file
@ -0,0 +1,30 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:aapt="http://schemas.android.com/aapt"
|
||||
android:width="108dp"
|
||||
android:height="108dp"
|
||||
android:viewportWidth="108"
|
||||
android:viewportHeight="108">
|
||||
<path android:pathData="M31,63.928c0,0 6.4,-11 12.1,-13.1c7.2,-2.6 26,-1.4 26,-1.4l38.1,38.1L107,108.928l-32,-1L31,63.928z">
|
||||
<aapt:attr name="android:fillColor">
|
||||
<gradient
|
||||
android:endX="85.84757"
|
||||
android:endY="92.4963"
|
||||
android:startX="42.9492"
|
||||
android:startY="49.59793"
|
||||
android:type="linear">
|
||||
<item
|
||||
android:color="#44000000"
|
||||
android:offset="0.0" />
|
||||
<item
|
||||
android:color="#00000000"
|
||||
android:offset="1.0" />
|
||||
</gradient>
|
||||
</aapt:attr>
|
||||
</path>
|
||||
<path
|
||||
android:fillColor="#FFFFFF"
|
||||
android:fillType="nonZero"
|
||||
android:pathData="M65.3,45.828l3.8,-6.6c0.2,-0.4 0.1,-0.9 -0.3,-1.1c-0.4,-0.2 -0.9,-0.1 -1.1,0.3l-3.9,6.7c-6.3,-2.8 -13.4,-2.8 -19.7,0l-3.9,-6.7c-0.2,-0.4 -0.7,-0.5 -1.1,-0.3C38.8,38.328 38.7,38.828 38.9,39.228l3.8,6.6C36.2,49.428 31.7,56.028 31,63.928h46C76.3,56.028 71.8,49.428 65.3,45.828zM43.4,57.328c-0.8,0 -1.5,-0.5 -1.8,-1.2c-0.3,-0.7 -0.1,-1.5 0.4,-2.1c0.5,-0.5 1.4,-0.7 2.1,-0.4c0.7,0.3 1.2,1 1.2,1.8C45.3,56.528 44.5,57.328 43.4,57.328L43.4,57.328zM64.6,57.328c-0.8,0 -1.5,-0.5 -1.8,-1.2s-0.1,-1.5 0.4,-2.1c0.5,-0.5 1.4,-0.7 2.1,-0.4c0.7,0.3 1.2,1 1.2,1.8C66.5,56.528 65.6,57.328 64.6,57.328L64.6,57.328z"
|
||||
android:strokeWidth="1"
|
||||
android:strokeColor="#00000000" />
|
||||
</vector>
|
||||
7
app/src/main/res/drawable/btn_bg_selector.xml
Normal file
@ -0,0 +1,7 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<!-- 按下时的背景颜色 -->
|
||||
<item android:drawable="@drawable/drw_black_btn_bg" android:state_pressed="true" />
|
||||
<!-- 默认背景颜色 -->
|
||||
<item android:drawable="@drawable/drw_frame_grey_btn_bg" />
|
||||
</selector>
|
||||
7
app/src/main/res/drawable/drw_black_btn_bg.xml
Normal file
@ -0,0 +1,7 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:shape="rectangle">
|
||||
|
||||
<solid android:color="@color/black_btn_bg" />
|
||||
<corners android:radius="16dp" />
|
||||
</shape>
|
||||
7
app/src/main/res/drawable/drw_dialog_bg.xml
Normal file
@ -0,0 +1,7 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:shape="rectangle">
|
||||
|
||||
<solid android:color="@color/white" />
|
||||
<corners android:radius="16dp" />
|
||||
</shape>
|
||||
9
app/src/main/res/drawable/drw_frame_grey_btn_bg.xml
Normal file
@ -0,0 +1,9 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:shape="rectangle">
|
||||
|
||||
<stroke
|
||||
android:width="1dp"
|
||||
android:color="@color/grey" />
|
||||
<corners android:radius="16dp" />
|
||||
</shape>
|
||||
7
app/src/main/res/drawable/drw_grey_btn_bg.xml
Normal file
@ -0,0 +1,7 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:shape="rectangle">
|
||||
|
||||
<solid android:color="@color/grey" />
|
||||
<corners android:radius="16dp" />
|
||||
</shape>
|
||||
7
app/src/main/res/drawable/drw_red_btn_bg.xml
Normal file
@ -0,0 +1,7 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:shape="rectangle">
|
||||
|
||||
<solid android:color="@color/dark_red" />
|
||||
<corners android:radius="16dp" />
|
||||
</shape>
|
||||
170
app/src/main/res/drawable/ic_launcher_background.xml
Normal file
@ -0,0 +1,170 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="108dp"
|
||||
android:height="108dp"
|
||||
android:viewportWidth="108"
|
||||
android:viewportHeight="108">
|
||||
<path
|
||||
android:fillColor="#3DDC84"
|
||||
android:pathData="M0,0h108v108h-108z" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M9,0L9,108"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M19,0L19,108"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M29,0L29,108"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M39,0L39,108"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M49,0L49,108"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M59,0L59,108"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M69,0L69,108"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M79,0L79,108"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M89,0L89,108"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M99,0L99,108"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M0,9L108,9"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M0,19L108,19"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M0,29L108,29"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M0,39L108,39"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M0,49L108,49"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M0,59L108,59"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M0,69L108,69"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M0,79L108,79"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M0,89L108,89"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M0,99L108,99"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M19,29L89,29"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M19,39L89,39"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M19,49L89,49"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M19,59L89,59"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M19,69L89,69"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M19,79L89,79"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M29,19L29,89"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M39,19L39,89"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M49,19L49,89"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M59,19L59,89"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M69,19L69,89"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M79,19L79,89"
|
||||
android:strokeWidth="0.8"
|
||||
android:strokeColor="#33FFFFFF" />
|
||||
</vector>
|
||||
53
app/src/main/res/drawable/lose_emoji_anguished_face.xml
Normal file
@ -0,0 +1,53 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:aapt="http://schemas.android.com/aapt"
|
||||
android:width="128dp"
|
||||
android:height="128dp"
|
||||
android:viewportWidth="128"
|
||||
android:viewportHeight="128">
|
||||
<path android:pathData="M63.6,118.8c-27.9,0 -58,-17.5 -58,-55.9S35.7,7 63.6,7c15.5,0 29.8,5.1 40.4,14.4c11.5,10.2 17.6,24.6 17.6,41.5s-6.1,31.2 -17.6,41.4c-10.6,9.3 -25,14.5 -40.4,14.5z">
|
||||
<aapt:attr name="android:fillColor">
|
||||
<gradient
|
||||
android:centerX="63.6"
|
||||
android:centerY="62.9"
|
||||
android:gradientRadius="56.96"
|
||||
android:type="radial">
|
||||
<item
|
||||
android:color="#FFFDE030"
|
||||
android:offset="0.5" />
|
||||
<item
|
||||
android:color="#FFF7C02B"
|
||||
android:offset="0.92" />
|
||||
<item
|
||||
android:color="#FFF4A223"
|
||||
android:offset="1" />
|
||||
</gradient>
|
||||
</aapt:attr>
|
||||
</path>
|
||||
<path
|
||||
android:fillColor="#eb8f00"
|
||||
android:pathData="M111.49,29.67c5.33,8.6 8.11,18.84 8.11,30.23c0,16.9 -6.1,31.2 -17.6,41.4c-10.6,9.3 -25,14.5 -40.4,14.5c-18.06,0 -37,-7.35 -48.18,-22.94c10.76,17.66 31,25.94 50.18,25.94c15.4,0 29.8,-5.2 40.4,-14.5c11.5,-10.2 17.6,-24.5 17.6,-41.4c0,-12.74 -3.47,-24.06 -10.11,-33.23z" />
|
||||
<path
|
||||
android:fillColor="#422b0d"
|
||||
android:pathData="M52.7,103c-3.35,0 -6.45,-1.74 -8.2,-4.6a8,8 0,0 1,0.4 -8.9c4.3,-6 10.9,-9.2 19.1,-9.2s14.8,3.2 19.1,9.2a8,8 0,0 1,0.4 8.9a9.606,9.606 0,0 1,-8.2 4.6c-1.05,-0.01 -2.1,-0.18 -3.1,-0.5a26.56,26.56 0,0 0,-16.4 0c-1,0.31 -2.05,0.48 -3.1,0.5z" />
|
||||
<path
|
||||
android:fillColor="#422b0d"
|
||||
android:pathData="M83.4,31.31h-0.1c-1.01,0.08 -1.9,-0.67 -1.99,-1.68c-0.08,-1.01 0.67,-1.9 1.68,-1.99c1.93,-0.29 3.9,-0.27 5.83,0.05c5.23,0.8 9.96,3.56 13.22,7.73c1.49,2 -1.14,3.9 -2.79,2.4c-4.4,-3.89 -9.98,-6.18 -15.85,-6.51z" />
|
||||
<path
|
||||
android:fillColor="#422b0d"
|
||||
android:pathData="M44.85,31.31H45c1.02,0.02 1.85,-0.79 1.87,-1.81c0.02,-0.92 -0.66,-1.72 -1.57,-1.85c-1.93,-0.29 -3.9,-0.27 -5.83,0.05c-5.24,0.79 -9.97,3.56 -13.23,7.73c-1.48,2 1.15,3.9 2.79,2.4a26.23,26.23 0,0 1,15.82 -6.52z" />
|
||||
<path
|
||||
android:fillColor="#422b0d"
|
||||
android:pathData="M44,49.94c-4.19,0 -8,3.54 -8,9.42s3.81,9.41 8,9.41c4.2,0 8,-3.54 8,-9.41s-3.76,-9.42 -8,-9.42z" />
|
||||
<path
|
||||
android:fillColor="#896024"
|
||||
android:pathData="M43.65,53.87a2.874,2.874 0,0 0,-3.82 1.34c-0.53,1.11 -0.29,2.44 0.6,3.3c1.42,0.68 3.13,0.08 3.82,-1.34c0.53,-1.11 0.29,-2.44 -0.6,-3.3z" />
|
||||
<path
|
||||
android:fillColor="#422b0d"
|
||||
android:pathData="M82.4,49.94c-4.19,0 -8,3.54 -8,9.42s3.81,9.41 8,9.41c4.19,0 8,-3.54 8,-9.41s-3.81,-9.42 -8,-9.42z" />
|
||||
<path
|
||||
android:fillColor="#896024"
|
||||
android:pathData="M82,53.87a2.874,2.874 0,0 0,-3.82 1.34c-0.53,1.11 -0.29,2.44 0.6,3.3c1.42,0.68 3.13,0.08 3.82,-1.34c0.53,-1.11 0.29,-2.44 -0.6,-3.3z" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M0,0h128v128h-128z" />
|
||||
</vector>
|
||||
260
app/src/main/res/drawable/lose_emoji_bomb.xml
Normal file
@ -0,0 +1,260 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:aapt="http://schemas.android.com/aapt"
|
||||
android:width="128dp"
|
||||
android:height="128dp"
|
||||
android:viewportWidth="128"
|
||||
android:viewportHeight="128">
|
||||
<path
|
||||
android:fillColor="#f44336"
|
||||
android:pathData="M31.24,18.76c-0.33,-0.34 -0.68,-0.68 -1.11,-0.98c-2.51,-1.75 -5.65,1.54 -4.27,4.07c0.41,0.76 0.96,1.42 1.58,2c2.5,-0.53 3.88,-2.48 3.8,-5.09z" />
|
||||
<path
|
||||
android:fillColor="#212121"
|
||||
android:pathData="M80.4,4.7c-10.18,-0.51 -17.33,6.91 -25.27,12.02c-5.23,3.36 -10.89,5.32 -17.18,4.74c-1.49,-0.14 -3.02,-0.35 -4.41,-0.92c-1.04,-0.42 -1.64,-1.1 -2.29,-1.77c0.07,2.62 -1.31,4.56 -3.79,5.09c3.03,2.81 8.17,3.58 11.92,3.67c9.89,0.25 17.43,-4.52 25.12,-10.12c4.93,-3.6 16.74,-11.53 21.83,-3.91c2.7,4.04 -0.04,13.03 -4.73,14.68c-3.62,1.28 -2.06,7.08 1.59,5.79c6.22,-2.2 9.77,-9.39 10.11,-15.67c0.42,-7.93 -5.18,-13.21 -12.9,-13.6z" />
|
||||
<path
|
||||
android:fillColor="#504f4f"
|
||||
android:pathData="M80.4,4.7c-10.18,-0.51 -17.33,6.91 -25.27,12.02c-5.23,3.36 -10.89,5.32 -17.18,4.74c-1.49,-0.14 -3.02,-0.35 -4.41,-0.92c-1.04,-0.42 -1.64,-1.1 -2.29,-1.77c0.07,2.62 -1.31,4.56 -3.79,5.09c3.03,2.81 8.17,3.58 11.92,3.67c9.89,0.25 17.43,-4.52 25.12,-10.12c4.93,-3.6 16.74,-11.53 21.83,-3.91c2.7,4.04 -0.04,13.03 -4.73,14.68c-3.62,1.28 -2.06,7.08 1.59,5.79c6.22,-2.2 9.77,-9.39 10.11,-15.67c0.42,-7.93 -5.18,-13.21 -12.9,-13.6z" />
|
||||
<path android:pathData="M99.96,44.22l-3.23,-11.43c-0.56,-2.13 -2.31,-3.39 -4.42,-4.03l-12.69,-3.88c-2.11,-0.64 -4.26,-0.58 -5.92,0.87l-9.14,7.89C47.31,35.77 32.1,47.63 26.69,65.33c-7.33,23.99 6.18,49.32 30.17,56.66c23.99,7.33 49.39,-6.19 56.72,-30.18c5.43,-17.7 -0.5,-36.18 -13.62,-47.59z">
|
||||
<aapt:attr name="android:fillColor">
|
||||
<gradient
|
||||
android:centerX="60.68351"
|
||||
android:centerY="66.65497"
|
||||
android:gradientRadius="47.649"
|
||||
android:type="radial">
|
||||
<item
|
||||
android:color="#FF616161"
|
||||
android:offset="0.231" />
|
||||
<item
|
||||
android:color="#FF212121"
|
||||
android:offset="0.928" />
|
||||
</gradient>
|
||||
</aapt:attr>
|
||||
</path>
|
||||
<path android:pathData="M99.96,44.22l-3.23,-11.43c-0.56,-2.13 -2.31,-3.39 -4.42,-4.03l-12.69,-3.88c-2.11,-0.64 -4.26,-0.58 -5.92,0.87l-9.14,7.89C47.31,35.77 32.1,47.63 26.69,65.33c-7.33,23.99 6.18,49.32 30.17,56.66c23.99,7.33 49.39,-6.19 56.72,-30.18c5.43,-17.7 -0.5,-36.18 -13.62,-47.59z">
|
||||
<aapt:attr name="android:fillColor">
|
||||
<gradient
|
||||
android:centerX="71.611"
|
||||
android:centerY="78.309"
|
||||
android:gradientRadius="44.23"
|
||||
android:type="radial">
|
||||
<item
|
||||
android:color="#00504F4F"
|
||||
android:offset="0.75" />
|
||||
<item
|
||||
android:color="#FF504F4F"
|
||||
android:offset="1" />
|
||||
</gradient>
|
||||
</aapt:attr>
|
||||
</path>
|
||||
<path android:pathData="M100.01,44.22l-3.23,-11.43c-0.56,-2.13 -2.31,-3.39 -4.42,-4.03l-12.69,-3.88c-2.11,-0.64 -4.26,-0.58 -5.92,0.87l-9.14,7.89l35.4,10.58z">
|
||||
<aapt:attr name="android:fillColor">
|
||||
<gradient
|
||||
android:endX="101.931"
|
||||
android:endY="-7.072"
|
||||
android:startX="75.978"
|
||||
android:startY="53.765"
|
||||
android:type="linear">
|
||||
<item
|
||||
android:color="#FF616161"
|
||||
android:offset="0" />
|
||||
<item
|
||||
android:color="#FF333333"
|
||||
android:offset="0.488" />
|
||||
<item
|
||||
android:color="#FF616161"
|
||||
android:offset="1" />
|
||||
</gradient>
|
||||
</aapt:attr>
|
||||
</path>
|
||||
<path android:pathData="M28.67,2.67l1.66,11.31l-3,0.04z">
|
||||
<aapt:attr name="android:fillColor">
|
||||
<gradient
|
||||
android:endX="28.83"
|
||||
android:endY="14.021"
|
||||
android:startX="28.663"
|
||||
android:startY="2.689"
|
||||
android:type="linear">
|
||||
<item
|
||||
android:color="#FFFF9100"
|
||||
android:offset="0.362" />
|
||||
<item
|
||||
android:color="#FFFF8A04"
|
||||
android:offset="0.454" />
|
||||
<item
|
||||
android:color="#FFFF760F"
|
||||
android:offset="0.589" />
|
||||
<item
|
||||
android:color="#FFFF5621"
|
||||
android:offset="0.751" />
|
||||
<item
|
||||
android:color="#FFFF2A39"
|
||||
android:offset="0.931" />
|
||||
<item
|
||||
android:color="#FFFF1744"
|
||||
android:offset="1" />
|
||||
</gradient>
|
||||
</aapt:attr>
|
||||
</path>
|
||||
<path android:pathData="M13.25,9.88l11.22,5.35l-1.61,2.54z">
|
||||
<aapt:attr name="android:fillColor">
|
||||
<gradient
|
||||
android:endX="24.47"
|
||||
android:endY="13.825"
|
||||
android:startX="13.25"
|
||||
android:startY="13.825"
|
||||
android:type="linear">
|
||||
<item
|
||||
android:color="#FFFF9100"
|
||||
android:offset="0.362" />
|
||||
<item
|
||||
android:color="#FFFF8A04"
|
||||
android:offset="0.454" />
|
||||
<item
|
||||
android:color="#FFFF760F"
|
||||
android:offset="0.589" />
|
||||
<item
|
||||
android:color="#FFFF5621"
|
||||
android:offset="0.751" />
|
||||
<item
|
||||
android:color="#FFFF2A39"
|
||||
android:offset="0.931" />
|
||||
<item
|
||||
android:color="#FFFF1744"
|
||||
android:offset="1" />
|
||||
</gradient>
|
||||
</aapt:attr>
|
||||
</path>
|
||||
<path android:pathData="M11.5,25.17l11.3,-4.01l0.65,2.93z">
|
||||
<aapt:attr name="android:fillColor">
|
||||
<gradient
|
||||
android:endX="23.02"
|
||||
android:endY="22.654"
|
||||
android:startX="13.52"
|
||||
android:startY="25.321"
|
||||
android:type="linear">
|
||||
<item
|
||||
android:color="#FFFF9100"
|
||||
android:offset="0.362" />
|
||||
<item
|
||||
android:color="#FFFF8A04"
|
||||
android:offset="0.454" />
|
||||
<item
|
||||
android:color="#FFFF760F"
|
||||
android:offset="0.589" />
|
||||
<item
|
||||
android:color="#FFFF5621"
|
||||
android:offset="0.751" />
|
||||
<item
|
||||
android:color="#FFFF2A39"
|
||||
android:offset="0.931" />
|
||||
<item
|
||||
android:color="#FFFF1744"
|
||||
android:offset="1" />
|
||||
</gradient>
|
||||
</aapt:attr>
|
||||
</path>
|
||||
<path android:pathData="M27.34,28.09l-7.66,8.47l5.19,-10.17z">
|
||||
<aapt:attr name="android:fillColor">
|
||||
<gradient
|
||||
android:endX="26.147"
|
||||
android:endY="27.18"
|
||||
android:startX="19.647"
|
||||
android:startY="36.347"
|
||||
android:type="linear">
|
||||
<item
|
||||
android:color="#FFFF9100"
|
||||
android:offset="0.362" />
|
||||
<item
|
||||
android:color="#FFFF8A04"
|
||||
android:offset="0.454" />
|
||||
<item
|
||||
android:color="#FFFF760F"
|
||||
android:offset="0.589" />
|
||||
<item
|
||||
android:color="#FFFF5621"
|
||||
android:offset="0.751" />
|
||||
<item
|
||||
android:color="#FFFF2A39"
|
||||
android:offset="0.931" />
|
||||
<item
|
||||
android:color="#FFFF1744"
|
||||
android:offset="1" />
|
||||
</gradient>
|
||||
</aapt:attr>
|
||||
</path>
|
||||
<path android:pathData="M32.04,28.43l0.48,9.34l-2.9,-8.89z">
|
||||
<aapt:attr name="android:fillColor">
|
||||
<gradient
|
||||
android:endX="30.82026"
|
||||
android:endY="28.598633"
|
||||
android:startX="32.383183"
|
||||
android:startY="37.671284"
|
||||
android:type="linear">
|
||||
<item
|
||||
android:color="#FFFF9100"
|
||||
android:offset="0.362" />
|
||||
<item
|
||||
android:color="#FFFF8A04"
|
||||
android:offset="0.454" />
|
||||
<item
|
||||
android:color="#FFFF760F"
|
||||
android:offset="0.589" />
|
||||
<item
|
||||
android:color="#FFFF5621"
|
||||
android:offset="0.751" />
|
||||
<item
|
||||
android:color="#FFFF2A39"
|
||||
android:offset="0.931" />
|
||||
<item
|
||||
android:color="#FFFF1744"
|
||||
android:offset="1" />
|
||||
</gradient>
|
||||
</aapt:attr>
|
||||
</path>
|
||||
<path android:pathData="M33.04,14.01l8.63,-7.51l-6.38,9.49z">
|
||||
<aapt:attr name="android:fillColor">
|
||||
<gradient
|
||||
android:endX="41.527"
|
||||
android:endY="6.586"
|
||||
android:startX="34.527"
|
||||
android:startY="14.586"
|
||||
android:type="linear">
|
||||
<item
|
||||
android:color="#FFFF1744"
|
||||
android:offset="0" />
|
||||
<item
|
||||
android:color="#FFFF2A39"
|
||||
android:offset="0.069" />
|
||||
<item
|
||||
android:color="#FFFF5621"
|
||||
android:offset="0.249" />
|
||||
<item
|
||||
android:color="#FFFF760F"
|
||||
android:offset="0.411" />
|
||||
<item
|
||||
android:color="#FFFF8A04"
|
||||
android:offset="0.546" />
|
||||
<item
|
||||
android:color="#FFFF9100"
|
||||
android:offset="0.638" />
|
||||
</gradient>
|
||||
</aapt:attr>
|
||||
</path>
|
||||
<path
|
||||
android:fillColor="#f44336"
|
||||
android:pathData="M22.94,10.19m-0.94,0a0.94,0.94 0,1 1,1.88 0a0.94,0.94 0,1 1,-1.88 0" />
|
||||
<path
|
||||
android:fillColor="#f44336"
|
||||
android:pathData="M17.75,19.38m-1,0a1,1 0,1 1,2 0a1,1 0,1 1,-2 0" />
|
||||
<path
|
||||
android:fillColor="#f44336"
|
||||
android:pathData="M38,17.38m-1,0a1,1 0,1 1,2 0a1,1 0,1 1,-2 0" />
|
||||
<path
|
||||
android:fillColor="#f44336"
|
||||
android:pathData="M26.33,32.92m-0.57,0a0.57,0.57 0,1 1,1.14 0a0.57,0.57 0,1 1,-1.14 0" />
|
||||
<path
|
||||
android:fillColor="#f44336"
|
||||
android:pathData="M17.38,29.5m-1,0a1,1 0,1 1,2 0a1,1 0,1 1,-2 0" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M0,0h128v128h-128z" />
|
||||
</vector>
|
||||
45
app/src/main/res/drawable/lose_emoji_confounded_face.xml
Normal file
@ -0,0 +1,45 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:aapt="http://schemas.android.com/aapt"
|
||||
android:width="128dp"
|
||||
android:height="128dp"
|
||||
android:viewportWidth="128"
|
||||
android:viewportHeight="128">
|
||||
<path android:pathData="M63.6,118.8c-27.9,0 -58,-17.5 -58,-55.9S35.7,7 63.6,7c15.5,0 29.8,5.1 40.4,14.4c11.5,10.2 17.6,24.6 17.6,41.5s-6.1,31.2 -17.6,41.4c-10.6,9.3 -25,14.5 -40.4,14.5z">
|
||||
<aapt:attr name="android:fillColor">
|
||||
<gradient
|
||||
android:centerX="63.6"
|
||||
android:centerY="62.9"
|
||||
android:gradientRadius="56.96"
|
||||
android:type="radial">
|
||||
<item
|
||||
android:color="#FFFDE030"
|
||||
android:offset="0.5" />
|
||||
<item
|
||||
android:color="#FFF7C02B"
|
||||
android:offset="0.92" />
|
||||
<item
|
||||
android:color="#FFF4A223"
|
||||
android:offset="1" />
|
||||
</gradient>
|
||||
</aapt:attr>
|
||||
</path>
|
||||
<path
|
||||
android:fillColor="#eb8f00"
|
||||
android:pathData="M111.49,29.67c5.33,8.6 8.11,18.84 8.11,30.23c0,16.9 -6.1,31.2 -17.6,41.4c-10.6,9.3 -25,14.5 -40.4,14.5c-18.06,0 -37,-7.35 -48.18,-22.94c10.76,17.66 31,25.94 50.18,25.94c15.4,0 29.8,-5.2 40.4,-14.5c11.5,-10.2 17.6,-24.5 17.6,-41.4c0,-12.74 -3.47,-24.06 -10.11,-33.23z" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M38.77,91.57l6.13,5.73l9.5,-9.2l9.6,9.2l9.5,-9.2l9.6,9.2l6.23,-5.83"
|
||||
android:strokeWidth="8"
|
||||
android:strokeColor="#35220b"
|
||||
android:strokeLineCap="round"
|
||||
android:strokeLineJoin="round" />
|
||||
<path
|
||||
android:fillColor="#422b0d"
|
||||
android:pathData="M32.2,69.1l12.2,-2.4l-12.5,-5.2a0.762,0.762 0,0 0,-0.4 -0.2c-2.6,-1.6 -3.1,-4.9 -0.7,-6.9a5.989,5.989 0,0 1,6.9 -0.3c5,3 16.7,10.2 21.3,13c0.51,0.22 0.74,0.81 0.52,1.31c-0.13,0.3 -0.4,0.52 -0.72,0.59l-22.9,8.6c-0.2,0.1 -0.3,0.1 -0.5,0.2c-3,0.8 -6.3,-0.9 -6.8,-3.8c-0.5,-2.2 1.2,-4.3 3.6,-4.9z" />
|
||||
<path
|
||||
android:fillColor="#422b0d"
|
||||
android:pathData="M95.8,68.8l-12.2,-2.4l12.6,-5.2c0.11,-0.11 0.25,-0.17 0.4,-0.2c2.6,-1.6 3.1,-4.9 0.7,-6.9a5.989,5.989 0,0 0,-6.9 -0.3c-5,3 -16.7,10.2 -21.3,13c-0.51,0.22 -0.74,0.81 -0.52,1.31c0.13,0.3 0.4,0.52 0.72,0.59l22.9,8.6c0.2,0.1 0.3,0.1 0.5,0.2c3,0.8 6.3,-0.9 6.8,-3.8c0.4,-2.2 -1.3,-4.2 -3.7,-4.9z" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M0,0h128v128h-128z" />
|
||||
</vector>
|
||||
@ -0,0 +1,47 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:aapt="http://schemas.android.com/aapt"
|
||||
android:width="128dp"
|
||||
android:height="128dp"
|
||||
android:viewportWidth="128"
|
||||
android:viewportHeight="128">
|
||||
<path android:pathData="M63.6,118.8c-27.9,0 -58,-17.5 -58,-55.9S35.7,7 63.6,7c15.5,0 29.8,5.1 40.4,14.4c11.5,10.2 17.6,24.6 17.6,41.5s-6.1,31.2 -17.6,41.4c-10.6,9.3 -25,14.5 -40.4,14.5z">
|
||||
<aapt:attr name="android:fillColor">
|
||||
<gradient
|
||||
android:centerX="63.6"
|
||||
android:centerY="62.9"
|
||||
android:gradientRadius="56.96"
|
||||
android:type="radial">
|
||||
<item
|
||||
android:color="#FFFDE030"
|
||||
android:offset="0.5" />
|
||||
<item
|
||||
android:color="#FFF7C02B"
|
||||
android:offset="0.92" />
|
||||
<item
|
||||
android:color="#FFF4A223"
|
||||
android:offset="1" />
|
||||
</gradient>
|
||||
</aapt:attr>
|
||||
</path>
|
||||
<path
|
||||
android:fillColor="#eb8f00"
|
||||
android:pathData="M111.49,29.67c5.33,8.6 8.11,18.84 8.11,30.23c0,16.9 -6.1,31.2 -17.6,41.4c-10.6,9.3 -25,14.5 -40.4,14.5c-18.06,0 -37,-7.35 -48.18,-22.94c10.76,17.66 31,25.94 50.18,25.94c15.4,0 29.8,-5.2 40.4,-14.5c11.5,-10.2 17.6,-24.5 17.6,-41.4c0,-12.74 -3.47,-24.06 -10.11,-33.23z" />
|
||||
<path
|
||||
android:fillColor="#422b0d"
|
||||
android:pathData="M73.71,74a3.342,3.342 0,0 1,1.86 -5c3.38,-1.33 6.98,-2.05 10.61,-2.12c3.63,0.06 7.23,0.74 10.64,2a3.4,3.4 0,0 1,2.33 4.22c-0.08,0.27 -0.19,0.54 -0.33,0.78a4.001,4.001 0,0 1,-4.66 1.54c-2.51,-0.96 -5.16,-1.5 -7.85,-1.6c-2.7,0.09 -5.37,0.63 -7.89,1.6c-1.71,0.7 -3.67,0.11 -4.71,-1.42z" />
|
||||
<path
|
||||
android:fillColor="#422b0d"
|
||||
android:pathData="M29.11,74a3.343,3.343 0,0 1,1.05 -4.62c0.26,-0.16 0.54,-0.29 0.84,-0.38a30.4,30.4 0,0 1,10.62 -2.12c3.63,0.06 7.23,0.74 10.63,2c1.81,0.53 2.85,2.43 2.33,4.24c-0.08,0.27 -0.19,0.52 -0.33,0.76a3.998,3.998 0,0 1,-4.67 1.54c-2.51,-0.96 -5.16,-1.5 -7.85,-1.6c-2.7,0.09 -5.37,0.63 -7.89,1.6c-1.71,0.71 -3.69,0.12 -4.73,-1.42z" />
|
||||
<path
|
||||
android:fillColor="#422b0d"
|
||||
android:pathData="M64,87.2c10.8,0 17.8,7.9 19.7,11.6c0.7,1.4 0.7,2.6 0.1,3.1c-0.64,0.4 -1.46,0.4 -2.1,0c-0.32,-0.13 -0.62,-0.3 -0.9,-0.5A29.3,29.3 0,0 0,64 95.9c-6.01,0.08 -11.87,1.96 -16.8,5.4c-0.28,0.2 -0.58,0.37 -0.9,0.5c-0.64,0.4 -1.46,0.4 -2.1,0c-0.6,-0.6 -0.6,-1.7 0.1,-3.1c1.9,-3.6 8.9,-11.5 19.7,-11.5z" />
|
||||
<path
|
||||
android:fillColor="#44b3e6"
|
||||
android:pathData="M29.66,56.52c-8.47,0 -15,-8.2 -15,-15.23c0,-4.95 2.21,-10.68 5.33,-18.62c0.39,-1.17 0.91,-2.34 1.43,-3.65c1.49,-3.72 2.81,-7.75 4.81,-11.24a3.516,3.516 0,0 1,6.14 0c1.86,3.43 3.13,7.14 5.07,11.47c5.47,12.24 7,17.19 7,22.14c0.19,6.93 -6.44,15.13 -14.78,15.13z" />
|
||||
<path
|
||||
android:fillColor="#81d4fa"
|
||||
android:pathData="M38.81,47.13c-1.91,3 -6.25,2.4 -6.25,-2.51c0,-3.14 0.64,-19.25 3.33,-17c4.39,3.67 5.64,15.38 2.92,19.51z" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M0,0h128v128h-128z" />
|
||||
</vector>
|
||||
131
app/src/main/res/drawable/lose_emoji_exploding_head.xml
Normal file
@ -0,0 +1,131 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:aapt="http://schemas.android.com/aapt"
|
||||
android:width="128dp"
|
||||
android:height="128dp"
|
||||
android:viewportWidth="128"
|
||||
android:viewportHeight="128">
|
||||
<path
|
||||
android:fillColor="#f15a24"
|
||||
android:pathData="M103.06,60.5c7.19,-3.2 21.36,-9.27 21.36,-9.27s-13.29,-5.46 -20.26,-8.47c3.03,-2.47 17.55,-9.52 17.55,-9.52l-22.15,1.83l12.22,-29.53S92.54,20.15 85.07,22.02c0.03,-3.43 0.1,-12.51 0.1,-12.51s-6.81,7.46 -10.19,9.97C71.05,13.65 63.54,4.72 63.54,4.72s-6.71,8.21 -10.41,13.87C50.09,16.13 41.94,4.58 41.94,4.58s1.88,14.07 1.72,17.74c-7.8,-1.87 -22.21,-8.37 -22.21,-8.37S27.69,25.79 30,31.86c-4.23,-0.03 -18.39,-0.8 -23.45,-1.11c4.09,3.1 21.17,15.44 21.17,15.44L3.58,50.87s17.17,4.15 24.14,7.16c-1.7,1.38 -6.13,4.93 -9.69,7.77h91.4c-2.31,-1.83 -4.44,-3.59 -6.37,-5.3z" />
|
||||
<path android:pathData="M48.28,45.33h31.67v20.48H48.28z">
|
||||
<aapt:attr name="android:fillColor">
|
||||
<gradient
|
||||
android:endX="64.117"
|
||||
android:endY="67.834"
|
||||
android:startX="64.117"
|
||||
android:startY="60.706"
|
||||
android:type="linear">
|
||||
<item
|
||||
android:color="#FF78C0E8"
|
||||
android:offset="0" />
|
||||
<item
|
||||
android:color="#FF31A0D6"
|
||||
android:offset="1" />
|
||||
</gradient>
|
||||
</aapt:attr>
|
||||
</path>
|
||||
<path
|
||||
android:fillColor="#ffea5c"
|
||||
android:pathData="M120.13,54.86c0.19,-0.5 0.3,-1.03 0.3,-1.59c0,-2.5 -2.03,-4.53 -4.53,-4.53c-2.07,0 -3.8,1.4 -4.34,3.3a4.51,4.51 0,0 0,-2.99 4.24c0,2.5 2.03,4.53 4.53,4.53c0.29,0 0.57,-0.03 0.85,-0.09c0.62,0.32 1.31,0.52 2.06,0.52c2.5,0 4.53,-2.03 4.53,-4.53c0,-0.65 -0.16,-1.28 -0.41,-1.85z" />
|
||||
<path
|
||||
android:fillColor="#5c5cff"
|
||||
android:pathData="M103.31,6.31a4.197,4.197 0,0 0,-2.44 5.42c0.49,1.29 1.54,2.18 2.77,2.54A4.203,4.203 0,0 0,109 16.6a4.197,4.197 0,0 0,2.44 -5.42c-0.49,-1.29 -1.54,-2.18 -2.77,-2.54c-0.87,-2.09 -3.23,-3.14 -5.36,-2.33z" />
|
||||
<path
|
||||
android:fillColor="#45f9ff"
|
||||
android:pathData="M19.42,49.18a3.45,3.45 0,1 0,-6.84 -0.65c0,0.52 0.12,1 0.32,1.44c-2,0.1 -3.64,1.69 -3.76,3.74a3.98,3.98 0,0 0,3.74 4.2c1.35,0.08 2.58,-0.53 3.36,-1.52c0.53,0.32 1.15,0.52 1.81,0.56a3.98,3.98 0,0 0,4.2 -3.74c0.11,-1.87 -1.1,-3.52 -2.83,-4.03z" />
|
||||
<path
|
||||
android:fillColor="#4bff17"
|
||||
android:pathData="M9.87,17a5,4.5 0,1 0,10 0a5,4.5 0,1 0,-10 0z" />
|
||||
<path
|
||||
android:fillColor="#ff17c8"
|
||||
android:pathData="M108.28,24.83a5,4.5 0,1 0,10 0a5,4.5 0,1 0,-10 0z" />
|
||||
<path
|
||||
android:fillColor="#d2edf7"
|
||||
android:pathData="M99.74,31.65c-0.86,-0.48 -1.11,-1.62 -0.76,-2.54c0.53,-1.38 0.86,-2.85 0.94,-4.37c0.46,-8.78 -7.23,-15.98 -17.13,-15.88c-3.49,0.03 -6.74,0.99 -9.49,2.59c-2.29,-4.48 -7.2,-7.56 -12.89,-7.5c-5.9,0.07 -10.88,3.5 -12.94,8.28c-1.49,-0.48 -3.07,-0.74 -4.7,-0.73c-8.02,0.07 -13.82,4.78 -13.24,13.57c0.1,1.49 1.28,4.3 1.28,4.3s-2.41,0.59 -4.39,3.93c-1.61,2.71 -1.78,7.08 -0.38,9.96c2.19,4.51 8.27,6.63 12.79,4.46c0.64,-0.31 1.37,-0.7 2.03,-0.43c0.33,0.14 1.71,5.2 14.13,7.78c7.16,1.49 15.56,-3.76 16.03,-3.77c0.54,-0.01 1.02,0.32 1.47,0.62c0,0 3.32,3.81 10.75,2.03c7.01,-1.67 7.69,-6.43 8.29,-6.62c0.48,-0.15 8.7,2.43 12.17,-5.44c1.52,-3.52 -1.07,-8.63 -3.96,-10.24z" />
|
||||
<path
|
||||
android:fillColor="#92cbeb"
|
||||
android:pathData="M29.45,24.11c0.06,1.25 0.35,4.6 1.88,5.54c1.03,0.63 1.95,0.93 2.76,1.03c1.57,0.19 2.52,-1.75 1.46,-2.92c-1.16,-1.27 -2.41,-3.45 -2.89,-7.1c-0.69,-5.15 3.36,-7.74 3.36,-7.74s-6.96,2.82 -6.57,11.19z" />
|
||||
<path
|
||||
android:fillColor="#78c0e8"
|
||||
android:pathData="M103.66,41.91c1,-2.26 0.66,-5.45 -1.16,-7.49c0,0 1.11,2.89 -0.29,5.76c-1.42,2.91 -4.43,5.63 -7.57,4.88c-1.96,-0.47 -0.04,-3.69 -2.8,-8.43c0.14,4.47 0.05,14.6 -13.07,15.44c-2.4,0.15 -8.15,-1.92 -8.49,-5.4c-0.76,-7.58 6.44,-6.53 7.47,-6.37c2.47,0.37 5.17,-0.7 5.58,-2.65c0.37,-1.77 -0.49,-2.47 -1.3,-3.17c-2.32,-1.98 -5.97,-1.61 -8.55,0.03c-3.92,2.5 -5.73,9.12 -8.84,12.33c-3.63,3.74 -9.51,4.64 -14.52,3.2c-8.58,-2.47 -11.26,-13.41 -11.26,-13.41c-1.12,2.86 -0.13,6.62 0.56,8.3c-8.55,1.77 -12.82,-2.68 -14.14,-3.98c0.14,0.8 0.37,1.59 0.73,2.33c2.19,4.51 8.27,6.63 12.79,4.46c0.64,-0.31 1.37,-0.7 2.03,-0.43c0.33,0.14 1.71,5.2 14.13,7.78c7.16,1.49 15.56,-3.76 16.03,-3.77c0.54,-0.01 1.02,0.32 1.47,0.62c0,0 3.32,3.81 10.75,2.03c7.01,-1.67 7.69,-6.43 8.29,-6.62c0.48,-0.16 8.7,2.42 12.16,-5.44z" />
|
||||
<path
|
||||
android:fillColor="#92cbeb"
|
||||
android:pathData="M67.06,5.42s1.33,1.9 1.6,2.89c1.05,3.87 -0.93,6.44 -1.5,7.49c-0.3,0.56 -0.57,1.21 -0.36,1.8c0.23,0.64 0.93,0.98 1.59,1.08c1.78,0.29 3.63,-0.69 4.62,-2.19c0.97,-1.5 2.74,-7.52 -5.95,-11.07z" />
|
||||
<path
|
||||
android:fillColor="#92cbeb"
|
||||
android:pathData="M98.98,29.11c0.53,-1.38 0.86,-2.85 0.94,-4.37c0.18,-3.38 -0.86,-6.51 -2.76,-9.1c0.95,1.73 1.19,3.88 0.79,5.84c-0.55,2.67 -2.26,5 -4.24,6.87c-2.41,2.27 -0.7,3.32 0.69,3.32c3.35,-0.01 4.39,-2.07 4.58,-2.56z" />
|
||||
<path
|
||||
android:fillColor="#039be5"
|
||||
android:pathData="M70.5,65.8v-6.72c0,-1.26 -1.12,-2.28 -2.5,-2.28s-2.5,1.02 -2.5,2.28v6.72h5z" />
|
||||
<path
|
||||
android:fillColor="#039be5"
|
||||
android:pathData="M60.62,65.8V55.56c0,-0.83 -0.67,-1.5 -1.5,-1.5s-1.5,0.67 -1.5,1.5V65.8h3z" />
|
||||
<path android:pathData="M63.72,118.8c15.4,0 29.8,-5.2 40.4,-14.5c10.83,-9.61 16.87,-22.86 17.53,-38.5H5.79c1.48,36.38 30.74,53 57.93,53z">
|
||||
<aapt:attr name="android:fillColor">
|
||||
<gradient
|
||||
android:centerX="63.72"
|
||||
android:centerY="62.9"
|
||||
android:gradientRadius="56.957"
|
||||
android:type="radial">
|
||||
<item
|
||||
android:color="#FFFDE030"
|
||||
android:offset="0.5" />
|
||||
<item
|
||||
android:color="#FFF7C02B"
|
||||
android:offset="0.919" />
|
||||
<item
|
||||
android:color="#FFF4A223"
|
||||
android:offset="1" />
|
||||
</gradient>
|
||||
</aapt:attr>
|
||||
</path>
|
||||
<path
|
||||
android:fillColor="#eb8f00"
|
||||
android:pathData="M13.54,92.86c0.15,0.25 0.33,0.48 0.49,0.73c-0.1,-0.17 -0.21,-0.34 -0.31,-0.5c-0.06,-0.08 -0.13,-0.15 -0.18,-0.23z" />
|
||||
<path
|
||||
android:fillColor="#eb8f00"
|
||||
android:pathData="M119.45,65.8c-1.27,14.33 -7.2,26.51 -17.34,35.5c-10.6,9.3 -25,14.5 -40.4,14.5c-17.97,0 -36.84,-7.28 -48,-22.71c0.1,0.17 0.2,0.34 0.31,0.5c0.35,0.55 0.7,1.08 1.07,1.61c0.27,0.39 0.53,0.78 0.81,1.16c0.59,0.8 1.2,1.58 1.83,2.34c0.3,0.36 0.61,0.7 0.91,1.05c0.43,0.49 0.87,0.97 1.31,1.44a45.755,45.755 0,0 0,2.92 2.84c0.33,0.3 0.67,0.58 1,0.87c0.57,0.48 1.14,0.95 1.72,1.41c0.34,0.27 0.69,0.53 1.04,0.79c0.59,0.44 1.2,0.86 1.81,1.28c0.28,0.19 0.56,0.39 0.84,0.58c0.85,0.55 1.71,1.08 2.59,1.58c0.33,0.19 0.67,0.37 1,0.55c0.65,0.36 1.31,0.7 1.97,1.04c0.32,0.16 0.65,0.33 0.97,0.48c0.93,0.45 1.87,0.87 2.83,1.27c0.25,0.1 0.5,0.19 0.74,0.29c0.77,0.31 1.55,0.6 2.34,0.88c0.33,0.12 0.67,0.23 1,0.35c0.87,0.29 1.75,0.57 2.63,0.82c0.16,0.05 0.32,0.1 0.47,0.14c1.03,0.29 2.06,0.54 3.1,0.78c0.31,0.07 0.61,0.13 0.92,0.2c0.83,0.18 1.66,0.33 2.49,0.48c0.27,0.05 0.53,0.1 0.79,0.14c1.06,0.17 2.12,0.31 3.18,0.43c0.23,0.03 0.46,0.04 0.68,0.07c0.87,0.09 1.74,0.16 2.61,0.21c0.3,0.02 0.6,0.04 0.89,0.05c1.07,0.05 2.15,0.09 3.22,0.09c15.4,0 29.8,-5.2 40.4,-14.5c0.7,-0.62 1.38,-1.26 2.03,-1.9c0.22,-0.22 0.44,-0.45 0.66,-0.68c0.42,-0.43 0.85,-0.87 1.26,-1.31c0.26,-0.28 0.5,-0.57 0.75,-0.86c0.35,-0.4 0.7,-0.8 1.04,-1.22c0.26,-0.32 0.51,-0.65 0.76,-0.97c0.31,-0.39 0.61,-0.78 0.91,-1.19c0.25,-0.35 0.5,-0.71 0.74,-1.06c0.27,-0.39 0.54,-0.78 0.8,-1.18c0.24,-0.38 0.48,-0.76 0.71,-1.14c0.24,-0.39 0.48,-0.78 0.71,-1.18c0.23,-0.4 0.45,-0.81 0.67,-1.21c0.21,-0.39 0.42,-0.78 0.62,-1.18c0.22,-0.42 0.42,-0.85 0.63,-1.29c0.18,-0.39 0.36,-0.78 0.54,-1.18c0.2,-0.45 0.39,-0.9 0.58,-1.36c0.16,-0.39 0.31,-0.78 0.46,-1.17c0.18,-0.47 0.36,-0.95 0.52,-1.43c0.13,-0.38 0.26,-0.77 0.39,-1.16c0.16,-0.5 0.32,-1 0.47,-1.51c0.11,-0.38 0.21,-0.76 0.32,-1.15c0.14,-0.53 0.28,-1.06 0.41,-1.59c0.09,-0.37 0.17,-0.74 0.25,-1.12c0.12,-0.56 0.24,-1.12 0.35,-1.69c0.07,-0.35 0.12,-0.71 0.18,-1.06c0.1,-0.6 0.2,-1.2 0.28,-1.81c0.04,-0.32 0.08,-0.64 0.11,-0.97c0.08,-0.65 0.16,-1.3 0.22,-1.96c0.02,-0.25 0.03,-0.5 0.05,-0.75c0.06,-0.74 0.1,-1.49 0.14,-2.24h-2.21z" />
|
||||
<path
|
||||
android:fillColor="#eb8f00"
|
||||
android:pathData="M119.45,65.8c-1.27,14.33 -7.2,26.51 -17.34,35.5c-10.6,9.3 -25,14.5 -40.4,14.5c-17.97,0 -36.84,-7.28 -48,-22.71c0.1,0.17 0.2,0.34 0.31,0.5c0.35,0.55 0.7,1.08 1.07,1.61c0.27,0.39 0.53,0.78 0.81,1.16c0.59,0.8 1.2,1.58 1.83,2.34c0.3,0.36 0.61,0.7 0.91,1.05c0.43,0.49 0.87,0.97 1.31,1.44a45.755,45.755 0,0 0,2.92 2.84c0.33,0.3 0.67,0.58 1,0.87c0.57,0.48 1.14,0.95 1.72,1.41c0.34,0.27 0.69,0.53 1.04,0.79c0.59,0.44 1.2,0.86 1.81,1.28c0.28,0.19 0.56,0.39 0.84,0.58c0.85,0.55 1.71,1.08 2.59,1.58c0.33,0.19 0.67,0.37 1,0.55c0.65,0.36 1.31,0.7 1.97,1.04c0.32,0.16 0.65,0.33 0.97,0.48c0.93,0.45 1.87,0.87 2.83,1.27c0.25,0.1 0.5,0.19 0.74,0.29c0.77,0.31 1.55,0.6 2.34,0.88c0.33,0.12 0.67,0.23 1,0.35c0.87,0.29 1.75,0.57 2.63,0.82c0.16,0.05 0.32,0.1 0.47,0.14c1.03,0.29 2.06,0.54 3.1,0.78c0.31,0.07 0.61,0.13 0.92,0.2c0.83,0.18 1.66,0.33 2.49,0.48c0.27,0.05 0.53,0.1 0.79,0.14c1.06,0.17 2.12,0.31 3.18,0.43c0.23,0.03 0.46,0.04 0.68,0.07c0.87,0.09 1.74,0.16 2.61,0.21c0.3,0.02 0.6,0.04 0.89,0.05c1.07,0.05 2.15,0.09 3.22,0.09c15.4,0 29.8,-5.2 40.4,-14.5c0.7,-0.62 1.38,-1.26 2.03,-1.9c0.22,-0.22 0.44,-0.45 0.66,-0.68c0.42,-0.43 0.85,-0.87 1.26,-1.31c0.26,-0.28 0.5,-0.57 0.75,-0.86c0.35,-0.4 0.7,-0.8 1.04,-1.22c0.26,-0.32 0.51,-0.65 0.76,-0.97c0.31,-0.39 0.61,-0.78 0.91,-1.19c0.25,-0.35 0.5,-0.71 0.74,-1.06c0.27,-0.39 0.54,-0.78 0.8,-1.18c0.24,-0.38 0.48,-0.76 0.71,-1.14c0.24,-0.39 0.48,-0.78 0.71,-1.18c0.23,-0.4 0.45,-0.81 0.67,-1.21c0.21,-0.39 0.42,-0.78 0.62,-1.18c0.22,-0.42 0.42,-0.85 0.63,-1.29c0.18,-0.39 0.36,-0.78 0.54,-1.18c0.2,-0.45 0.39,-0.9 0.58,-1.36c0.16,-0.39 0.31,-0.78 0.46,-1.17c0.18,-0.47 0.36,-0.95 0.52,-1.43c0.13,-0.38 0.26,-0.77 0.39,-1.16c0.16,-0.5 0.32,-1 0.47,-1.51c0.11,-0.38 0.21,-0.76 0.32,-1.15c0.14,-0.53 0.28,-1.06 0.41,-1.59c0.09,-0.37 0.17,-0.74 0.25,-1.12c0.12,-0.56 0.24,-1.12 0.35,-1.69c0.07,-0.35 0.12,-0.71 0.18,-1.06c0.1,-0.6 0.2,-1.2 0.28,-1.81c0.04,-0.32 0.08,-0.64 0.11,-0.97c0.08,-0.65 0.16,-1.3 0.22,-1.96c0.02,-0.25 0.03,-0.5 0.05,-0.75c0.06,-0.74 0.1,-1.49 0.14,-2.24h-2.21z" />
|
||||
<path
|
||||
android:fillColor="#eb8f00"
|
||||
android:pathData="M121.51,68.04c0.06,-0.74 0.11,-1.49 0.14,-2.24h-0.01c-0.03,0.75 -0.08,1.5 -0.13,2.24z" />
|
||||
<path android:pathData="M121.51,68.04c0.06,-0.74 0.11,-1.49 0.14,-2.24h-0.01c-0.03,0.75 -0.08,1.5 -0.13,2.24z">
|
||||
<aapt:attr name="android:fillColor">
|
||||
<gradient
|
||||
android:centerX="63.72"
|
||||
android:centerY="62.9"
|
||||
android:gradientRadius="56.957"
|
||||
android:type="radial">
|
||||
<item
|
||||
android:color="#FFFDE030"
|
||||
android:offset="0.5" />
|
||||
<item
|
||||
android:color="#FFF7C02B"
|
||||
android:offset="0.919" />
|
||||
<item
|
||||
android:color="#FFF4A223"
|
||||
android:offset="1" />
|
||||
</gradient>
|
||||
</aapt:attr>
|
||||
</path>
|
||||
<path
|
||||
android:fillColor="#422b0d"
|
||||
android:pathData="M77.93,104.94c0,5.6 -6.19,8.89 -13.82,8.89s-13.82,-3.29 -13.82,-8.89s6.19,-11.69 13.82,-11.69s13.82,6.09 13.82,11.69z" />
|
||||
<path
|
||||
android:fillColor="#fff"
|
||||
android:pathData="M41.6,75.13m-15.51,0a15.51,15.51 0,1 1,31.02 0a15.51,15.51 0,1 1,-31.02 0" />
|
||||
<path
|
||||
android:fillColor="#422b0d"
|
||||
android:pathData="M34.93,75.13a6.67,6.77 0,1 0,13.34 0a6.67,6.77 0,1 0,-13.34 0z" />
|
||||
<path
|
||||
android:fillColor="#fff"
|
||||
android:pathData="M86.6,75.13m-15.51,0a15.51,15.51 0,1 1,31.02 0a15.51,15.51 0,1 1,-31.02 0" />
|
||||
<path
|
||||
android:fillColor="#422b0d"
|
||||
android:pathData="M79.95,75.21a6.67,6.77 0,1 0,13.34 0a6.67,6.77 0,1 0,-13.34 0z" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M0,0h128v128h-128z" />
|
||||
</vector>
|
||||
@ -0,0 +1,85 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:aapt="http://schemas.android.com/aapt"
|
||||
android:width="128dp"
|
||||
android:height="128dp"
|
||||
android:viewportWidth="128"
|
||||
android:viewportHeight="128">
|
||||
<path android:pathData="M63.6,118.8c-27.9,0 -58,-17.5 -58,-55.9S35.7,7 63.6,7c15.5,0 29.8,5.1 40.4,14.4c11.5,10.2 17.6,24.6 17.6,41.5s-6.1,31.2 -17.6,41.4c-10.6,9.3 -25,14.5 -40.4,14.5z">
|
||||
<aapt:attr name="android:fillColor">
|
||||
<gradient
|
||||
android:centerX="63.6"
|
||||
android:centerY="62.9"
|
||||
android:gradientRadius="56.96"
|
||||
android:type="radial">
|
||||
<item
|
||||
android:color="#FFFDE030"
|
||||
android:offset="0.5" />
|
||||
<item
|
||||
android:color="#FFF7C02B"
|
||||
android:offset="0.919" />
|
||||
<item
|
||||
android:color="#FFF4A223"
|
||||
android:offset="1" />
|
||||
</gradient>
|
||||
</aapt:attr>
|
||||
</path>
|
||||
<path
|
||||
android:fillColor="#eb8f00"
|
||||
android:pathData="M111.49,29.67c5.33,8.6 8.11,18.84 8.11,30.23c0,16.9 -6.1,31.2 -17.6,41.4c-10.6,9.3 -25,14.5 -40.4,14.5c-18.06,0 -37.04,-7.35 -48.18,-22.94c10.76,17.66 30.99,25.94 50.18,25.94c15.4,0 29.8,-5.2 40.4,-14.5c11.5,-10.2 17.6,-24.5 17.6,-41.4c0,-12.74 -3.47,-24.06 -10.11,-33.23z" />
|
||||
<path
|
||||
android:fillColor="#422b0d"
|
||||
android:pathData="M86.11,100.49c-0.32,-0.06 -0.62,-0.21 -0.87,-0.43c-4.26,-3.68 -9.59,-6.3 -15.51,-7.63c-5.91,-1.33 -11.85,-1.26 -17.28,0.24c-0.32,0.09 -0.66,0.09 -0.97,0.01c-0.69,-0.18 -1.23,-0.75 -1.36,-1.46c-0.13,-0.69 0.16,-1.38 0.75,-1.79c5.92,-4.08 13.28,-5.47 20.4,-3.86c7.12,1.6 13.18,6.01 16.77,12.24c0.36,0.62 0.33,1.37 -0.09,1.94c-0.41,0.59 -1.14,0.87 -1.84,0.74z" />
|
||||
<path
|
||||
android:fillColor="#422b0d"
|
||||
android:pathData="M44.04,54.94c-4.19,0 -8,3.54 -8,9.42c0,5.87 3.81,9.42 8,9.42c4.19,0 8,-3.54 8,-9.42s-3.8,-9.42 -8,-9.42z" />
|
||||
<path
|
||||
android:fillColor="#896024"
|
||||
android:pathData="M43.65,58.87c-1.03,-0.72 -2.58,-0.49 -3.58,0.95c-1,1.45 -0.67,2.97 0.36,3.69c1.03,0.72 2.58,0.49 3.58,-0.95s0.68,-2.97 -0.36,-3.69z" />
|
||||
<path
|
||||
android:fillColor="#422b0d"
|
||||
android:pathData="M82.4,54.94c-4.19,0 -8,3.54 -8,9.42c0,5.87 3.81,9.42 8,9.42c4.19,0 8,-3.54 8,-9.42s-3.81,-9.42 -8,-9.42z" />
|
||||
<path
|
||||
android:fillColor="#896024"
|
||||
android:pathData="M82.01,58.87c-1.03,-0.72 -2.58,-0.49 -3.58,0.95c-1,1.45 -0.67,2.97 0.36,3.69c1.03,0.72 2.58,0.49 3.58,-0.95c1.01,-1.45 0.67,-2.97 -0.36,-3.69z" />
|
||||
<path
|
||||
android:fillColor="#f5f5f5"
|
||||
android:pathData="M104,21.4c-5.5,-4.83 -12.01,-8.51 -19.16,-10.95l-1.89,1.04l-23.98,11.43l-40.51,5.51l-2.1,0.23C9.74,37.32 5.6,48.67 5.6,62.9c0,5.42 0.62,10.41 1.73,15l59.63,-33.03l50.26,-4.97c-2.96,-7.09 -7.4,-13.33 -13.22,-18.5z" />
|
||||
<path
|
||||
android:fillColor="#808080"
|
||||
android:pathData="M7.69,79.4l-0.56,-2.18s31.83,-24.86 63.76,-34.46l5.6,0.85C44.37,53.8 8.02,79.16 7.69,79.4z" />
|
||||
<path android:pathData="M62.24,21.36l-5.79,2.76l5.79,-2.76z">
|
||||
<aapt:attr name="android:fillColor">
|
||||
<gradient
|
||||
android:endX="58.389"
|
||||
android:endY="14.954"
|
||||
android:startX="59.569"
|
||||
android:startY="24.57"
|
||||
android:type="linear">
|
||||
<item
|
||||
android:color="#FFB3B3B3"
|
||||
android:offset="0.065" />
|
||||
<item
|
||||
android:color="#BFBDBDBD"
|
||||
android:offset="0.266" />
|
||||
<item
|
||||
android:color="#52D9D9D9"
|
||||
android:offset="0.611" />
|
||||
<item
|
||||
android:color="#00F2F2F2"
|
||||
android:offset="0.871" />
|
||||
</gradient>
|
||||
</aapt:attr>
|
||||
</path>
|
||||
<path
|
||||
android:fillColor="#808080"
|
||||
android:pathData="M84.84,10.45c3.52,1.05 6.94,2.46 10.22,4.15c3.28,1.69 6.44,3.67 9.29,6.12c2.8,2.47 5.3,5.29 7.46,8.34c1.08,1.53 2.08,3.11 3,4.74c0.92,1.64 1.76,3.28 2.51,5.08l0.62,1.51l-1.68,0.17c-9.13,0.95 -18.27,1.87 -27.41,2.7c-4.57,0.44 -9.14,0.84 -13.71,1.23s-9.15,0.81 -13.72,1.15c-9.13,0.69 -18.26,1.49 -27.39,2.37l-13.69,1.38c-4.56,0.48 -9.12,1.02 -13.68,1.56c4.48,-1.01 9.01,-1.82 13.53,-2.63c4.52,-0.81 9.06,-1.53 13.61,-2.19c9.1,-1.32 18.23,-2.39 27.38,-3.26l13.7,-1.32c4.57,-0.43 9.13,-0.86 13.71,-1.24c9.14,-0.82 18.28,-1.54 27.43,-2.25l-1.06,1.68c-1.23,-3.26 -2.94,-6.53 -4.88,-9.53c-1.93,-3.03 -4.18,-5.88 -6.75,-8.4c-2.57,-2.51 -5.54,-4.65 -8.67,-6.51a67.74,67.74 0,0 0,-4.82 -2.6c-1.63,-0.81 -3.29,-1.58 -5,-2.25z" />
|
||||
<path
|
||||
android:fillColor="#808080"
|
||||
android:pathData="M104,21.45c-5.2,0.31 -10.35,0.45 -15.51,0.64c-2.58,0.12 -5.16,0.08 -7.74,0.22l-7.75,0.41c-5.16,0.27 -10.33,0.64 -15.48,1.09c-5.16,0.4 -10.31,0.91 -15.47,1.46l-0.02,-0.1c10.26,-1.48 20.57,-2.53 30.9,-3.27c5.17,-0.35 10.34,-0.65 15.52,-0.77c5.18,-0.1 10.37,-0.1 15.54,0.23l0.01,0.09z" />
|
||||
<path
|
||||
android:fillColor="#808080"
|
||||
android:pathData="M16.36,28.65c-2.02,3.99 -3.86,7.99 -5.4,12.07c-0.75,2.04 -1.45,4.09 -1.97,6.18c-0.58,2.08 -0.94,4.15 -1.16,6.29c-0.47,4.36 -0.85,8.72 -0.97,13.09c-0.05,2.18 -0.08,4.37 0.05,6.56c0.1,2.19 0.28,4.38 0.77,6.56c-1.12,-1.96 -1.72,-4.17 -2.23,-6.37c-0.48,-2.21 -0.77,-4.45 -0.93,-6.7c-0.32,-4.5 -0.18,-9.01 0.33,-13.47c0.5,-4.59 1.96,-9.03 3.97,-13.06c2.02,-4.06 4.5,-7.85 7.54,-11.15z" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M0,0h128v128h-128z" />
|
||||
</vector>
|
||||
88
app/src/main/res/drawable/lose_emoji_grimacing_face.xml
Normal file
@ -0,0 +1,88 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:aapt="http://schemas.android.com/aapt"
|
||||
android:width="128dp"
|
||||
android:height="128dp"
|
||||
android:viewportWidth="128"
|
||||
android:viewportHeight="128">
|
||||
<path android:pathData="M63.6,118.8c-27.9,0 -58,-17.5 -58,-55.9S35.7,7 63.6,7c15.5,0 29.8,5.1 40.4,14.4c11.5,10.2 17.6,24.6 17.6,41.5s-6.1,31.2 -17.6,41.4c-10.6,9.3 -25,14.5 -40.4,14.5z">
|
||||
<aapt:attr name="android:fillColor">
|
||||
<gradient
|
||||
android:centerX="63.6"
|
||||
android:centerY="62.9"
|
||||
android:gradientRadius="56.96"
|
||||
android:type="radial">
|
||||
<item
|
||||
android:color="#FFFDE030"
|
||||
android:offset="0.5" />
|
||||
<item
|
||||
android:color="#FFF7C02B"
|
||||
android:offset="0.92" />
|
||||
<item
|
||||
android:color="#FFF4A223"
|
||||
android:offset="1" />
|
||||
</gradient>
|
||||
</aapt:attr>
|
||||
</path>
|
||||
<path android:pathData="M63.6,118.8c-27.9,0 -58,-17.5 -58,-55.9S35.7,7 63.6,7c15.5,0 29.8,5.1 40.4,14.4c11.5,10.2 17.6,24.6 17.6,41.5s-6.1,31.2 -17.6,41.4c-10.6,9.3 -25,14.5 -40.4,14.5z">
|
||||
<aapt:attr name="android:fillColor">
|
||||
<gradient
|
||||
android:endX="63.6"
|
||||
android:endY="7"
|
||||
android:startX="63.6"
|
||||
android:startY="118.8"
|
||||
android:type="linear">
|
||||
<item
|
||||
android:color="#FFF4A223"
|
||||
android:offset="0" />
|
||||
<item
|
||||
android:color="#FFF7C02B"
|
||||
android:offset="0.08" />
|
||||
<item
|
||||
android:color="#00FDE030"
|
||||
android:offset="0.54" />
|
||||
</gradient>
|
||||
</aapt:attr>
|
||||
</path>
|
||||
<path
|
||||
android:fillColor="#eb8f00"
|
||||
android:pathData="M111.49,29.67c5.33,8.6 8.11,18.84 8.11,30.23c0,16.9 -6.1,31.2 -17.6,41.4c-10.6,9.3 -25,14.5 -40.4,14.5c-18.06,0 -37,-7.35 -48.18,-22.94c10.76,17.66 31,25.94 50.18,25.94c15.4,0 29.8,-5.2 40.4,-14.5c11.5,-10.2 17.6,-24.5 17.6,-41.4c0,-12.74 -3.47,-24.06 -10.11,-33.23z" />
|
||||
<path
|
||||
android:fillColor="#422b0d"
|
||||
android:pathData="M44,40.94c-4.19,0 -8,3.54 -8,9.42s3.81,9.41 8,9.41c4.2,0 8,-3.54 8,-9.41s-3.76,-9.42 -8,-9.42z" />
|
||||
<path
|
||||
android:fillColor="#896024"
|
||||
android:pathData="M43.65,44.87a2.874,2.874 0,0 0,-3.82 1.34c-0.53,1.11 -0.29,2.44 0.6,3.3c1.42,0.68 3.13,0.08 3.82,-1.34c0.53,-1.11 0.29,-2.44 -0.6,-3.3z" />
|
||||
<path
|
||||
android:fillColor="#422b0d"
|
||||
android:pathData="M82.4,40.94c-4.19,0 -8,3.54 -8,9.42s3.81,9.41 8,9.41c4.19,0 8,-3.54 8,-9.41s-3.81,-9.42 -8,-9.42z" />
|
||||
<path
|
||||
android:fillColor="#896024"
|
||||
android:pathData="M82,44.87a2.874,2.874 0,0 0,-3.82 1.34c-0.53,1.11 -0.29,2.44 0.6,3.3c1.42,0.68 3.13,0.08 3.82,-1.34c0.53,-1.11 0.29,-2.44 -0.6,-3.3z" />
|
||||
<path
|
||||
android:fillColor="#fff"
|
||||
android:pathData="M39.37,71.1h50.09c6.32,0 11.44,5.12 11.44,11.44v0.01c0,6.32 -5.12,11.44 -11.44,11.44H39.37c-6.32,0 -11.44,-5.12 -11.44,-11.44v-0.01c0,-6.32 5.12,-11.44 11.44,-11.44z" />
|
||||
<path
|
||||
android:fillColor="#b3b3b3"
|
||||
android:pathData="M100.74,80.67H28.1a10.76,10.76 0,0 0,0 4h72.6c0.25,-1.32 0.25,-2.68 0,-4h0.04z" />
|
||||
<path
|
||||
android:fillColor="#b3b3b3"
|
||||
android:pathData="M89.46,71.1h-0.55V94h0.55c0.89,0 1.78,-0.11 2.65,-0.32V71.42c-0.87,-0.21 -1.76,-0.32 -2.65,-0.32z" />
|
||||
<path
|
||||
android:fillColor="#b3b3b3"
|
||||
android:pathData="M62.58,71.1h3.2v22.89h-3.2z" />
|
||||
<path
|
||||
android:fillColor="#b3b3b3"
|
||||
android:pathData="M39.38,71.1c-1.06,0 -2.12,0.15 -3.14,0.45v22c1.02,0.3 2.08,0.45 3.14,0.45h0.06V71.1h-0.06z" />
|
||||
<path
|
||||
android:fillColor="#b3b3b3"
|
||||
android:pathData="M49.41,71.1h3.2v22.89h-3.2z" />
|
||||
<path
|
||||
android:fillColor="#b3b3b3"
|
||||
android:pathData="M75.74,71.1h3.2v22.89h-3.2z" />
|
||||
<path
|
||||
android:fillColor="#eb8f00"
|
||||
android:pathData="M100.91,82.55c-0.29,-3.52 -2.19,-6.7 -5.13,-8.65c-1.39,-0.92 -2.98,-1.49 -4.64,-1.67a50.3,50.3 0,0 0,-5.21 0c-3.59,0.14 -7.17,0.17 -10.75,0.25l-10.76,0.08l-10.75,-0.08c-3.59,-0.08 -7.17,-0.11 -10.76,-0.25a50.3,50.3 0,0 0,-5.21 0c-1.66,0.17 -3.25,0.75 -4.63,1.68a11.498,11.498 0,0 0,-5.14 8.64c-0.29,-3.78 1.31,-7.46 4.27,-9.83c1.51,-1.22 3.29,-2.05 5.19,-2.43l0.72,-0.14l0.73,-0.06c0.5,0 0.94,-0.06 1.39,-0.07l2.68,-0.09c3.59,-0.14 7.17,-0.17 10.76,-0.25l10.75,-0.08l10.76,0.09c3.58,0.08 7.16,0.11 10.75,0.25l2.69,0.08c0.45,0 0.88,0 1.39,0.07l0.72,0.07l0.72,0.14c1.9,0.37 3.68,1.2 5.19,2.42c2.96,2.37 4.56,6.05 4.27,9.83z" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M0,0h128v128h-128z" />
|
||||
</vector>
|
||||
@ -0,0 +1,72 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:aapt="http://schemas.android.com/aapt"
|
||||
android:width="128dp"
|
||||
android:height="128dp"
|
||||
android:viewportWidth="128"
|
||||
android:viewportHeight="128">
|
||||
<path android:pathData="M63.6,118.8c-27.9,0 -58,-17.5 -58,-55.9S35.7,7 63.6,7c15.5,0 29.8,5.1 40.4,14.4c11.5,10.2 17.6,24.6 17.6,41.5s-6.1,31.2 -17.6,41.4c-10.6,9.3 -25,14.5 -40.4,14.5z">
|
||||
<aapt:attr name="android:fillColor">
|
||||
<gradient
|
||||
android:centerX="63.6"
|
||||
android:centerY="62.9"
|
||||
android:gradientRadius="56.96"
|
||||
android:type="radial">
|
||||
<item
|
||||
android:color="#FFFDE030"
|
||||
android:offset="0.5" />
|
||||
<item
|
||||
android:color="#FFF7C02B"
|
||||
android:offset="0.92" />
|
||||
<item
|
||||
android:color="#FFF4A223"
|
||||
android:offset="1" />
|
||||
</gradient>
|
||||
</aapt:attr>
|
||||
</path>
|
||||
<path
|
||||
android:fillColor="#eb8f00"
|
||||
android:pathData="M111.49,29.67c5.33,8.6 8.11,18.84 8.11,30.23c0,16.9 -6.1,31.2 -17.6,41.4c-10.6,9.3 -25,14.5 -40.4,14.5c-18.06,0 -37,-7.35 -48.18,-22.94c10.76,17.66 31,25.94 50.18,25.94c15.4,0 29.8,-5.2 40.4,-14.5c11.5,-10.2 17.6,-24.5 17.6,-41.4c0,-12.74 -3.47,-24.06 -10.11,-33.23z" />
|
||||
<path
|
||||
android:fillColor="#422b0d"
|
||||
android:pathData="M64,87.15c10.82,0 17.83,7.92 19.65,11.57c0.7,1.41 0.74,2.58 0.14,3.13c-0.63,0.41 -1.45,0.41 -2.08,0c-0.31,-0.15 -0.62,-0.32 -0.9,-0.52a28.849,28.849 0,0 0,-33.61 0c-0.28,0.2 -0.58,0.37 -0.9,0.52c-0.63,0.42 -1.45,0.42 -2.08,0c-0.6,-0.55 -0.56,-1.72 0.14,-3.13c1.81,-3.64 8.82,-11.57 19.64,-11.57z" />
|
||||
<path
|
||||
android:fillColor="#422b0d"
|
||||
android:pathData="M27.39,39.77c-2.2,0.39 -2.31,3.59 0.09,3.7c5.3,0.08 10.42,-1.88 14.32,-5.47a17.24,17.24 0,0 0,3.71 -4.49c0.58,-0.83 0.38,-1.97 -0.44,-2.56s-1.97,-0.38 -2.56,0.44l-0.1,0.1c-3.93,4.39 -9.22,7.3 -15.02,8.28z" />
|
||||
<path
|
||||
android:fillColor="#422b0d"
|
||||
android:pathData="M86.12,31.52l-0.1,-0.1a1.841,1.841 0,0 0,-2.56 -0.45a1.83,1.83 0,0 0,-0.44 2.56c0.98,1.69 2.24,3.2 3.73,4.47c3.9,3.59 9.02,5.54 14.32,5.45c2.4,-0.11 2.29,-3.31 0.08,-3.7c-5.8,-0.97 -11.09,-3.87 -15.03,-8.23z" />
|
||||
<path android:pathData="M19.52,107c-8.46,0 -15,-8.21 -15,-15.24c0,-4.94 2.21,-10.67 5.34,-18.61c0.39,-1.17 0.91,-2.35 1.43,-3.65c1.49,-3.72 2.8,-7.75 4.8,-11.24a3.516,3.516 0,0 1,6.14 0c1.86,3.43 3.14,7.14 5.07,11.47c5.47,12.24 7,17.19 7,22.13c0.19,6.97 -6.45,15.14 -14.78,15.14z">
|
||||
<aapt:attr name="android:fillColor">
|
||||
<gradient
|
||||
android:centerX="20.59"
|
||||
android:centerY="62.940308"
|
||||
android:gradientRadius="33.4"
|
||||
android:type="radial">
|
||||
<item
|
||||
android:color="#FF29B6F6"
|
||||
android:offset="0.46" />
|
||||
<item
|
||||
android:color="#FF1E88E5"
|
||||
android:offset="1" />
|
||||
</gradient>
|
||||
</aapt:attr>
|
||||
</path>
|
||||
<path
|
||||
android:fillColor="#81d4fa"
|
||||
android:pathData="M28.67,97.65c-1.91,3 -6.25,2.4 -6.25,-2.51c0,-3.14 0.64,-19.26 3.34,-17c4.38,3.67 5.63,15.33 2.91,19.51z" />
|
||||
<path
|
||||
android:fillColor="#422b0d"
|
||||
android:pathData="M44.67,54.94c-4.19,0 -8,3.54 -8,9.42s3.81,9.41 8,9.41c4.19,0 8,-3.54 8,-9.41s-3.81,-9.42 -8,-9.42z" />
|
||||
<path
|
||||
android:fillColor="#896024"
|
||||
android:pathData="M44.28,58.87a2.874,2.874 0,0 0,-3.82 1.34c-0.53,1.11 -0.29,2.44 0.6,3.3c1.42,0.68 3.13,0.08 3.82,-1.34c0.53,-1.11 0.29,-2.44 -0.6,-3.3z" />
|
||||
<path
|
||||
android:fillColor="#422b0d"
|
||||
android:pathData="M83,54.94c-4.19,0 -8,3.54 -8,9.42s3.81,9.41 8,9.41c4.19,0 8,-3.54 8,-9.41s-3.79,-9.42 -8,-9.42z" />
|
||||
<path
|
||||
android:fillColor="#896024"
|
||||
android:pathData="M82.63,58.87a2.874,2.874 0,0 0,-3.82 1.34c-0.53,1.11 -0.29,2.44 0.6,3.3c1.42,0.68 3.13,0.08 3.82,-1.34c0.53,-1.11 0.29,-2.44 -0.6,-3.3z" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M0,0h128v128h-128z" />
|
||||
</vector>
|
||||
9
app/src/main/res/drawable/sel_bg_single.xml
Normal file
@ -0,0 +1,9 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item
|
||||
android:drawable="@android:color/darker_gray"
|
||||
android:state_pressed="true"/>
|
||||
<item
|
||||
android:drawable = "@android:color/white"
|
||||
android:state_pressed="false"/>
|
||||
</selector>
|
||||
@ -0,0 +1,47 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:aapt="http://schemas.android.com/aapt"
|
||||
android:width="128dp"
|
||||
android:height="128dp"
|
||||
android:viewportWidth="128"
|
||||
android:viewportHeight="128">
|
||||
<path android:pathData="M63.6,118.8c-27.9,0 -58,-17.5 -58,-55.9S35.7,7 63.6,7c15.5,0 29.8,5.1 40.4,14.4c11.5,10.2 17.6,24.6 17.6,41.5s-6.1,31.2 -17.6,41.4c-10.6,9.3 -25,14.5 -40.4,14.5z">
|
||||
<aapt:attr name="android:fillColor">
|
||||
<gradient
|
||||
android:centerX="63.6"
|
||||
android:centerY="62.9"
|
||||
android:gradientRadius="56.96"
|
||||
android:type="radial">
|
||||
<item
|
||||
android:color="#FFFDE030"
|
||||
android:offset="0.5" />
|
||||
<item
|
||||
android:color="#FFF7C02B"
|
||||
android:offset="0.92" />
|
||||
<item
|
||||
android:color="#FFF4A223"
|
||||
android:offset="1" />
|
||||
</gradient>
|
||||
</aapt:attr>
|
||||
</path>
|
||||
<path
|
||||
android:fillColor="#eb8f00"
|
||||
android:pathData="M111.49,29.67c5.33,8.6 8.11,18.84 8.11,30.23c0,16.9 -6.1,31.2 -17.6,41.4c-10.6,9.3 -25,14.5 -40.4,14.5c-18.06,0 -37,-7.35 -48.18,-22.94c10.76,17.66 31,25.94 50.18,25.94c15.4,0 29.8,-5.2 40.4,-14.5c11.5,-10.2 17.6,-24.5 17.6,-41.4c0,-12.74 -3.47,-24.06 -10.11,-33.23z" />
|
||||
<path
|
||||
android:fillColor="#fff"
|
||||
android:pathData="M101.7,72.21a5.8,5.8 0,0 0,-7.14 -2.6c-9,2.8 -20,3.83 -31.08,3.84A111.07,111.07 0,0 1,31.89 69a5.8,5.8 0,0 0,-7.14 2.6c-1.36,2.51 -0.37,5.42 0.77,7.93C32,93.65 46.1,102.09 63.4,102.14h0.16c17.3,0 30.94,-7.9 37.37,-22c1.14,-2.51 2.13,-5.42 0.77,-7.93z" />
|
||||
<path
|
||||
android:fillColor="#422b0d"
|
||||
android:pathData="M49,56.89l-0.15,-0.2l-0.43,-0.55l-0.53,-0.57c-0.22,-0.25 -0.48,-0.49 -0.73,-0.75s-0.56,-0.51 -0.84,-0.72c-0.26,-0.2 -0.54,-0.39 -0.84,-0.54c-0.2,-0.11 -0.42,-0.2 -0.65,-0.25a0.739,0.739 0,0 0,-0.21 0H44.45h0.27h-0.55c-0.15,0 -0.05,0 0,0h0.08c0.08,0 0,0 0,0h-0.11c-0.23,0.05 -0.45,0.13 -0.66,0.25c-0.29,0.16 -0.58,0.34 -0.84,0.54c-0.29,0.22 -0.57,0.46 -0.83,0.72c-0.53,0.51 -1,1 -1.3,1.39l-0.52,0.6l-0.23,0.27a4.231,4.231 0,0 1,-5.62 0.61a3.54,3.54 0,0 1,-1.47 -3.48s0.07,-0.4 0.26,-1.11c0.3,-1.01 0.72,-1.99 1.25,-2.91c0.85,-1.5 2,-2.81 3.38,-3.85c0.91,-0.7 1.92,-1.26 3,-1.65c0.3,-0.12 0.61,-0.21 0.92,-0.29c0.33,-0.1 0.66,-0.17 1,-0.23l0.61,-0.09l0.51,-0.06h1.85c0.34,0 0.67,0.09 1,0.14c0.64,0.11 1.28,0.28 1.89,0.51c1.08,0.39 2.09,0.95 3,1.65c1.38,1.04 2.53,2.35 3.38,3.85c0.31,0.52 0.58,1.07 0.8,1.63c0.19,0.45 0.35,0.9 0.48,1.37c0.07,0.24 0.13,0.48 0.16,0.72v0.25c0.3,2.04 -1.12,3.94 -3.16,4.24c-0.05,0.01 -0.1,0.01 -0.15,0.02c-1.46,0.21 -2.92,-0.37 -3.85,-1.51z" />
|
||||
<path
|
||||
android:fillColor="#422b0d"
|
||||
android:pathData="M88.46,56.89l-0.16,-0.2l-0.43,-0.55l-0.53,-0.57c-0.22,-0.25 -0.48,-0.49 -0.73,-0.75s-0.56,-0.51 -0.84,-0.72c-0.26,-0.2 -0.54,-0.39 -0.84,-0.54c-0.2,-0.11 -0.42,-0.2 -0.65,-0.25a0.739,0.739 0,0 0,-0.21 0H83.9h0.27h-0.55c-0.15,0 -0.05,0 0,0h0.08c0.08,0 0,0 0,0h-0.11c-0.23,0.05 -0.45,0.13 -0.66,0.25c-0.29,0.15 -0.57,0.34 -0.83,0.54c-0.3,0.22 -0.58,0.46 -0.84,0.72c-0.53,0.51 -1,1 -1.3,1.39l-0.52,0.6l-0.22,0.27a4.244,4.244 0,0 1,-5.63 0.61a3.54,3.54 0,0 1,-1.47 -3.48s0.07,-0.4 0.27,-1.11c0.3,-1.02 0.71,-2 1.25,-2.91c0.85,-1.5 1.99,-2.81 3.37,-3.85c0.91,-0.7 1.92,-1.26 3,-1.65c0.3,-0.12 0.61,-0.21 0.92,-0.29c0.33,-0.1 0.66,-0.17 1,-0.23l0.62,-0.09l0.5,-0.06h1.85c0.34,0 0.67,0.09 1,0.14c0.65,0.11 1.28,0.28 1.89,0.51c1.08,0.39 2.09,0.95 3,1.65c1.38,1.04 2.53,2.35 3.38,3.85c0.31,0.52 0.58,1.07 0.8,1.63c0.19,0.44 0.35,0.89 0.48,1.35c0.07,0.24 0.13,0.48 0.16,0.72v0.25a3.74,3.74 0,0 1,-3.12 4.27c-0.03,0 -0.06,0.01 -0.09,0.01c-1.49,0.25 -3,-0.33 -3.94,-1.51z" />
|
||||
<path
|
||||
android:fillColor="#b3b3b3"
|
||||
android:pathData="M100.89,75.83c-0.09,0.06 -6.2,4.63 -17.69,7.59v-11.3c-1.31,0.2 -2.65,0.37 -4,0.52v11.68c-4.65,0.92 -9.38,1.43 -14.12,1.53V73.43h-4v12.42c0.43,0.01 0.43,0.02 0,0.02l-0.02,-0.02c-4.63,-0.08 -9.24,-0.52 -13.8,-1.33V72.33c-1.36,-0.18 -2.69,-0.39 -4,-0.62v11.97c-11.82,-2.81 -17.76,-7.3 -17.84,-7.37a1.96,1.96 0,0 0,-1.16 -0.42c0.28,1.26 0.7,2.49 1.26,3.66c0.35,0.77 0.73,1.51 1.13,2.25a63.036,63.036 0,0 0,16.61 6v9.86c1.3,0.63 2.64,1.2 4,1.69V88.6c4.56,0.76 9.18,1.18 13.8,1.25l0.02,0.02h-0.02v12.21c0.77,0 1.55,0.08 2.34,0.08h1.66V89.85H65h0.06c4.74,-0.09 9.47,-0.57 14.14,-1.43v11.21c1.36,-0.46 2.7,-1 4,-1.61V87.57c6.1,-1.4 11.97,-3.69 17.41,-6.79c0.1,-0.22 0.22,-0.42 0.32,-0.64c0.73,-1.48 1.21,-3.07 1.4,-4.71c-0.51,-0.06 -1.03,0.09 -1.44,0.4z" />
|
||||
<path
|
||||
android:fillColor="#eb8f00"
|
||||
android:pathData="M102.11,71.63A5.877,5.877 0,0 0,94.92 69c-10.26,2.99 -20.9,4.48 -31.58,4.43A111.05,111.05 0,0 1,31.75 69a5.802,5.802 0,0 0,-7.13 2.6c-1.36,2.51 -0.38,5.42 0.77,7.93c0.51,1.13 1.08,2.24 1.71,3.31c0,0 -2.1,-7.78 -0.28,-10.04a3.55,3.55 0,0 1,2.8 -1.62c0.47,0 0.93,0.08 1.38,0.22c10.44,3.07 21.27,4.62 32.16,4.6h0.35c10.89,0.02 21.72,-1.53 32.16,-4.6c0.45,-0.14 0.91,-0.22 1.38,-0.22c1.14,0.06 2.19,0.66 2.81,1.62c1.85,2.26 -0.28,10.07 -0.28,10.07c0.62,-1.07 1.24,-2.17 1.76,-3.31c1.14,-2.51 2.13,-5.41 0.77,-7.93z" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M0,0h128v128h-128z" />
|
||||
</vector>
|
||||
71
app/src/main/res/drawable/win_emoji_cowboy_hat_face.xml
Normal file
@ -0,0 +1,71 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:aapt="http://schemas.android.com/aapt"
|
||||
android:width="128dp"
|
||||
android:height="128dp"
|
||||
android:viewportWidth="128"
|
||||
android:viewportHeight="128">
|
||||
<path android:pathData="M63.6,124.8c-24.81,0 -51.6,-15.56 -51.6,-49.71s26.79,-49.71 51.6,-49.71c13.78,0 26.5,4.53 35.93,12.8c10.22,9.08 15.65,21.88 15.65,36.91s-5.43,27.75 -15.65,36.82c-9.43,8.27 -22.24,12.89 -35.93,12.89z">
|
||||
<aapt:attr name="android:fillColor">
|
||||
<gradient
|
||||
android:centerX="63.59"
|
||||
android:centerY="75.09"
|
||||
android:gradientRadius="50.659"
|
||||
android:type="radial">
|
||||
<item
|
||||
android:color="#FFFDE030"
|
||||
android:offset="0.5" />
|
||||
<item
|
||||
android:color="#FFF7C02B"
|
||||
android:offset="0.92" />
|
||||
<item
|
||||
android:color="#FFF4A223"
|
||||
android:offset="1" />
|
||||
</gradient>
|
||||
</aapt:attr>
|
||||
</path>
|
||||
<path
|
||||
android:fillColor="#eb8f00"
|
||||
android:pathData="M106.19,45.54c4.88,8.1 7.38,17.42 7.21,26.88c0,15 -5.43,27.75 -15.65,36.82c-9.43,8.27 -22.23,12.89 -35.93,12.89c-16.06,0 -32.93,-6.53 -42.84,-20.4c9.57,15.71 27.56,23.07 44.62,23.07c13.69,0 26.5,-4.62 35.93,-12.89c10.22,-9.08 15.65,-21.79 15.65,-36.82c0,-11.33 -3.09,-21.4 -8.99,-29.55z" />
|
||||
<path
|
||||
android:fillColor="#4a251a"
|
||||
android:pathData="M34.25,33.47C13.9,25.4 0,13.55 0,22.8C0,41.22 4.83,56 12.6,67.31c2.11,-15.94 10.59,-27.09 21.65,-33.84z" />
|
||||
<path
|
||||
android:fillColor="#4a251a"
|
||||
android:pathData="M114.71,68.3C122.88,56.92 128,41.76 128,22.8c0,-9.7 -14.17,2.63 -34.84,10.81c2.23,1.39 4.34,2.95 6.32,4.68c8.62,7.65 13.81,17.96 15.23,30.01z" />
|
||||
<path
|
||||
android:fillColor="#826156"
|
||||
android:pathData="M94.2,19.2C89.7,9.5 81.9,0.1 74.7,0.2C66.9,0.3 68.3,3.6 64,3.6C59.5,3.6 61.2,0.2 53.9,0.2s-15.4,9.1 -20.2,19c9.92,2.4 20.1,3.54 30.3,3.4c13.7,0 23.6,-1.6 30.2,-3.4z" />
|
||||
<path
|
||||
android:fillColor="#a1887f"
|
||||
android:pathData="M96.46,25c-0.64,-1.98 -1.39,-3.91 -2.26,-5.8c-6.6,1.8 -16.5,3.4 -30.2,3.4c-10.2,0.14 -20.38,-1 -30.3,-3.4c-0.89,1.9 -1.66,3.86 -2.32,5.85C42.17,26.84 53.07,27.82 64,28c10.88,-0.18 21.73,-1.18 32.46,-3z" />
|
||||
<path
|
||||
android:fillColor="#7a5549"
|
||||
android:pathData="M96.46,25A215.397,215.397 0,0 1,64 28c-10.93,-0.18 -21.83,-1.16 -32.62,-2.95C15.58,22.6 3,19.5 3,19.5s17.3,34.3 61,34.3s60.1,-34.3 60.1,-34.3s-12.17,3.08 -27.64,5.5z" />
|
||||
<path
|
||||
android:fillColor="#422b0d"
|
||||
android:pathData="M82.3,57.4c3.5,0 6.7,4.1 6.7,10.9s-3.2,10.9 -6.7,10.9s-6.7,-4.1 -6.7,-10.9s3.2,-10.9 6.7,-10.9z" />
|
||||
<path
|
||||
android:fillColor="#422b0d"
|
||||
android:pathData="M45.7,57.4c-3.5,0 -6.7,4.1 -6.7,10.9s3.2,10.9 6.7,10.9s6.7,-4.1 6.7,-10.9s-3.2,-10.9 -6.7,-10.9z" />
|
||||
<path
|
||||
android:fillColor="#896024"
|
||||
android:pathData="M45.11,61.31a2.546,2.546 0,0 0,-3.38 1.25c-0.45,0.98 -0.24,2.13 0.52,2.88a2.552,2.552 0,0 0,2.86 -4.13z" />
|
||||
<path
|
||||
android:fillColor="#896024"
|
||||
android:pathData="M82,61.31a2.546,2.546 0,0 0,-3.38 1.25c-0.45,0.98 -0.24,2.13 0.52,2.88A2.552,2.552 0,0 0,82 61.31z" />
|
||||
<path
|
||||
android:fillColor="#422b0d"
|
||||
android:pathData="M95.57,88.78a4.843,4.843 0,0 0,-5.94 -2.16a92.39,92.39 0,0 1,-26.28 3.69c-8.9,0.04 -17.75,-1.2 -26.29,-3.69c-2.24,-0.84 -4.76,0.07 -5.93,2.16c-1.13,2.1 -0.31,4.52 0.64,6.61c5.35,11.73 17.12,18.74 31.51,18.79h0.13c14.4,-0.05 26.17,-7.06 31.51,-18.79c0.95,-2.09 1.78,-4.51 0.65,-6.61z" />
|
||||
<path
|
||||
android:fillColor="#ed7770"
|
||||
android:pathData="M76.66,110.85c-0.31,-0.28 -0.62,-0.54 -0.94,-0.81c-3.4,-2.98 -7.79,-4.59 -12.31,-4.5c-4.67,-0.1 -9.22,1.44 -12.87,4.35c-0.32,0.25 -0.65,0.5 -1,0.78s-0.47,0.56 -0.67,0.83a39.02,39.02 0,0 0,14.37 2.68h0.13c4.71,0.01 9.38,-0.82 13.79,-2.46c-0.15,-0.3 -0.32,-0.59 -0.5,-0.87z" />
|
||||
<path
|
||||
android:fillColor="#fff"
|
||||
android:pathData="M89.63,86.62a92.39,92.39 0,0 1,-26.28 3.69c-8.9,0.04 -17.75,-1.2 -26.29,-3.69c-2.24,-0.84 -4.76,0.07 -5.93,2.16c-0.17,0.32 -0.29,0.65 -0.38,1c0.28,0.14 0.59,0.28 1,0.43c10,5.01 21.06,7.56 32.25,7.43c10.74,0.12 21.36,-2.22 31.06,-6.83c0.39,-0.16 0.71,-0.32 1,-0.47a4.51,4.51 0,0 0,-0.49 -1.56a4.843,4.843 0,0 0,-5.94 -2.16z" />
|
||||
<path
|
||||
android:fillColor="#eb8f00"
|
||||
android:pathData="M95.6,88.79a4.913,4.913 0,0 0,-6 -2.17a92.39,92.39 0,0 1,-26.28 3.69a92.39,92.39 0,0 1,-26.28 -3.69c-2.24,-0.84 -4.76,0.07 -5.93,2.16c-1.13,2.1 -0.31,4.52 0.64,6.61c0.43,0.94 0.91,1.86 1.42,2.75c0,0 -1.77,-6.49 -0.23,-8.37c0.52,-0.79 1.38,-1.29 2.33,-1.35c0.39,0 0.78,0.07 1.15,0.19c8.7,2.53 17.72,3.81 26.78,3.78h0.29c9.05,0.03 18.06,-1.25 26.75,-3.78c0.37,-0.12 0.76,-0.19 1.15,-0.19c0.95,0.05 1.82,0.55 2.34,1.35c1.53,1.88 -0.23,8.38 -0.23,8.38c0.51,-0.89 1,-1.81 1.46,-2.75c0.95,-2.09 1.77,-4.51 0.64,-6.61z" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M0,0h128v128h-128z" />
|
||||
</vector>
|
||||
156
app/src/main/res/drawable/win_emoji_partying_face.xml
Normal file
@ -0,0 +1,156 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:aapt="http://schemas.android.com/aapt"
|
||||
android:width="128dp"
|
||||
android:height="128dp"
|
||||
android:viewportWidth="128"
|
||||
android:viewportHeight="128">
|
||||
<path android:pathData="M63.6,124.8c-24.81,0 -51.6,-15.56 -51.6,-49.71s26.79,-49.71 51.6,-49.71c13.78,0 26.5,4.53 35.93,12.8c10.22,9.08 15.65,21.88 15.65,36.91s-5.43,27.75 -15.65,36.82c-9.43,8.27 -22.24,12.89 -35.93,12.89z">
|
||||
<aapt:attr name="android:fillColor">
|
||||
<gradient
|
||||
android:centerX="63.59"
|
||||
android:centerY="75.09"
|
||||
android:gradientRadius="50.659"
|
||||
android:type="radial">
|
||||
<item
|
||||
android:color="#FFFDE030"
|
||||
android:offset="0.5" />
|
||||
<item
|
||||
android:color="#FFF7C02B"
|
||||
android:offset="0.92" />
|
||||
<item
|
||||
android:color="#FFF4A223"
|
||||
android:offset="1" />
|
||||
</gradient>
|
||||
</aapt:attr>
|
||||
</path>
|
||||
<path
|
||||
android:fillColor="#eb8f00"
|
||||
android:pathData="M106.19,45.54c4.88,8.1 7.38,17.42 7.21,26.88c0,15 -5.43,27.75 -15.65,36.82c-9.43,8.27 -22.23,12.89 -35.93,12.89c-16.06,0 -32.93,-6.53 -42.84,-20.4c9.57,15.71 27.56,23.07 44.62,23.07c13.69,0 26.5,-4.62 35.93,-12.89c10.22,-9.08 15.65,-21.79 15.65,-36.82c0,-11.33 -3.09,-21.4 -8.99,-29.55z" />
|
||||
<path
|
||||
android:fillAlpha="0.8"
|
||||
android:pathData="M16.3,71.6a17.5,16.5 0,1 0,35 0a17.5,16.5 0,1 0,-35 0z"
|
||||
android:strokeAlpha="0.8">
|
||||
<aapt:attr name="android:fillColor">
|
||||
<gradient
|
||||
android:centerX="33.800343"
|
||||
android:centerY="75.11886"
|
||||
android:gradientRadius="19.047281"
|
||||
android:type="radial">
|
||||
<item
|
||||
android:color="#FFED7770"
|
||||
android:offset="0" />
|
||||
<item
|
||||
android:color="#00ED7770"
|
||||
android:offset="0.9" />
|
||||
</gradient>
|
||||
</aapt:attr>
|
||||
</path>
|
||||
<path
|
||||
android:fillAlpha="0.8"
|
||||
android:pathData="M76.7,71.6a17.5,16.5 0,1 0,35 0a17.5,16.5 0,1 0,-35 0z"
|
||||
android:strokeAlpha="0.8">
|
||||
<aapt:attr name="android:fillColor">
|
||||
<gradient
|
||||
android:centerX="126.52"
|
||||
android:centerY="1172.59"
|
||||
android:gradientRadius="19.43"
|
||||
android:type="radial">
|
||||
<item
|
||||
android:color="#FFED7770"
|
||||
android:offset="0" />
|
||||
<item
|
||||
android:color="#00ED7770"
|
||||
android:offset="0.9" />
|
||||
</gradient>
|
||||
</aapt:attr>
|
||||
</path>
|
||||
<path
|
||||
android:fillColor="#ff00a2"
|
||||
android:pathData="M17,15a7,5 0,1 0,14 0a7,5 0,1 0,-14 0z" />
|
||||
<path
|
||||
android:fillColor="#fd3b3b"
|
||||
android:pathData="M46.588,28.351a4.2,5.5 134.999,1 0,5.94 -5.94a4.2,5.5 134.999,1 0,-5.94 5.94z" />
|
||||
<path
|
||||
android:fillColor="#0ef"
|
||||
android:pathData="M65.868,23.353a3.9,8.4 52.26,1 0,13.285 -10.283a3.9,8.4 52.26,1 0,-13.285 10.283z" />
|
||||
<path
|
||||
android:fillColor="#0048ff"
|
||||
android:pathData="M20.197,83.127a6.5,2.9 60,1 0,5.023 -2.9a6.5,2.9 60,1 0,-5.023 2.9z" />
|
||||
<path
|
||||
android:fillColor="#f63bbe"
|
||||
android:pathData="M93,110.5a3.5,5.5 0,1 0,7 0a3.5,5.5 0,1 0,-7 0z" />
|
||||
<path
|
||||
android:fillColor="#0c0"
|
||||
android:pathData="M110.067,60.837a2,6.5 54.857,1 0,10.63 -7.483a2,6.5 54.857,1 0,-10.63 7.483z" />
|
||||
<path
|
||||
android:fillColor="#0048ff"
|
||||
android:pathData="M17.098,117.391a6,2.5 56.731,1 0,4.181 -2.743a6,2.5 56.731,1 0,-4.181 2.743z" />
|
||||
<path
|
||||
android:fillColor="#7acded"
|
||||
android:pathData="M9.015,99.425a2.5,6 85.948,1 0,11.97 -0.848a2.5,6 85.948,1 0,-11.97 0.848z" />
|
||||
<path
|
||||
android:fillColor="#ff82b2"
|
||||
android:pathData="M16.822,87.179a1.7,7.2 86.199,1 0,14.368 -0.955a1.7,7.2 86.199,1 0,-14.368 0.955z" />
|
||||
<path android:pathData="M118.9,78.2c-0.85,-2.94 -2.88,-5.4 -5.6,-6.8c-4.6,-2.5 -10.36,-0.79 -12.85,3.81c-0.02,0.03 -0.03,0.06 -0.05,0.09a8.082,8.082 0,0 0,3.3 10.9c1.55,0.87 3.37,1.12 5.1,0.7c1.78,-0.4 3.28,-1.57 4.1,-3.2c0.89,-1.88 0.81,-4.08 -0.2,-5.9a5.174,5.174 0,0 0,-4.2 -2.8c-1.03,-0.02 -1.87,0.8 -1.89,1.83c-0.01,0.93 0.67,1.73 1.59,1.87c0.51,0.03 0.97,0.34 1.2,0.8c0.35,0.71 0.42,1.54 0.2,2.3a2.45,2.45 0,0 1,-1.7 1.3c-0.81,0.21 -1.67,0.1 -2.4,-0.3c-1,-0.53 -1.75,-1.43 -2.1,-2.5c-0.3,-1.1 -0.19,-2.27 0.3,-3.3a5.55,5.55 0,0 1,3.4 -2.8c1.47,-0.42 3.03,-0.28 4.4,0.4c1.79,0.98 3.12,2.64 3.7,4.6c0.61,1.97 0.39,4.1 -0.6,5.9c-1.9,3.6 -5.6,6 -11,6c-3.1,0 -21.55,-0.5 -21.55,-0.5l0.22,4.6l21.13,-0.3c6.3,0 11.5,-2.5 14.5,-8.1c1.58,-2.58 1.94,-5.73 1,-8.6z">
|
||||
<aapt:attr name="android:fillColor">
|
||||
<gradient
|
||||
android:endX="119.38"
|
||||
android:endY="82.726"
|
||||
android:startX="82.19"
|
||||
android:startY="82.726"
|
||||
android:type="linear">
|
||||
<item
|
||||
android:color="#FF004054"
|
||||
android:offset="0" />
|
||||
<item
|
||||
android:color="#FF45A4FF"
|
||||
android:offset="0.99" />
|
||||
</gradient>
|
||||
</aapt:attr>
|
||||
</path>
|
||||
<path
|
||||
android:fillColor="#7f0099"
|
||||
android:pathData="M70,93c0.61,0.65 1.08,1.41 1.4,2.24l11.45,-0.07c0,-1.5 -0.2,-3 -0.2,-4.6c-3,-0.1 -9.18,-0.2 -11.1,-0.27a5.759,5.759 0,0 1,-1.61 2.7H70z" />
|
||||
<path
|
||||
android:fillColor="#ff4545"
|
||||
android:pathData="M104.8,54.8l3.5,0.5l0.9,-3.5l0.5,-2L89.6,47c9.1,6.9 14.6,7.8 15.2,7.8z" />
|
||||
<path
|
||||
android:fillColor="#ff4545"
|
||||
android:pathData="M120.9,5.4l-8.1,4.6l-2,1.1l8.4,1.2c0.6,-2.5 1.7,-6.9 1.7,-6.9z" />
|
||||
<path
|
||||
android:fillColor="#ff4545"
|
||||
android:pathData="M103,15.5l-8.3,4.7l21.7,3.1l1.4,-5.7z" />
|
||||
<path
|
||||
android:fillColor="#ff4545"
|
||||
android:pathData="M79.3,28.9h-0.1l34.5,5l1.3,-5.3l-28.1,-4z" />
|
||||
<path
|
||||
android:fillColor="#ff4545"
|
||||
android:pathData="M82.2,40.4l28.8,4.1l1.4,-5.4l-34.7,-5c0.4,1.1 1.6,3.3 4.5,6.3z" />
|
||||
<path
|
||||
android:fillColor="#ff9c9c"
|
||||
android:pathData="M86.9,24.6l28.1,4l1.4,-5.3l-21.7,-3.1z" />
|
||||
<path
|
||||
android:fillColor="#ff9c9c"
|
||||
android:pathData="M118.6,14.5s0.3,-1.4 0.5,-2.1l-8.4,-1.2l-7.8,4.4l14.8,2.1l0.9,-3.2z" />
|
||||
<path
|
||||
android:fillColor="#ff9c9c"
|
||||
android:pathData="M76.3,30.5l1.1,3.2c0.04,0.18 0.11,0.35 0.2,0.5l34.7,5l1.3,-5.3L79.1,29l-2.8,1.5z" />
|
||||
<path
|
||||
android:fillColor="#ff9c9c"
|
||||
android:pathData="M89.2,46.7c0.1,0.1 0.3,0.2 0.4,0.3l20.1,2.9l1.3,-5.3l-28.8,-4.1c2.19,2.22 4.53,4.29 7,6.2z" />
|
||||
<path
|
||||
android:fillColor="#c93737"
|
||||
android:pathData="M120.8,6.5m-4.8,0a4.8,4.8 0,1 1,9.6 0a4.8,4.8 0,1 1,-9.6 0" />
|
||||
<path
|
||||
android:fillColor="#422b0d"
|
||||
android:pathData="M71.84,91.83a7.52,7.52 0,0 0,2.57 -5c0.28,-1.95 -0.3,-3.92 -1.6,-5.4c-2.33,-3.06 -8.81,-2.3 -8.81,-2.3c-1.74,0.07 -3.75,0.9 -3.5,2.9a3.269,3.269 0,0 0,2.42 2.29c2.56,0.61 6.21,0 6.31,2.6c0.12,2.92 -4.36,1.72 -4.72,4.81s4.72,2.68 4.72,4.81c0,1.63 -1.67,1.91 -3.43,2.28c-1.51,0.31 -4.41,0.78 -4.64,2.51s0.76,3.86 4.84,3.24c6.42,-1 8.58,-4.49 8.58,-6.65c0.04,-2.34 -0.96,-4.57 -2.74,-6.09z" />
|
||||
<path
|
||||
android:fillColor="#422b0d"
|
||||
android:pathData="M49.86,65.43l-0.15,-0.19l-0.4,-0.51l-0.51,-0.55c-0.2,-0.22 -0.44,-0.46 -0.68,-0.7c-0.25,-0.24 -0.51,-0.47 -0.79,-0.68c-0.25,-0.19 -0.51,-0.36 -0.79,-0.51c-0.19,-0.11 -0.4,-0.19 -0.62,-0.23a0.67,0.67 0,0 0,-0.2 0h-0.08h0.18h-0.52c-0.13,0 0,0 0,0h0.07c0.08,0 0,0 0,0a0.205,0.205 0,0 0,-0.11 0c-0.22,0.04 -0.43,0.12 -0.62,0.23c-0.28,0.15 -0.54,0.32 -0.79,0.51c-0.26,0.2 -0.53,0.44 -0.79,0.68c-0.49,0.48 -0.92,1 -1.22,1.31l-0.48,0.57l-0.22,0.25a3.995,3.995 0,0 1,-5.29 0.57c-1.05,-0.73 -1.59,-2 -1.39,-3.27c0,0 0.07,-0.38 0.25,-1c0.28,-0.96 0.68,-1.88 1.18,-2.74c0.78,-1.42 1.84,-2.67 3.11,-3.67c0.87,-0.66 1.83,-1.19 2.86,-1.56c0.28,-0.11 0.58,-0.2 0.87,-0.27c0.33,-0.1 0.66,-0.17 1,-0.22l0.58,-0.08H46.53c0.31,0 0.63,0.08 0.94,0.13a10.875,10.875 0,0 1,4.64 2.04c1.29,0.98 2.38,2.21 3.18,3.62c0.29,0.49 0.55,1.01 0.76,1.54c0.19,0.44 0.33,0.91 0.45,1.26s0.11,0.52 0.15,0.69v0.23a3.538,3.538 0,0 1,-3.01 3.99c-0.04,0.01 -0.08,0.01 -0.11,0.01c-1.39,0.21 -2.8,-0.34 -3.67,-1.45z" />
|
||||
<path
|
||||
android:fillColor="#422b0d"
|
||||
android:pathData="M87,65.43l-0.15,-0.19l-0.4,-0.51l-0.45,-0.55c-0.2,-0.22 -0.44,-0.46 -0.68,-0.7c-0.25,-0.24 -0.51,-0.47 -0.79,-0.68c-0.25,-0.19 -0.51,-0.36 -0.79,-0.51c-0.19,-0.11 -0.4,-0.19 -0.61,-0.23a0.67,0.67 0,0 0,-0.2 0h-0.08h0.15h-0.52c-0.14,0 0,0 0,0h0.07c0.08,0 0,0 0,0h-0.11c-0.21,0.04 -0.42,0.12 -0.61,0.23c-0.28,0.15 -0.54,0.32 -0.79,0.51c-0.28,0.21 -0.54,0.44 -0.79,0.68c-0.5,0.48 -0.92,1 -1.23,1.31l-0.48,0.57l-0.22,0.25a3.995,3.995 0,0 1,-5.29 0.57c-1.05,-0.73 -1.59,-2 -1.39,-3.27c0,0 0.07,-0.38 0.26,-1c0.25,-0.97 0.62,-1.91 1.1,-2.79c0.8,-1.41 1.89,-2.64 3.18,-3.62c0.87,-0.66 1.84,-1.19 2.87,-1.56c0.28,-0.11 0.57,-0.2 0.86,-0.27c0.33,-0.1 0.66,-0.17 1,-0.22l0.58,-0.08H83.71c0.32,0 0.63,0.08 0.94,0.13c1.69,0.29 3.28,0.98 4.65,2c1.29,0.98 2.37,2.21 3.18,3.62c0.29,0.49 0.54,1.01 0.75,1.54c0.18,0.41 0.33,0.83 0.45,1.26c0.07,0.23 0.12,0.46 0.15,0.69v0.23a3.512,3.512 0,0 1,-2.98 3.98c-0.04,0.01 -0.08,0.01 -0.13,0.02c-1.4,0.22 -2.82,-0.31 -3.72,-1.41z" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M0,0h128v128h-128z" />
|
||||
</vector>
|
||||
@ -0,0 +1,44 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:aapt="http://schemas.android.com/aapt"
|
||||
android:width="128dp"
|
||||
android:height="128dp"
|
||||
android:viewportWidth="128"
|
||||
android:viewportHeight="128">
|
||||
<path android:pathData="M63.6,118.8c-27.9,0 -58,-17.5 -58,-55.9S35.7,7 63.6,7c15.5,0 29.8,5.1 40.4,14.4c11.5,10.2 17.6,24.6 17.6,41.5s-6.1,31.2 -17.6,41.4c-10.6,9.3 -25,14.5 -40.4,14.5z">
|
||||
<aapt:attr name="android:fillColor">
|
||||
<gradient
|
||||
android:centerX="63.6"
|
||||
android:centerY="62.9"
|
||||
android:gradientRadius="56.96"
|
||||
android:type="radial">
|
||||
<item
|
||||
android:color="#FFFDE030"
|
||||
android:offset="0.5" />
|
||||
<item
|
||||
android:color="#FFF7C02B"
|
||||
android:offset="0.92" />
|
||||
<item
|
||||
android:color="#FFF4A223"
|
||||
android:offset="1" />
|
||||
</gradient>
|
||||
</aapt:attr>
|
||||
</path>
|
||||
<path
|
||||
android:fillColor="#eb8f00"
|
||||
android:pathData="M111.49,29.67c5.33,8.6 8.11,18.84 8.11,30.23c0,16.9 -6.1,31.2 -17.6,41.4c-10.6,9.3 -25,14.5 -40.4,14.5c-18.06,0 -37,-7.35 -48.18,-22.94c10.76,17.66 31,25.94 50.18,25.94c15.4,0 29.8,-5.2 40.4,-14.5c11.5,-10.2 17.6,-24.5 17.6,-41.4c0,-12.74 -3.47,-24.06 -10.11,-33.23z" />
|
||||
<path
|
||||
android:fillColor="#422b0d"
|
||||
android:pathData="M64,93.81c-11.51,0 -19.73,-6 -22.2,-9.74a4.15,4.15 0,0 1,-0.5 -4.22c0.47,-0.89 1.4,-1.44 2.41,-1.41c0.37,0 0.74,0.06 1.09,0.17A65.07,65.07 0,0 0,64 81.39c6.5,0.04 12.98,-0.9 19.2,-2.78c0.35,-0.11 0.72,-0.17 1.09,-0.17c1.01,-0.03 1.94,0.52 2.41,1.41a4.15,4.15 0,0 1,-0.5 4.22c-2.47,3.76 -10.69,9.74 -22.2,9.74z" />
|
||||
<path
|
||||
android:fillColor="#422b0d"
|
||||
android:pathData="M124,45.42s-4.26,0.09 -4.26,3.5c0,8.42 0.1,26.49 -22,26.49c-17.66,0 -26.09,-9.12 -27.51,-19.19c-0.58,-4.19 -2,-8.75 -6.27,-8.75s-5.65,4.53 -6.23,8.75c-1.42,10.07 -9.85,19.19 -27.51,19.19c-22.06,0 -22,-18.07 -22,-26.49c0,-3.41 -4.26,-3.5 -4.26,-3.5v-8.34a148.6,148.6 0,0 1,20.65 -1.26c12.48,0 17.45,0 27.38,1c5.87,0.58 12,0.65 12,0.65s6.1,-0.07 12,-0.65c9.93,-1 14.9,-1 27.38,-1c6.9,-0.06 13.79,0.37 20.63,1.26v8.34z" />
|
||||
<path
|
||||
android:fillColor="#896024"
|
||||
android:pathData="M21.12,52c-0.1,1.6 -0.74,3.08 -2.31,3.38c-0.18,0.03 -0.35,0.05 -0.53,0.05A2.888,2.888 0,0 1,15.44 53c-0.61,-2.76 0.06,-5.65 1.82,-7.86a8.5,8.5 0,0 1,6.58 -3.08c1.51,-0.14 2.85,0.97 2.99,2.48c0,0.03 0.01,0.06 0.01,0.1c0,1.88 -1.5,2.68 -3,3.2c-1.64,0.74 -2.7,2.36 -2.72,4.16z" />
|
||||
<path
|
||||
android:fillColor="#896024"
|
||||
android:pathData="M84.7,52c-0.09,1.6 -0.74,3.08 -2.3,3.38A2.9,2.9 0,0 1,79 53c-0.61,-2.76 0.06,-5.65 1.82,-7.86a8.52,8.52 0,0 1,6.59 -3.08c1.51,-0.14 2.85,0.97 2.99,2.48c0,0.03 0.01,0.06 0.01,0.1c0,1.88 -1.5,2.68 -3,3.2A4.624,4.624 0,0 0,84.7 52z" />
|
||||
<path
|
||||
android:fillColor="#00000000"
|
||||
android:pathData="M0,0h128v128h-128z" />
|
||||
</vector>
|
||||
113
app/src/main/res/layout/activity_main.xml
Normal file
@ -0,0 +1,113 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:id="@+id/main"
|
||||
android:fitsSystemWindows="true"
|
||||
android:orientation="vertical"
|
||||
tools:context=".MainActivity">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
android:layout_weight="1">
|
||||
|
||||
<TextView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="24dp"
|
||||
android:gravity="center"
|
||||
android:text="@string/app_name"
|
||||
android:textColor="@color/black"
|
||||
android:textSize="20dp"
|
||||
android:textStyle="bold" />
|
||||
</LinearLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
android:layout_weight="3"
|
||||
android:orientation="vertical">
|
||||
|
||||
<ImageView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_horizontal"
|
||||
android:src="@mipmap/app_logo_no_bg" />
|
||||
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_margin="16dp"
|
||||
android:orientation="vertical">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginBottom="16dp"
|
||||
android:gravity="center"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<Button
|
||||
android:id="@+id/btnPrevious"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="◀" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvDifficulty"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="16dp"
|
||||
android:layout_marginEnd="16dp"
|
||||
android:text="新手"
|
||||
android:textColor="@color/black"
|
||||
android:textSize="18dp" />
|
||||
|
||||
<Button
|
||||
android:id="@+id/btnNext"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="▶" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
|
||||
<TextView
|
||||
android:id="@+id/continueBtn"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="42dp"
|
||||
android:layout_marginBottom="16dp"
|
||||
android:background="@drawable/btn_bg_selector"
|
||||
android:gravity="center"
|
||||
android:text="@string/continue_game"
|
||||
android:textColor="@color/text_color_selector"
|
||||
android:textSize="16dp"
|
||||
android:visibility="visible" />
|
||||
|
||||
|
||||
<TextView
|
||||
android:id="@+id/newGameBtn"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="42dp"
|
||||
android:background="@drawable/btn_bg_selector"
|
||||
android:gravity="center"
|
||||
android:text="@string/new_game"
|
||||
android:textColor="@color/text_color_selector"
|
||||
android:textSize="16dp" />
|
||||
|
||||
|
||||
</LinearLayout>
|
||||
</LinearLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
android:layout_weight="1">
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
||||
67
app/src/main/res/layout/activity_splash.xml
Normal file
@ -0,0 +1,67 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:id="@+id/main"
|
||||
android:background="@color/white">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:gravity="center"
|
||||
android:orientation="vertical">
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginBottom="24dp">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/splash_logo"
|
||||
android:layout_width="94dp"
|
||||
android:layout_height="94dp"
|
||||
android:src="@mipmap/app_logo"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center"
|
||||
android:orientation="vertical">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/app_name"
|
||||
android:textColor="@color/black"
|
||||
android:textSize="24sp" />
|
||||
|
||||
</LinearLayout>
|
||||
</LinearLayout>
|
||||
</LinearLayout>
|
||||
|
||||
|
||||
<ProgressBar
|
||||
android:id="@+id/loading_indicator"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentBottom="true"
|
||||
android:layout_centerHorizontal="true"
|
||||
android:layout_marginBottom="48dp"
|
||||
android:layout_marginTop="48dp"
|
||||
android:indeterminate="true"
|
||||
android:indeterminateTint="@color/black" />
|
||||
|
||||
</RelativeLayout>
|
||||
10
app/src/main/res/layout/activity_splash2.xml
Normal file
@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:id="@+id/main"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
tools:context=".SplashActivity">
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
131
app/src/main/res/layout/activity_swipe.xml
Normal file
@ -0,0 +1,131 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:background="@color/grey"
|
||||
android:id="@+id/main"
|
||||
android:orientation="vertical">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="48dp"
|
||||
android:background="@mipmap/empty"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_marginStart="4dp"
|
||||
android:layout_weight="1"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="@color/black"
|
||||
android:gravity="center"
|
||||
android:orientation="horizontal"
|
||||
android:paddingStart="4dp"
|
||||
android:paddingEnd="4dp">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/hundreds"
|
||||
android:layout_width="20dp"
|
||||
android:layout_height="36dp"
|
||||
android:src="@mipmap/c0" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/tens"
|
||||
android:layout_width="20dp"
|
||||
android:layout_height="36dp"
|
||||
android:src="@mipmap/c0" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/ones"
|
||||
android:layout_width="20dp"
|
||||
android:layout_height="36dp"
|
||||
android:src="@mipmap/c0" />
|
||||
|
||||
</LinearLayout>
|
||||
</LinearLayout>
|
||||
|
||||
|
||||
<RelativeLayout
|
||||
android:id="@+id/btn_start"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_weight="1"
|
||||
android:gravity="center"
|
||||
android:text="Start">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/stateImg"
|
||||
android:layout_width="40dp"
|
||||
android:layout_height="40dp"
|
||||
android:src="@mipmap/smile" />
|
||||
</RelativeLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_marginEnd="4dp"
|
||||
android:layout_weight="1"
|
||||
android:gravity="center_vertical|end">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="@color/black"
|
||||
android:gravity="center"
|
||||
android:orientation="horizontal"
|
||||
android:paddingStart="4dp"
|
||||
android:paddingEnd="4dp">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/minuteTens"
|
||||
android:layout_width="20dp"
|
||||
android:layout_height="36dp"
|
||||
android:src="@mipmap/c0" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/minuteOnes"
|
||||
android:layout_width="20dp"
|
||||
android:layout_height="36dp"
|
||||
android:src="@mipmap/c0" />
|
||||
|
||||
<ImageView
|
||||
android:layout_width="20dp"
|
||||
android:layout_height="36dp"
|
||||
android:src="@mipmap/czz" />
|
||||
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/secondTens"
|
||||
android:layout_width="20dp"
|
||||
android:layout_height="36dp"
|
||||
android:src="@mipmap/c0" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/secondOnes"
|
||||
android:layout_width="20dp"
|
||||
android:layout_height="36dp"
|
||||
android:src="@mipmap/c0" />
|
||||
|
||||
</LinearLayout>
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<FrameLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<com.gogame.minesweeper.swipe.SwipeGridLayout
|
||||
android:id="@+id/grid_swipe"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_gravity="center" />
|
||||
|
||||
</FrameLayout>
|
||||
|
||||
</LinearLayout>
|
||||
54
app/src/main/res/layout/dialog_result.xml
Normal file
@ -0,0 +1,54 @@
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="320dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="@drawable/drw_dialog_bg"
|
||||
android:orientation="vertical"
|
||||
android:padding="16dp">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/imageView"
|
||||
android:layout_width="60dp"
|
||||
android:layout_height="60dp"
|
||||
android:layout_gravity="center"
|
||||
android:src="@drawable/lose_emoji_anguished_face" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/textViewTitle"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center"
|
||||
android:paddingTop="8dp"
|
||||
android:text="@string/you_lose"
|
||||
android:textColor="@color/black"
|
||||
android:textSize="16dp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/textViewMessage"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center"
|
||||
android:paddingTop="4dp"
|
||||
android:text="@string/lose_desc"
|
||||
android:textColor="@color/black"
|
||||
android:textSize="16dp" />
|
||||
|
||||
|
||||
<TextView
|
||||
android:id="@+id/newGameBtn"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="40dp"
|
||||
android:layout_marginTop="16dp"
|
||||
android:background="@drawable/drw_red_btn_bg"
|
||||
android:gravity="center"
|
||||
android:text="@string/new_game"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="16dp"
|
||||
android:textStyle="bold" />
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
||||
5
app/src/main/res/mipmap-anydpi-v26/app_logo.xml
Normal file
@ -0,0 +1,5 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<background android:drawable="@color/app_logo_background"/>
|
||||
<foreground android:drawable="@mipmap/app_logo_foreground"/>
|
||||
</adaptive-icon>
|
||||
5
app/src/main/res/mipmap-anydpi-v26/app_logo_round.xml
Normal file
@ -0,0 +1,5 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<background android:drawable="@color/app_logo_background"/>
|
||||
<foreground android:drawable="@mipmap/app_logo_foreground"/>
|
||||
</adaptive-icon>
|
||||
6
app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml
Normal file
@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<background android:drawable="@drawable/ic_launcher_background" />
|
||||
<foreground android:drawable="@drawable/ic_launcher_foreground" />
|
||||
<monochrome android:drawable="@drawable/ic_launcher_foreground" />
|
||||
</adaptive-icon>
|
||||
6
app/src/main/res/mipmap-anydpi-v26/ic_launcher_round.xml
Normal file
@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<background android:drawable="@drawable/ic_launcher_background" />
|
||||
<foreground android:drawable="@drawable/ic_launcher_foreground" />
|
||||
<monochrome android:drawable="@drawable/ic_launcher_foreground" />
|
||||
</adaptive-icon>
|
||||
BIN
app/src/main/res/mipmap-hdpi/app_logo.webp
Normal file
|
After Width: | Height: | Size: 980 B |
BIN
app/src/main/res/mipmap-hdpi/app_logo_foreground.webp
Normal file
|
After Width: | Height: | Size: 944 B |
BIN
app/src/main/res/mipmap-hdpi/app_logo_round.webp
Normal file
|
After Width: | Height: | Size: 2.1 KiB |
BIN
app/src/main/res/mipmap-hdpi/c0.png
Normal file
|
After Width: | Height: | Size: 168 B |
BIN
app/src/main/res/mipmap-hdpi/c1.png
Normal file
|
After Width: | Height: | Size: 145 B |
BIN
app/src/main/res/mipmap-hdpi/c2.png
Normal file
|
After Width: | Height: | Size: 167 B |
BIN
app/src/main/res/mipmap-hdpi/c3.png
Normal file
|
After Width: | Height: | Size: 150 B |
BIN
app/src/main/res/mipmap-hdpi/c4.png
Normal file
|
After Width: | Height: | Size: 174 B |
BIN
app/src/main/res/mipmap-hdpi/c5.png
Normal file
|
After Width: | Height: | Size: 166 B |
BIN
app/src/main/res/mipmap-hdpi/c6.png
Normal file
|
After Width: | Height: | Size: 166 B |
BIN
app/src/main/res/mipmap-hdpi/c7.png
Normal file
|
After Width: | Height: | Size: 155 B |
BIN
app/src/main/res/mipmap-hdpi/c8.png
Normal file
|
After Width: | Height: | Size: 156 B |
BIN
app/src/main/res/mipmap-hdpi/c9.png
Normal file
|
After Width: | Height: | Size: 164 B |
BIN
app/src/main/res/mipmap-hdpi/czz.png
Normal file
|
After Width: | Height: | Size: 92 B |
BIN
app/src/main/res/mipmap-hdpi/ic_launcher.webp
Normal file
|
After Width: | Height: | Size: 1.4 KiB |
BIN
app/src/main/res/mipmap-hdpi/ic_launcher_round.webp
Normal file
|
After Width: | Height: | Size: 2.8 KiB |
BIN
app/src/main/res/mipmap-hdpi/smile.png
Normal file
|
After Width: | Height: | Size: 2.4 KiB |
BIN
app/src/main/res/mipmap-hdpi/sorrow.png
Normal file
|
After Width: | Height: | Size: 2.3 KiB |
BIN
app/src/main/res/mipmap-mdpi/app_logo.webp
Normal file
|
After Width: | Height: | Size: 566 B |
BIN
app/src/main/res/mipmap-mdpi/app_logo_foreground.webp
Normal file
|
After Width: | Height: | Size: 630 B |
BIN
app/src/main/res/mipmap-mdpi/app_logo_round.webp
Normal file
|
After Width: | Height: | Size: 1.2 KiB |
BIN
app/src/main/res/mipmap-mdpi/ic_launcher.webp
Normal file
|
After Width: | Height: | Size: 982 B |
BIN
app/src/main/res/mipmap-mdpi/ic_launcher_round.webp
Normal file
|
After Width: | Height: | Size: 1.7 KiB |
BIN
app/src/main/res/mipmap-xhdpi/app_logo.webp
Normal file
|
After Width: | Height: | Size: 1.2 KiB |
BIN
app/src/main/res/mipmap-xhdpi/app_logo_foreground.webp
Normal file
|
After Width: | Height: | Size: 1.2 KiB |