├── ios ├── Flutter │ ├── Debug.xcconfig │ ├── Release.xcconfig │ ├── Generated.xcconfig │ ├── flutter_export_environment.sh │ └── AppFrameworkInfo.plist ├── Runner │ ├── AppDelegate.h │ ├── Assets.xcassets │ │ ├── LaunchImage.imageset │ │ │ ├── LaunchImage.png │ │ │ ├── LaunchImage@2x.png │ │ │ ├── LaunchImage@3x.png │ │ │ ├── README.md │ │ │ └── Contents.json │ │ └── AppIcon.appiconset │ │ │ ├── Icon-App-20x20@1x.png │ │ │ ├── Icon-App-20x20@2x.png │ │ │ ├── Icon-App-20x20@3x.png │ │ │ ├── Icon-App-29x29@1x.png │ │ │ ├── Icon-App-29x29@2x.png │ │ │ ├── Icon-App-29x29@3x.png │ │ │ ├── Icon-App-40x40@1x.png │ │ │ ├── Icon-App-40x40@2x.png │ │ │ ├── Icon-App-40x40@3x.png │ │ │ ├── Icon-App-60x60@2x.png │ │ │ ├── Icon-App-60x60@3x.png │ │ │ ├── Icon-App-76x76@1x.png │ │ │ ├── Icon-App-76x76@2x.png │ │ │ ├── Icon-App-1024x1024@1x.png │ │ │ ├── Icon-App-83.5x83.5@2x.png │ │ │ └── Contents.json │ ├── main.m │ ├── GeneratedPluginRegistrant.h │ ├── AppDelegate.m │ ├── Base.lproj │ │ ├── Main.storyboard │ │ └── LaunchScreen.storyboard │ ├── Info.plist │ └── GeneratedPluginRegistrant.m ├── Runner.xcworkspace │ ├── contents.xcworkspacedata │ └── xcshareddata │ │ ├── WorkspaceSettings.xcsettings │ │ └── IDEWorkspaceChecks.plist ├── Runner.xcodeproj │ ├── project.xcworkspace │ │ ├── contents.xcworkspacedata │ │ └── xcshareddata │ │ │ ├── WorkspaceSettings.xcsettings │ │ │ └── IDEWorkspaceChecks.plist │ ├── xcshareddata │ │ └── xcschemes │ │ │ └── Runner.xcscheme │ └── project.pbxproj └── .gitignore ├── asset ├── images │ ├── 1.png │ ├── 10.png │ ├── 2.png │ ├── 3.png │ ├── 4.png │ ├── 5.png │ ├── 6.png │ ├── 7.png │ ├── 8.png │ └── 9.png └── fonts │ └── SourceSansPro-Regular.ttf ├── images └── memory game image.png ├── android ├── gradle.properties ├── gradle │ └── wrapper │ │ ├── gradle-wrapper.jar │ │ └── gradle-wrapper.properties ├── app │ ├── src │ │ ├── main │ │ │ ├── res │ │ │ │ ├── mipmap-hdpi │ │ │ │ │ └── ic_launcher.png │ │ │ │ ├── mipmap-mdpi │ │ │ │ │ └── ic_launcher.png │ │ │ │ ├── mipmap-xhdpi │ │ │ │ │ └── ic_launcher.png │ │ │ │ ├── mipmap-xxhdpi │ │ │ │ │ └── ic_launcher.png │ │ │ │ ├── mipmap-xxxhdpi │ │ │ │ │ └── ic_launcher.png │ │ │ │ ├── drawable │ │ │ │ │ └── launch_background.xml │ │ │ │ └── values │ │ │ │ │ └── styles.xml │ │ │ ├── kotlin │ │ │ │ └── com │ │ │ │ │ └── blackhole │ │ │ │ │ └── memory │ │ │ │ │ └── MainActivity.kt │ │ │ ├── AndroidManifest.xml │ │ │ └── java │ │ │ │ └── io │ │ │ │ └── flutter │ │ │ │ └── plugins │ │ │ │ └── GeneratedPluginRegistrant.java │ │ ├── debug │ │ │ └── AndroidManifest.xml │ │ └── profile │ │ │ └── AndroidManifest.xml │ ├── google-services.json │ └── build.gradle ├── local.properties ├── .gitignore ├── settings.gradle ├── build.gradle ├── memory_android.iml ├── gradlew.bat └── gradlew ├── .metadata ├── lib ├── main.dart ├── data │ └── data.dart └── screen │ ├── brain_jam.dart │ ├── setting.dart │ ├── high score.dart │ ├── help.dart │ ├── challenges page.dart │ ├── Challenges level.dart │ └── home screen.dart ├── .gitignore ├── README.md ├── pubspec.yaml ├── privacy.md └── pubspec.lock /ios/Flutter/Debug.xcconfig: -------------------------------------------------------------------------------- 1 | #include "Generated.xcconfig" 2 | -------------------------------------------------------------------------------- /ios/Flutter/Release.xcconfig: -------------------------------------------------------------------------------- 1 | #include "Generated.xcconfig" 2 | -------------------------------------------------------------------------------- /asset/images/1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imayush-chauhan/Memory-Game/HEAD/asset/images/1.png -------------------------------------------------------------------------------- /asset/images/10.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imayush-chauhan/Memory-Game/HEAD/asset/images/10.png -------------------------------------------------------------------------------- /asset/images/2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imayush-chauhan/Memory-Game/HEAD/asset/images/2.png -------------------------------------------------------------------------------- /asset/images/3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imayush-chauhan/Memory-Game/HEAD/asset/images/3.png -------------------------------------------------------------------------------- /asset/images/4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imayush-chauhan/Memory-Game/HEAD/asset/images/4.png -------------------------------------------------------------------------------- /asset/images/5.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imayush-chauhan/Memory-Game/HEAD/asset/images/5.png -------------------------------------------------------------------------------- /asset/images/6.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imayush-chauhan/Memory-Game/HEAD/asset/images/6.png -------------------------------------------------------------------------------- /asset/images/7.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imayush-chauhan/Memory-Game/HEAD/asset/images/7.png -------------------------------------------------------------------------------- /asset/images/8.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imayush-chauhan/Memory-Game/HEAD/asset/images/8.png -------------------------------------------------------------------------------- /asset/images/9.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imayush-chauhan/Memory-Game/HEAD/asset/images/9.png -------------------------------------------------------------------------------- /images/memory game image.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imayush-chauhan/Memory-Game/HEAD/images/memory game image.png -------------------------------------------------------------------------------- /asset/fonts/SourceSansPro-Regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imayush-chauhan/Memory-Game/HEAD/asset/fonts/SourceSansPro-Regular.ttf -------------------------------------------------------------------------------- /android/gradle.properties: -------------------------------------------------------------------------------- 1 | org.gradle.jvmargs=-Xmx1536M 2 | android.useAndroidX=true 3 | android.enableJetifier=true 4 | android.enableR8=true 5 | -------------------------------------------------------------------------------- /android/gradle/wrapper/gradle-wrapper.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imayush-chauhan/Memory-Game/HEAD/android/gradle/wrapper/gradle-wrapper.jar -------------------------------------------------------------------------------- /ios/Runner/AppDelegate.h: -------------------------------------------------------------------------------- 1 | #import 2 | #import 3 | 4 | @interface AppDelegate : FlutterAppDelegate 5 | 6 | @end 7 | -------------------------------------------------------------------------------- /android/app/src/main/res/mipmap-hdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imayush-chauhan/Memory-Game/HEAD/android/app/src/main/res/mipmap-hdpi/ic_launcher.png -------------------------------------------------------------------------------- /android/app/src/main/res/mipmap-mdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imayush-chauhan/Memory-Game/HEAD/android/app/src/main/res/mipmap-mdpi/ic_launcher.png -------------------------------------------------------------------------------- /android/app/src/main/res/mipmap-xhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imayush-chauhan/Memory-Game/HEAD/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png -------------------------------------------------------------------------------- /android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imayush-chauhan/Memory-Game/HEAD/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imayush-chauhan/Memory-Game/HEAD/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imayush-chauhan/Memory-Game/HEAD/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imayush-chauhan/Memory-Game/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imayush-chauhan/Memory-Game/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imayush-chauhan/Memory-Game/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imayush-chauhan/Memory-Game/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imayush-chauhan/Memory-Game/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imayush-chauhan/Memory-Game/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imayush-chauhan/Memory-Game/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imayush-chauhan/Memory-Game/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imayush-chauhan/Memory-Game/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imayush-chauhan/Memory-Game/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imayush-chauhan/Memory-Game/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imayush-chauhan/Memory-Game/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imayush-chauhan/Memory-Game/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imayush-chauhan/Memory-Game/HEAD/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imayush-chauhan/Memory-Game/HEAD/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png -------------------------------------------------------------------------------- /android/local.properties: -------------------------------------------------------------------------------- 1 | sdk.dir=C:\\Users\\ayush\\AppData\\Local\\Android\\sdk 2 | flutter.sdk=C:\\Flutter ayu\\flutter 3 | flutter.buildMode=debug 4 | flutter.versionName=1.1.20 5 | flutter.versionCode=20 -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imayush-chauhan/Memory-Game/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imayush-chauhan/Memory-Game/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png -------------------------------------------------------------------------------- /android/app/src/main/kotlin/com/blackhole/memory/MainActivity.kt: -------------------------------------------------------------------------------- 1 | package com.blackhole.memory 2 | 3 | import io.flutter.embedding.android.FlutterActivity 4 | 5 | class MainActivity: FlutterActivity() { 6 | } 7 | -------------------------------------------------------------------------------- /ios/Runner.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /ios/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /ios/Runner/main.m: -------------------------------------------------------------------------------- 1 | #import 2 | #import 3 | #import "AppDelegate.h" 4 | 5 | int main(int argc, char* argv[]) { 6 | @autoreleasepool { 7 | return UIApplicationMain(argc, argv, nil, NSStringFromClass([AppDelegate class])); 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /android/gradle/wrapper/gradle-wrapper.properties: -------------------------------------------------------------------------------- 1 | #Fri Jun 23 08:50:38 CEST 2017 2 | distributionBase=GRADLE_USER_HOME 3 | distributionPath=wrapper/dists 4 | zipStoreBase=GRADLE_USER_HOME 5 | zipStorePath=wrapper/dists 6 | distributionUrl=https\://services.gradle.org/distributions/gradle-6.5-all.zip 7 | -------------------------------------------------------------------------------- /ios/Runner.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | PreviewsEnabled 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /android/.gitignore: -------------------------------------------------------------------------------- 1 | gradle-wrapper.jar 2 | /.gradle 3 | /captures/ 4 | /gradlew 5 | /gradlew.bat 6 | /local.properties 7 | GeneratedPluginRegistrant.java 8 | 9 | # Remember to never publicly share your keystore. 10 | # See https://flutter.dev/docs/deployment/android#reference-the-keystore-from-the-app 11 | key.properties 12 | -------------------------------------------------------------------------------- /ios/Runner.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | PreviewsEnabled 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /.metadata: -------------------------------------------------------------------------------- 1 | # This file tracks properties of this Flutter project. 2 | # Used by Flutter tool to assess capabilities and perform upgrades etc. 3 | # 4 | # This file should be version controlled and should not be manually edited. 5 | 6 | version: 7 | revision: 78910062997c3a836feee883712c241a5fd22983 8 | channel: stable 9 | 10 | project_type: app 11 | -------------------------------------------------------------------------------- /lib/main.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:memory/screen/home%20screen.dart'; 3 | 4 | void main(){ 5 | runApp(MaterialApp( 6 | title: "Memory Game", 7 | debugShowCheckedModeBanner: false, 8 | theme: ThemeData( 9 | primaryColor: Color(0xffC850C0), 10 | ), 11 | home: HomeScreen(), 12 | )); 13 | } -------------------------------------------------------------------------------- /android/app/src/debug/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 3 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /android/app/src/profile/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 3 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/LaunchImage.imageset/README.md: -------------------------------------------------------------------------------- 1 | # Launch Screen Assets 2 | 3 | You can customize the launch screen with your own desired assets by replacing the image files in this directory. 4 | 5 | You can also do it by opening your Flutter project's Xcode project with `open ios/Runner.xcworkspace`, selecting `Runner/Assets.xcassets` in the Project Navigator and dropping in the desired images. -------------------------------------------------------------------------------- /ios/Runner/GeneratedPluginRegistrant.h: -------------------------------------------------------------------------------- 1 | // 2 | // Generated file. Do not edit. 3 | // 4 | 5 | // clang-format off 6 | 7 | #ifndef GeneratedPluginRegistrant_h 8 | #define GeneratedPluginRegistrant_h 9 | 10 | #import 11 | 12 | NS_ASSUME_NONNULL_BEGIN 13 | 14 | @interface GeneratedPluginRegistrant : NSObject 15 | + (void)registerWithRegistry:(NSObject*)registry; 16 | @end 17 | 18 | NS_ASSUME_NONNULL_END 19 | #endif /* GeneratedPluginRegistrant_h */ 20 | -------------------------------------------------------------------------------- /ios/Runner/AppDelegate.m: -------------------------------------------------------------------------------- 1 | #import "AppDelegate.h" 2 | #import "GeneratedPluginRegistrant.h" 3 | 4 | @implementation AppDelegate 5 | 6 | - (BOOL)application:(UIApplication *)application 7 | didFinishLaunchingWithOptions:(NSDictionary *)launchOptions { 8 | [GeneratedPluginRegistrant registerWithRegistry:self]; 9 | // Override point for customization after application launch. 10 | return [super application:application didFinishLaunchingWithOptions:launchOptions]; 11 | } 12 | 13 | @end 14 | -------------------------------------------------------------------------------- /android/settings.gradle: -------------------------------------------------------------------------------- 1 | include ':app' 2 | 3 | def localPropertiesFile = new File(rootProject.projectDir, "local.properties") 4 | def properties = new Properties() 5 | 6 | assert localPropertiesFile.exists() 7 | localPropertiesFile.withReader("UTF-8") { reader -> properties.load(reader) } 8 | 9 | def flutterSdkPath = properties.getProperty("flutter.sdk") 10 | assert flutterSdkPath != null, "flutter.sdk not set in local.properties" 11 | apply from: "$flutterSdkPath/packages/flutter_tools/gradle/app_plugin_loader.gradle" 12 | -------------------------------------------------------------------------------- /ios/Flutter/Generated.xcconfig: -------------------------------------------------------------------------------- 1 | // This is a generated file; do not edit or check into version control. 2 | FLUTTER_ROOT=C:\Flutter ayu\flutter 3 | FLUTTER_APPLICATION_PATH=C:\Users\ayush\AndroidStudioProjects\memory 4 | COCOAPODS_PARALLEL_CODE_SIGN=true 5 | FLUTTER_TARGET=lib\main.dart 6 | FLUTTER_BUILD_DIR=build 7 | FLUTTER_BUILD_NAME=1.1.20 8 | FLUTTER_BUILD_NUMBER=20 9 | EXCLUDED_ARCHS[sdk=iphonesimulator*]=i386 10 | DART_OBFUSCATION=false 11 | TRACK_WIDGET_CREATION=false 12 | TREE_SHAKE_ICONS=false 13 | PACKAGE_CONFIG=.packages 14 | -------------------------------------------------------------------------------- /android/app/src/main/res/drawable/launch_background.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 12 | 13 | -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/LaunchImage.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "universal", 5 | "filename" : "LaunchImage.png", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "universal", 10 | "filename" : "LaunchImage@2x.png", 11 | "scale" : "2x" 12 | }, 13 | { 14 | "idiom" : "universal", 15 | "filename" : "LaunchImage@3x.png", 16 | "scale" : "3x" 17 | } 18 | ], 19 | "info" : { 20 | "version" : 1, 21 | "author" : "xcode" 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /ios/Flutter/flutter_export_environment.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # This is a generated file; do not edit or check into version control. 3 | export "FLUTTER_ROOT=C:\Flutter ayu\flutter" 4 | export "FLUTTER_APPLICATION_PATH=C:\Users\ayush\AndroidStudioProjects\memory" 5 | export "COCOAPODS_PARALLEL_CODE_SIGN=true" 6 | export "FLUTTER_TARGET=lib\main.dart" 7 | export "FLUTTER_BUILD_DIR=build" 8 | export "FLUTTER_BUILD_NAME=1.1.20" 9 | export "FLUTTER_BUILD_NUMBER=20" 10 | export "DART_OBFUSCATION=false" 11 | export "TRACK_WIDGET_CREATION=false" 12 | export "TREE_SHAKE_ICONS=false" 13 | export "PACKAGE_CONFIG=.packages" 14 | -------------------------------------------------------------------------------- /ios/.gitignore: -------------------------------------------------------------------------------- 1 | *.mode1v3 2 | *.mode2v3 3 | *.moved-aside 4 | *.pbxuser 5 | *.perspectivev3 6 | **/*sync/ 7 | .sconsign.dblite 8 | .tags* 9 | **/.vagrant/ 10 | **/DerivedData/ 11 | Icon? 12 | **/Pods/ 13 | **/.symlinks/ 14 | profile 15 | xcuserdata 16 | **/.generated/ 17 | Flutter/App.framework 18 | Flutter/Flutter.framework 19 | Flutter/Flutter.podspec 20 | Flutter/Generated.xcconfig 21 | Flutter/app.flx 22 | Flutter/app.zip 23 | Flutter/flutter_assets/ 24 | Flutter/flutter_export_environment.sh 25 | ServiceDefinitions.json 26 | Runner/GeneratedPluginRegistrant.* 27 | 28 | # Exceptions to above rules. 29 | !default.mode1v3 30 | !default.mode2v3 31 | !default.pbxuser 32 | !default.perspectivev3 33 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # Miscellaneous 2 | *.class 3 | *.log 4 | *.pyc 5 | *.swp 6 | .DS_Store 7 | .atom/ 8 | .buildlog/ 9 | .history 10 | .svn/ 11 | 12 | # IntelliJ related 13 | *.iml 14 | *.ipr 15 | *.iws 16 | .idea/ 17 | 18 | # The .vscode folder contains launch configuration and tasks you configure in 19 | # VS Code which you may wish to be included in version control, so this line 20 | # is commented out by default. 21 | #.vscode/ 22 | 23 | # Flutter/Dart/Pub related 24 | **/doc/api/ 25 | **/ios/Flutter/.last_build_id 26 | .dart_tool/ 27 | .flutter-plugins 28 | .flutter-plugins-dependencies 29 | .packages 30 | .pub-cache/ 31 | .pub/ 32 | /build/ 33 | 34 | # Web related 35 | lib/generated_plugin_registrant.dart 36 | 37 | # Symbolication related 38 | app.*.symbols 39 | 40 | # Obfuscation related 41 | app.*.map.json 42 | -------------------------------------------------------------------------------- /android/build.gradle: -------------------------------------------------------------------------------- 1 | buildscript { 2 | ext.kotlin_version = '1.4.32' 3 | repositories { 4 | google() 5 | jcenter() 6 | } 7 | 8 | dependencies { 9 | classpath 'com.android.tools.build:gradle:4.1.0' 10 | classpath 'com.google.gms:google-services:4.3.10' 11 | classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version" 12 | } 13 | } 14 | 15 | allprojects { 16 | repositories { 17 | google() 18 | jcenter() 19 | } 20 | } 21 | 22 | rootProject.buildDir = '../build' 23 | subprojects { 24 | project.buildDir = "${rootProject.buildDir}/${project.name}" 25 | } 26 | subprojects { 27 | project.evaluationDependsOn(':app') 28 | } 29 | 30 | task clean(type: Delete) { 31 | delete rootProject.buildDir 32 | } 33 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Memory Game: Picture matching & Brain training 2 | 3 | Made with Flutter 4 | 5 | ![](images/memory%20game%20image.png) 6 | 7 | https://play.google.com/store/apps/details?id=com.blackhole.memory 8 | 9 | Developer Personal Website:- 10 | https://studioi.web.app 11 | 12 | 13 | ## Getting Started 14 | 15 | This project is a starting point for a Flutter application. 16 | 17 | A few resources to get you started if this is your first Flutter project: 18 | 19 | - [Lab: Write your first Flutter app](https://flutter.dev/docs/get-started/codelab) 20 | - [Cookbook: Useful Flutter samples](https://flutter.dev/docs/cookbook) 21 | 22 | For help getting started with Flutter, view our 23 | [online documentation](https://flutter.dev/docs), which offers tutorials, 24 | samples, guidance on mobile development, and a full API reference. 25 | -------------------------------------------------------------------------------- /ios/Flutter/AppFrameworkInfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | $(DEVELOPMENT_LANGUAGE) 7 | CFBundleExecutable 8 | App 9 | CFBundleIdentifier 10 | io.flutter.flutter.app 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | App 15 | CFBundlePackageType 16 | FMWK 17 | CFBundleShortVersionString 18 | 1.0 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | 1.0 23 | MinimumOSVersion 24 | 8.0 25 | 26 | 27 | -------------------------------------------------------------------------------- /android/app/src/main/res/values/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 9 | 15 | 18 | 19 | -------------------------------------------------------------------------------- /android/app/google-services.json: -------------------------------------------------------------------------------- 1 | { 2 | "project_info": { 3 | "project_number": "400452120850", 4 | "project_id": "memory-game-3236c", 5 | "storage_bucket": "memory-game-3236c.appspot.com" 6 | }, 7 | "client": [ 8 | { 9 | "client_info": { 10 | "mobilesdk_app_id": "1:400452120850:android:e321093413c8746c2403cb", 11 | "android_client_info": { 12 | "package_name": "com.blackhole.memory" 13 | } 14 | }, 15 | "oauth_client": [ 16 | { 17 | "client_id": "400452120850-mo5gv16qamfg6pb7679rb13fv942qt04.apps.googleusercontent.com", 18 | "client_type": 3 19 | } 20 | ], 21 | "api_key": [ 22 | { 23 | "current_key": "AIzaSyCcJY_dJeOTu6nRGnSTWfm5J4nZDfInGPo" 24 | } 25 | ], 26 | "services": { 27 | "appinvite_service": { 28 | "other_platform_oauth_client": [ 29 | { 30 | "client_id": "400452120850-mo5gv16qamfg6pb7679rb13fv942qt04.apps.googleusercontent.com", 31 | "client_type": 3 32 | } 33 | ] 34 | } 35 | } 36 | } 37 | ], 38 | "configuration_version": "1" 39 | } -------------------------------------------------------------------------------- /android/memory_android.iml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /lib/data/data.dart: -------------------------------------------------------------------------------- 1 | class Data{ 2 | 3 | static int highScoreInPokemon = 0; 4 | static int timeInPokemon = 0; 5 | static int highScoreInEmoji = 0; 6 | static int timeInEmoji = 0; 7 | static int highScoreInNumber = 0; 8 | static int timeInNumber = 0; 9 | static int level = 1; 10 | static int con = 1; 11 | 12 | static int level_1 = 0; 13 | static int level_2 = 0; 14 | static int level_3 = 0; 15 | static int level_4 = 0; 16 | static int level_5 = 0; 17 | static int level_6 = 0; 18 | static int level_7 = 0; 19 | static int level_8 = 0; 20 | static int level_9 = 0; 21 | static int level_10 = 0; 22 | static int level_11 = 0; 23 | static int level_12 = 0; 24 | static int level_13 = 0; 25 | static int level_14 = 0; 26 | static int level_15 = 0; 27 | 28 | static int time_1 = 0; 29 | static int time_2 = 0; 30 | static int time_3 = 0; 31 | static int time_4 = 0; 32 | static int time_5 = 0; 33 | static int time_6 = 0; 34 | static int time_7 = 0; 35 | static int time_8 = 0; 36 | static int time_9 = 0; 37 | static int time_10 = 0; 38 | static int time_11 = 0; 39 | static int time_12 = 0; 40 | static int time_13 = 0; 41 | static int time_14 = 0; 42 | static int time_15 = 0; 43 | 44 | static bool challenge_1 = false; 45 | static bool challenge_2 = false; 46 | static bool challenge_3 = false; 47 | 48 | static int playerLevel = 1; 49 | 50 | static bool play = true; 51 | static bool neverPlay = false; 52 | static String music = ""; 53 | 54 | static bool showAds = false; 55 | 56 | static bool share = false; 57 | static bool rate = false; 58 | } -------------------------------------------------------------------------------- /ios/Runner/Base.lproj/Main.storyboard: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /ios/Runner/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | $(DEVELOPMENT_LANGUAGE) 7 | CFBundleExecutable 8 | $(EXECUTABLE_NAME) 9 | CFBundleIdentifier 10 | $(PRODUCT_BUNDLE_IDENTIFIER) 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | memory 15 | CFBundlePackageType 16 | APPL 17 | CFBundleShortVersionString 18 | $(FLUTTER_BUILD_NAME) 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | $(FLUTTER_BUILD_NUMBER) 23 | LSRequiresIPhoneOS 24 | 25 | UILaunchStoryboardName 26 | LaunchScreen 27 | UIMainStoryboardFile 28 | Main 29 | UISupportedInterfaceOrientations 30 | 31 | UIInterfaceOrientationPortrait 32 | UIInterfaceOrientationLandscapeLeft 33 | UIInterfaceOrientationLandscapeRight 34 | 35 | UISupportedInterfaceOrientations~ipad 36 | 37 | UIInterfaceOrientationPortrait 38 | UIInterfaceOrientationPortraitUpsideDown 39 | UIInterfaceOrientationLandscapeLeft 40 | UIInterfaceOrientationLandscapeRight 41 | 42 | UIViewControllerBasedStatusBarAppearance 43 | 44 | 45 | 46 | -------------------------------------------------------------------------------- /ios/Runner/Base.lproj/LaunchScreen.storyboard: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | -------------------------------------------------------------------------------- /android/gradlew.bat: -------------------------------------------------------------------------------- 1 | @if "%DEBUG%" == "" @echo off 2 | @rem ########################################################################## 3 | @rem 4 | @rem Gradle startup script for Windows 5 | @rem 6 | @rem ########################################################################## 7 | 8 | @rem Set local scope for the variables with windows NT shell 9 | if "%OS%"=="Windows_NT" setlocal 10 | 11 | @rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. 12 | set DEFAULT_JVM_OPTS= 13 | 14 | set DIRNAME=%~dp0 15 | if "%DIRNAME%" == "" set DIRNAME=. 16 | set APP_BASE_NAME=%~n0 17 | set APP_HOME=%DIRNAME% 18 | 19 | @rem Find java.exe 20 | if defined JAVA_HOME goto findJavaFromJavaHome 21 | 22 | set JAVA_EXE=java.exe 23 | %JAVA_EXE% -version >NUL 2>&1 24 | if "%ERRORLEVEL%" == "0" goto init 25 | 26 | echo. 27 | echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. 28 | echo. 29 | echo Please set the JAVA_HOME variable in your environment to match the 30 | echo location of your Java installation. 31 | 32 | goto fail 33 | 34 | :findJavaFromJavaHome 35 | set JAVA_HOME=%JAVA_HOME:"=% 36 | set JAVA_EXE=%JAVA_HOME%/bin/java.exe 37 | 38 | if exist "%JAVA_EXE%" goto init 39 | 40 | echo. 41 | echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME% 42 | echo. 43 | echo Please set the JAVA_HOME variable in your environment to match the 44 | echo location of your Java installation. 45 | 46 | goto fail 47 | 48 | :init 49 | @rem Get command-line arguments, handling Windowz variants 50 | 51 | if not "%OS%" == "Windows_NT" goto win9xME_args 52 | if "%@eval[2+2]" == "4" goto 4NT_args 53 | 54 | :win9xME_args 55 | @rem Slurp the command line arguments. 56 | set CMD_LINE_ARGS= 57 | set _SKIP=2 58 | 59 | :win9xME_args_slurp 60 | if "x%~1" == "x" goto execute 61 | 62 | set CMD_LINE_ARGS=%* 63 | goto execute 64 | 65 | :4NT_args 66 | @rem Get arguments from the 4NT Shell from JP Software 67 | set CMD_LINE_ARGS=%$ 68 | 69 | :execute 70 | @rem Setup the command line 71 | 72 | set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar 73 | 74 | @rem Execute Gradle 75 | "%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS% 76 | 77 | :end 78 | @rem End local scope for the variables with windows NT shell 79 | if "%ERRORLEVEL%"=="0" goto mainEnd 80 | 81 | :fail 82 | rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of 83 | rem the _cmd.exe /c_ return code! 84 | if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1 85 | exit /b 1 86 | 87 | :mainEnd 88 | if "%OS%"=="Windows_NT" endlocal 89 | 90 | :omega 91 | -------------------------------------------------------------------------------- /android/app/build.gradle: -------------------------------------------------------------------------------- 1 | def localProperties = new Properties() 2 | def localPropertiesFile = rootProject.file('local.properties') 3 | if (localPropertiesFile.exists()) { 4 | localPropertiesFile.withReader('UTF-8') { reader -> 5 | localProperties.load(reader) 6 | } 7 | } 8 | 9 | def flutterRoot = localProperties.getProperty('flutter.sdk') 10 | if (flutterRoot == null) { 11 | throw new GradleException("Flutter SDK not found. Define location with flutter.sdk in the local.properties file.") 12 | } 13 | 14 | def flutterVersionCode = localProperties.getProperty('flutter.versionCode') 15 | if (flutterVersionCode == null) { 16 | flutterVersionCode = '20' 17 | } 18 | 19 | def flutterVersionName = localProperties.getProperty('flutter.versionName') 20 | if (flutterVersionName == null) { 21 | flutterVersionName = '20.0' 22 | } 23 | 24 | apply plugin: 'com.android.application' 25 | apply plugin: 'com.google.gms.google-services' 26 | apply plugin: 'kotlin-android' 27 | apply from: "$flutterRoot/packages/flutter_tools/gradle/flutter.gradle" 28 | 29 | def keystoreProperties = new Properties() 30 | def keystorePropertiesFile = rootProject.file('key.properties') 31 | if (keystorePropertiesFile.exists()) { 32 | keystoreProperties.load(new FileInputStream(keystorePropertiesFile)) 33 | } 34 | 35 | android { 36 | compileSdkVersion 31 37 | 38 | sourceSets { 39 | main.java.srcDirs += 'src/main/kotlin' 40 | } 41 | 42 | lintOptions { 43 | disable 'InvalidPackage' 44 | } 45 | 46 | defaultConfig { 47 | // TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html). 48 | applicationId "com.blackhole.memory" 49 | minSdkVersion 23 50 | targetSdkVersion 31 51 | versionCode flutterVersionCode.toInteger() 52 | versionName flutterVersionName 53 | multiDexEnabled true 54 | } 55 | 56 | signingConfigs { 57 | release { 58 | keyAlias keystoreProperties['keyAlias'] 59 | keyPassword keystoreProperties['keyPassword'] 60 | storeFile keystoreProperties['storeFile'] ? file(keystoreProperties['storeFile']) : null 61 | storePassword keystoreProperties['storePassword'] 62 | } 63 | } 64 | 65 | buildTypes { 66 | release { 67 | // TODO: Add your own signing config for the release build. 68 | // Signing with the debug keys for now, so `flutter run --release` works. 69 | signingConfig signingConfigs.release 70 | } 71 | } 72 | } 73 | 74 | flutter { 75 | source '../..' 76 | } 77 | 78 | dependencies { 79 | implementation platform('com.google.firebase:firebase-bom:26.3.0') 80 | implementation 'com.google.firebase:firebase-analytics' 81 | implementation 'com.google.firebase:firebase-messaging' 82 | implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version" 83 | } 84 | -------------------------------------------------------------------------------- /ios/Runner/GeneratedPluginRegistrant.m: -------------------------------------------------------------------------------- 1 | // 2 | // Generated file. Do not edit. 3 | // 4 | 5 | // clang-format off 6 | 7 | #import "GeneratedPluginRegistrant.h" 8 | 9 | #if __has_include() 10 | #import 11 | #else 12 | @import audioplayers; 13 | #endif 14 | 15 | #if __has_include() 16 | #import 17 | #else 18 | @import cloud_firestore; 19 | #endif 20 | 21 | #if __has_include() 22 | #import 23 | #else 24 | @import firebase_core; 25 | #endif 26 | 27 | #if __has_include() 28 | #import 29 | #else 30 | @import firebase_messaging; 31 | #endif 32 | 33 | #if __has_include() 34 | #import 35 | #else 36 | @import firebase_storage; 37 | #endif 38 | 39 | #if __has_include() 40 | #import 41 | #else 42 | @import google_mobile_ads; 43 | #endif 44 | 45 | #if __has_include() 46 | #import 47 | #else 48 | @import path_provider_ios; 49 | #endif 50 | 51 | #if __has_include() 52 | #import 53 | #else 54 | @import share; 55 | #endif 56 | 57 | #if __has_include() 58 | #import 59 | #else 60 | @import shared_preferences_ios; 61 | #endif 62 | 63 | #if __has_include() 64 | #import 65 | #else 66 | @import url_launcher_ios; 67 | #endif 68 | 69 | @implementation GeneratedPluginRegistrant 70 | 71 | + (void)registerWithRegistry:(NSObject*)registry { 72 | [AudioplayersPlugin registerWithRegistrar:[registry registrarForPlugin:@"AudioplayersPlugin"]]; 73 | [FLTFirebaseFirestorePlugin registerWithRegistrar:[registry registrarForPlugin:@"FLTFirebaseFirestorePlugin"]]; 74 | [FLTFirebaseCorePlugin registerWithRegistrar:[registry registrarForPlugin:@"FLTFirebaseCorePlugin"]]; 75 | [FLTFirebaseMessagingPlugin registerWithRegistrar:[registry registrarForPlugin:@"FLTFirebaseMessagingPlugin"]]; 76 | [FLTFirebaseStoragePlugin registerWithRegistrar:[registry registrarForPlugin:@"FLTFirebaseStoragePlugin"]]; 77 | [FLTGoogleMobileAdsPlugin registerWithRegistrar:[registry registrarForPlugin:@"FLTGoogleMobileAdsPlugin"]]; 78 | [FLTPathProviderPlugin registerWithRegistrar:[registry registrarForPlugin:@"FLTPathProviderPlugin"]]; 79 | [FLTSharePlugin registerWithRegistrar:[registry registrarForPlugin:@"FLTSharePlugin"]]; 80 | [FLTSharedPreferencesPlugin registerWithRegistrar:[registry registrarForPlugin:@"FLTSharedPreferencesPlugin"]]; 81 | [FLTURLLauncherPlugin registerWithRegistrar:[registry registrarForPlugin:@"FLTURLLauncherPlugin"]]; 82 | } 83 | 84 | @end 85 | -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "size" : "20x20", 5 | "idiom" : "iphone", 6 | "filename" : "Icon-App-20x20@2x.png", 7 | "scale" : "2x" 8 | }, 9 | { 10 | "size" : "20x20", 11 | "idiom" : "iphone", 12 | "filename" : "Icon-App-20x20@3x.png", 13 | "scale" : "3x" 14 | }, 15 | { 16 | "size" : "29x29", 17 | "idiom" : "iphone", 18 | "filename" : "Icon-App-29x29@1x.png", 19 | "scale" : "1x" 20 | }, 21 | { 22 | "size" : "29x29", 23 | "idiom" : "iphone", 24 | "filename" : "Icon-App-29x29@2x.png", 25 | "scale" : "2x" 26 | }, 27 | { 28 | "size" : "29x29", 29 | "idiom" : "iphone", 30 | "filename" : "Icon-App-29x29@3x.png", 31 | "scale" : "3x" 32 | }, 33 | { 34 | "size" : "40x40", 35 | "idiom" : "iphone", 36 | "filename" : "Icon-App-40x40@2x.png", 37 | "scale" : "2x" 38 | }, 39 | { 40 | "size" : "40x40", 41 | "idiom" : "iphone", 42 | "filename" : "Icon-App-40x40@3x.png", 43 | "scale" : "3x" 44 | }, 45 | { 46 | "size" : "60x60", 47 | "idiom" : "iphone", 48 | "filename" : "Icon-App-60x60@2x.png", 49 | "scale" : "2x" 50 | }, 51 | { 52 | "size" : "60x60", 53 | "idiom" : "iphone", 54 | "filename" : "Icon-App-60x60@3x.png", 55 | "scale" : "3x" 56 | }, 57 | { 58 | "size" : "20x20", 59 | "idiom" : "ipad", 60 | "filename" : "Icon-App-20x20@1x.png", 61 | "scale" : "1x" 62 | }, 63 | { 64 | "size" : "20x20", 65 | "idiom" : "ipad", 66 | "filename" : "Icon-App-20x20@2x.png", 67 | "scale" : "2x" 68 | }, 69 | { 70 | "size" : "29x29", 71 | "idiom" : "ipad", 72 | "filename" : "Icon-App-29x29@1x.png", 73 | "scale" : "1x" 74 | }, 75 | { 76 | "size" : "29x29", 77 | "idiom" : "ipad", 78 | "filename" : "Icon-App-29x29@2x.png", 79 | "scale" : "2x" 80 | }, 81 | { 82 | "size" : "40x40", 83 | "idiom" : "ipad", 84 | "filename" : "Icon-App-40x40@1x.png", 85 | "scale" : "1x" 86 | }, 87 | { 88 | "size" : "40x40", 89 | "idiom" : "ipad", 90 | "filename" : "Icon-App-40x40@2x.png", 91 | "scale" : "2x" 92 | }, 93 | { 94 | "size" : "76x76", 95 | "idiom" : "ipad", 96 | "filename" : "Icon-App-76x76@1x.png", 97 | "scale" : "1x" 98 | }, 99 | { 100 | "size" : "76x76", 101 | "idiom" : "ipad", 102 | "filename" : "Icon-App-76x76@2x.png", 103 | "scale" : "2x" 104 | }, 105 | { 106 | "size" : "83.5x83.5", 107 | "idiom" : "ipad", 108 | "filename" : "Icon-App-83.5x83.5@2x.png", 109 | "scale" : "2x" 110 | }, 111 | { 112 | "size" : "1024x1024", 113 | "idiom" : "ios-marketing", 114 | "filename" : "Icon-App-1024x1024@1x.png", 115 | "scale" : "1x" 116 | } 117 | ], 118 | "info" : { 119 | "version" : 1, 120 | "author" : "xcode" 121 | } 122 | } 123 | -------------------------------------------------------------------------------- /android/app/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 3 | 8 | 9 | 13 | 21 | 25 | 29 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 49 | 52 | 55 | 56 | 57 | -------------------------------------------------------------------------------- /android/app/src/main/java/io/flutter/plugins/GeneratedPluginRegistrant.java: -------------------------------------------------------------------------------- 1 | package io.flutter.plugins; 2 | 3 | import androidx.annotation.Keep; 4 | import androidx.annotation.NonNull; 5 | import io.flutter.Log; 6 | 7 | import io.flutter.embedding.engine.FlutterEngine; 8 | 9 | /** 10 | * Generated file. Do not edit. 11 | * This file is generated by the Flutter tool based on the 12 | * plugins that support the Android platform. 13 | */ 14 | @Keep 15 | public final class GeneratedPluginRegistrant { 16 | private static final String TAG = "GeneratedPluginRegistrant"; 17 | public static void registerWith(@NonNull FlutterEngine flutterEngine) { 18 | try { 19 | flutterEngine.getPlugins().add(new xyz.luan.audioplayers.AudioplayersPlugin()); 20 | } catch(Exception e) { 21 | Log.e(TAG, "Error registering plugin audioplayers, xyz.luan.audioplayers.AudioplayersPlugin", e); 22 | } 23 | try { 24 | flutterEngine.getPlugins().add(new io.flutter.plugins.firebase.firestore.FlutterFirebaseFirestorePlugin()); 25 | } catch(Exception e) { 26 | Log.e(TAG, "Error registering plugin cloud_firestore, io.flutter.plugins.firebase.firestore.FlutterFirebaseFirestorePlugin", e); 27 | } 28 | try { 29 | flutterEngine.getPlugins().add(new io.flutter.plugins.firebase.core.FlutterFirebaseCorePlugin()); 30 | } catch(Exception e) { 31 | Log.e(TAG, "Error registering plugin firebase_core, io.flutter.plugins.firebase.core.FlutterFirebaseCorePlugin", e); 32 | } 33 | try { 34 | flutterEngine.getPlugins().add(new io.flutter.plugins.firebase.messaging.FlutterFirebaseMessagingPlugin()); 35 | } catch(Exception e) { 36 | Log.e(TAG, "Error registering plugin firebase_messaging, io.flutter.plugins.firebase.messaging.FlutterFirebaseMessagingPlugin", e); 37 | } 38 | try { 39 | flutterEngine.getPlugins().add(new io.flutter.plugins.firebase.storage.FlutterFirebaseStoragePlugin()); 40 | } catch(Exception e) { 41 | Log.e(TAG, "Error registering plugin firebase_storage, io.flutter.plugins.firebase.storage.FlutterFirebaseStoragePlugin", e); 42 | } 43 | try { 44 | flutterEngine.getPlugins().add(new io.flutter.plugins.googlemobileads.GoogleMobileAdsPlugin()); 45 | } catch(Exception e) { 46 | Log.e(TAG, "Error registering plugin google_mobile_ads, io.flutter.plugins.googlemobileads.GoogleMobileAdsPlugin", e); 47 | } 48 | try { 49 | flutterEngine.getPlugins().add(new io.flutter.plugins.pathprovider.PathProviderPlugin()); 50 | } catch(Exception e) { 51 | Log.e(TAG, "Error registering plugin path_provider_android, io.flutter.plugins.pathprovider.PathProviderPlugin", e); 52 | } 53 | try { 54 | flutterEngine.getPlugins().add(new io.flutter.plugins.share.SharePlugin()); 55 | } catch(Exception e) { 56 | Log.e(TAG, "Error registering plugin share, io.flutter.plugins.share.SharePlugin", e); 57 | } 58 | try { 59 | flutterEngine.getPlugins().add(new io.flutter.plugins.sharedpreferences.SharedPreferencesPlugin()); 60 | } catch(Exception e) { 61 | Log.e(TAG, "Error registering plugin shared_preferences_android, io.flutter.plugins.sharedpreferences.SharedPreferencesPlugin", e); 62 | } 63 | try { 64 | flutterEngine.getPlugins().add(new io.flutter.plugins.urllauncher.UrlLauncherPlugin()); 65 | } catch(Exception e) { 66 | Log.e(TAG, "Error registering plugin url_launcher_android, io.flutter.plugins.urllauncher.UrlLauncherPlugin", e); 67 | } 68 | } 69 | } 70 | -------------------------------------------------------------------------------- /pubspec.yaml: -------------------------------------------------------------------------------- 1 | name: memory 2 | description: A new Flutter application. 3 | 4 | # The following line prevents the package from being accidentally published to 5 | # pub.dev using `pub publish`. This is preferred for private packages. 6 | publish_to: 'none' # Remove this line if you wish to publish to pub.dev 7 | 8 | # The following defines the version and build number for your application. 9 | # A version number is three numbers separated by dots, like 1.2.43 10 | # followed by an optional build number separated by a +. 11 | # Both the version and the builder number may be overridden in flutter 12 | # build by specifying --build-name and --build-number, respectively. 13 | # In Android, build-name is used as versionName while build-number used as versionCode. 14 | # Read more about Android versioning at https://developer.android.com/studio/publish/versioning 15 | # In iOS, build-name is used as CFBundleShortVersionString while build-number used as CFBundleVersion. 16 | # Read more about iOS versioning at 17 | # https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html 18 | version: 1.1.20+20 19 | 20 | environment: 21 | sdk: ">=2.7.0 <3.0.0" 22 | 23 | dependencies: 24 | flutter: 25 | sdk: flutter 26 | 27 | # The following adds the Cupertino Icons font to your application. 28 | # Use with the CupertinoIcons class for iOS style icons. 29 | cupertino_icons: ^1.0.2 30 | share: ^2.0.1 31 | animated_text_kit: ^4.1.1 32 | cloud_firestore: ^3.1.11 33 | firebase_core: ^1.0.2 34 | firebase_messaging: ^11.2.12 35 | google_mobile_ads: ^0.12.1+1 36 | url_launcher: ^6.0.3 37 | audioplayers: ^0.20.1 38 | firebase_storage: ^10.2.11 39 | shared_preferences: ^2.0.5 40 | 41 | dev_dependencies: 42 | flutter_test: 43 | sdk: flutter 44 | 45 | # For information on the generic Dart part of this file, see the 46 | # following page: https://dart.dev/tools/pub/pubspec 47 | 48 | # The following section is specific to Flutter. 49 | flutter: 50 | 51 | # The following line ensures that the Material Icons font is 52 | # included with your application, so that you can use the icons in 53 | # the material Icons class. 54 | uses-material-design: true 55 | 56 | # To add assets to your application, add an assets section, like this: 57 | assets: 58 | - asset/images/ 59 | # - images/a_dot_ham.jpeg 60 | 61 | # An image asset can refer to one or more resolution-specific "variants", see 62 | # https://flutter.dev/assets-and-images/#resolution-aware. 63 | 64 | # For details regarding adding assets from package dependencies, see 65 | # https://flutter.dev/assets-and-images/#from-packages 66 | 67 | # To add custom fonts to your application, add a fonts section here, 68 | # in this "flutter" section. Each entry in this list should have a 69 | # "family" key with the font family name, and a "fonts" key with a 70 | # list giving the asset and other descriptors for the font. For 71 | # example: 72 | fonts: 73 | - family: Source 74 | fonts: 75 | - asset: asset/fonts/SourceSansPro-Regular.ttf 76 | # - asset: fonts/Schyler-Italic.ttf 77 | # style: italic 78 | # - family: Trajan Pro 79 | # fonts: 80 | # - asset: fonts/TrajanPro.ttf 81 | # - asset: fonts/TrajanPro_Bold.ttf 82 | # weight: 700 83 | # 84 | # For details regarding fonts from package dependencies, 85 | # see https://flutter.dev/custom-fonts/#from-packages 86 | -------------------------------------------------------------------------------- /ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 9 | 15 | 21 | 22 | 23 | 24 | 25 | 30 | 31 | 32 | 33 | 39 | 40 | 41 | 42 | 43 | 44 | 54 | 56 | 62 | 63 | 64 | 65 | 66 | 67 | 73 | 75 | 81 | 82 | 83 | 84 | 86 | 87 | 90 | 91 | 92 | -------------------------------------------------------------------------------- /android/gradlew: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | ############################################################################## 4 | ## 5 | ## Gradle start up script for UN*X 6 | ## 7 | ############################################################################## 8 | 9 | # Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. 10 | DEFAULT_JVM_OPTS="" 11 | 12 | APP_NAME="Gradle" 13 | APP_BASE_NAME=`basename "$0"` 14 | 15 | # Use the maximum available, or set MAX_FD != -1 to use that value. 16 | MAX_FD="maximum" 17 | 18 | warn ( ) { 19 | echo "$*" 20 | } 21 | 22 | die ( ) { 23 | echo 24 | echo "$*" 25 | echo 26 | exit 1 27 | } 28 | 29 | # OS specific support (must be 'true' or 'false'). 30 | cygwin=false 31 | msys=false 32 | darwin=false 33 | case "`uname`" in 34 | CYGWIN* ) 35 | cygwin=true 36 | ;; 37 | Darwin* ) 38 | darwin=true 39 | ;; 40 | MINGW* ) 41 | msys=true 42 | ;; 43 | esac 44 | 45 | # Attempt to set APP_HOME 46 | # Resolve links: $0 may be a link 47 | PRG="$0" 48 | # Need this for relative symlinks. 49 | while [ -h "$PRG" ] ; do 50 | ls=`ls -ld "$PRG"` 51 | link=`expr "$ls" : '.*-> \(.*\)$'` 52 | if expr "$link" : '/.*' > /dev/null; then 53 | PRG="$link" 54 | else 55 | PRG=`dirname "$PRG"`"/$link" 56 | fi 57 | done 58 | SAVED="`pwd`" 59 | cd "`dirname \"$PRG\"`/" >/dev/null 60 | APP_HOME="`pwd -P`" 61 | cd "$SAVED" >/dev/null 62 | 63 | CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar 64 | 65 | # Determine the Java command to use to start the JVM. 66 | if [ -n "$JAVA_HOME" ] ; then 67 | if [ -x "$JAVA_HOME/jre/sh/java" ] ; then 68 | # IBM's JDK on AIX uses strange locations for the executables 69 | JAVACMD="$JAVA_HOME/jre/sh/java" 70 | else 71 | JAVACMD="$JAVA_HOME/bin/java" 72 | fi 73 | if [ ! -x "$JAVACMD" ] ; then 74 | die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME 75 | 76 | Please set the JAVA_HOME variable in your environment to match the 77 | location of your Java installation." 78 | fi 79 | else 80 | JAVACMD="java" 81 | which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. 82 | 83 | Please set the JAVA_HOME variable in your environment to match the 84 | location of your Java installation." 85 | fi 86 | 87 | # Increase the maximum file descriptors if we can. 88 | if [ "$cygwin" = "false" -a "$darwin" = "false" ] ; then 89 | MAX_FD_LIMIT=`ulimit -H -n` 90 | if [ $? -eq 0 ] ; then 91 | if [ "$MAX_FD" = "maximum" -o "$MAX_FD" = "max" ] ; then 92 | MAX_FD="$MAX_FD_LIMIT" 93 | fi 94 | ulimit -n $MAX_FD 95 | if [ $? -ne 0 ] ; then 96 | warn "Could not set maximum file descriptor limit: $MAX_FD" 97 | fi 98 | else 99 | warn "Could not query maximum file descriptor limit: $MAX_FD_LIMIT" 100 | fi 101 | fi 102 | 103 | # For Darwin, add options to specify how the application appears in the dock 104 | if $darwin; then 105 | GRADLE_OPTS="$GRADLE_OPTS \"-Xdock:name=$APP_NAME\" \"-Xdock:icon=$APP_HOME/media/gradle.icns\"" 106 | fi 107 | 108 | # For Cygwin, switch paths to Windows format before running java 109 | if $cygwin ; then 110 | APP_HOME=`cygpath --path --mixed "$APP_HOME"` 111 | CLASSPATH=`cygpath --path --mixed "$CLASSPATH"` 112 | JAVACMD=`cygpath --unix "$JAVACMD"` 113 | 114 | # We build the pattern for arguments to be converted via cygpath 115 | ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null` 116 | SEP="" 117 | for dir in $ROOTDIRSRAW ; do 118 | ROOTDIRS="$ROOTDIRS$SEP$dir" 119 | SEP="|" 120 | done 121 | OURCYGPATTERN="(^($ROOTDIRS))" 122 | # Add a user-defined pattern to the cygpath arguments 123 | if [ "$GRADLE_CYGPATTERN" != "" ] ; then 124 | OURCYGPATTERN="$OURCYGPATTERN|($GRADLE_CYGPATTERN)" 125 | fi 126 | # Now convert the arguments - kludge to limit ourselves to /bin/sh 127 | i=0 128 | for arg in "$@" ; do 129 | CHECK=`echo "$arg"|egrep -c "$OURCYGPATTERN" -` 130 | CHECK2=`echo "$arg"|egrep -c "^-"` ### Determine if an option 131 | 132 | if [ $CHECK -ne 0 ] && [ $CHECK2 -eq 0 ] ; then ### Added a condition 133 | eval `echo args$i`=`cygpath --path --ignore --mixed "$arg"` 134 | else 135 | eval `echo args$i`="\"$arg\"" 136 | fi 137 | i=$((i+1)) 138 | done 139 | case $i in 140 | (0) set -- ;; 141 | (1) set -- "$args0" ;; 142 | (2) set -- "$args0" "$args1" ;; 143 | (3) set -- "$args0" "$args1" "$args2" ;; 144 | (4) set -- "$args0" "$args1" "$args2" "$args3" ;; 145 | (5) set -- "$args0" "$args1" "$args2" "$args3" "$args4" ;; 146 | (6) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" ;; 147 | (7) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" ;; 148 | (8) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" ;; 149 | (9) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" "$args8" ;; 150 | esac 151 | fi 152 | 153 | # Split up the JVM_OPTS And GRADLE_OPTS values into an array, following the shell quoting and substitution rules 154 | function splitJvmOpts() { 155 | JVM_OPTS=("$@") 156 | } 157 | eval splitJvmOpts $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS 158 | JVM_OPTS[${#JVM_OPTS[*]}]="-Dorg.gradle.appname=$APP_BASE_NAME" 159 | 160 | exec "$JAVACMD" "${JVM_OPTS[@]}" -classpath "$CLASSPATH" org.gradle.wrapper.GradleWrapperMain "$@" 161 | -------------------------------------------------------------------------------- /lib/screen/brain_jam.dart: -------------------------------------------------------------------------------- 1 | import 'dart:math'; 2 | 3 | import 'package:flutter/material.dart'; 4 | 5 | class BrainJam extends StatefulWidget { 6 | @override 7 | _BrainJamState createState() => _BrainJamState(); 8 | } 9 | 10 | class _BrainJamState extends State { 11 | 12 | int inx = -1; 13 | int tap = -1; 14 | 15 | List n = []; 16 | 17 | bool play = false; 18 | 19 | List ans = []; 20 | 21 | // @override 22 | // void initState() { 23 | // super.initState(); 24 | // // put(); 25 | // } 26 | 27 | put(){ 28 | setState(() { 29 | n = []; 30 | ans = []; 31 | }); 32 | for(int i = 0; i < 5; i++){ 33 | setState(() { 34 | n.add(Random().nextInt(20)); 35 | }); 36 | } 37 | print(n); 38 | show(0); 39 | } 40 | 41 | show(int i){ 42 | if(i <= 4){ 43 | Future.delayed(const Duration(milliseconds: 400), () { 44 | setState(() { 45 | inx = n[i]; 46 | }); 47 | print(inx); 48 | // show(i+1); 49 | }).then((value) { 50 | Future.delayed(const Duration(milliseconds: 400), () { 51 | setState(() { 52 | inx = -1; 53 | }); 54 | show(i+1); 55 | }); 56 | }); 57 | }else{ 58 | Future.delayed(const Duration(milliseconds: 300), () { 59 | setState(() { 60 | inx = -1; 61 | play = true; 62 | print("ans"); 63 | }); 64 | }); 65 | } 66 | } 67 | 68 | check(){ 69 | for(int i = 0; i < 5; i++){ 70 | if(n[i] != ans[i]){ 71 | print("Try Again"); 72 | showWinDialog("Try Again"); 73 | break; 74 | }else if(i == 4){ 75 | showWinDialog("Congrats"); 76 | print("Congrats"); 77 | } 78 | } 79 | setState(() { 80 | play = false; 81 | }); 82 | print("n: $n"); 83 | print("ans; $ans"); 84 | } 85 | 86 | 87 | @override 88 | Widget build(BuildContext context) { 89 | double mediaQH = MediaQuery.of(context).size.height; 90 | double mediaQW = MediaQuery.of(context).size.width; 91 | return Container( 92 | decoration: BoxDecoration( 93 | gradient: LinearGradient( 94 | begin: Alignment.topRight, 95 | end: Alignment.bottomLeft, 96 | stops: [0,0.46,1], 97 | colors: [ 98 | Color(0xffFFCC70), 99 | Color(0xffC850C0), 100 | Color(0xff4158D0), 101 | ] 102 | ) 103 | ), 104 | child: Scaffold( 105 | backgroundColor: Colors.transparent, 106 | appBar: AppBar( 107 | centerTitle: true, 108 | backgroundColor: Colors.transparent, 109 | leading: IconButton( 110 | icon: Icon(Icons.arrow_back_ios), 111 | onPressed: (){ 112 | Navigator.of(context).pop(); 113 | }, 114 | ), 115 | title: Text("Level 1", 116 | style: TextStyle( 117 | color: Colors.white, 118 | fontSize: 25, 119 | fontWeight: FontWeight.w600 120 | ), 121 | ), 122 | elevation: 0, 123 | ), 124 | body: Container( 125 | height: mediaQH, 126 | width: mediaQW, 127 | child: Column( 128 | mainAxisAlignment: MainAxisAlignment.spaceEvenly, 129 | crossAxisAlignment: CrossAxisAlignment.center, 130 | children: [ 131 | Padding( 132 | padding: EdgeInsets.all(mediaQW*0.025), 133 | child: GridView.builder( 134 | shrinkWrap: true, 135 | physics: BouncingScrollPhysics(), 136 | itemCount: 20, 137 | gridDelegate: SliverGridDelegateWithFixedCrossAxisCount( 138 | crossAxisCount: 4, 139 | ), 140 | itemBuilder: (context,index){ 141 | return Padding( 142 | padding: EdgeInsets.all(4.0), 143 | child: GestureDetector( 144 | onTap: (){ 145 | if(play == true){ 146 | setState(() { 147 | ans.add(index); 148 | print(index); 149 | if(ans.length == 5){ 150 | check(); 151 | } 152 | }); 153 | } 154 | }, 155 | 156 | onTapDown: (_){ 157 | if(play == true){ 158 | setState(() { 159 | tap = index; 160 | }); 161 | } 162 | }, 163 | 164 | onTapUp: (_){ 165 | if(play == true){ 166 | setState(() { 167 | tap = -1; 168 | }); 169 | } 170 | }, 171 | child: Container( 172 | decoration: BoxDecoration( 173 | color: inx != index ? 174 | tap != index ? 175 | Colors.white : Colors.blue : Colors.red, 176 | borderRadius: BorderRadius.circular(5), 177 | ), 178 | // child: Center(child: Text(index.toString())), 179 | ), 180 | ), 181 | ); 182 | }, 183 | ), 184 | ), 185 | GestureDetector( 186 | onTap: (){ 187 | put(); 188 | }, 189 | child: Container( 190 | color: Colors.transparent, 191 | height: 60, 192 | width: MediaQuery.of(context).size.width*0.5, 193 | child: Card( 194 | shape: RoundedRectangleBorder( 195 | borderRadius: BorderRadius.circular(25), 196 | ), 197 | color: Colors.white, 198 | child: Center( 199 | child: Text("Start", 200 | style: TextStyle( 201 | color: Color(0xffDD2A7B), 202 | fontWeight: FontWeight.w600, 203 | fontSize: 20, 204 | ),), 205 | ), 206 | ), 207 | ), 208 | ), 209 | ], 210 | ), 211 | ), 212 | ), 213 | ); 214 | } 215 | 216 | showWinDialog(String yo) { 217 | showDialog( 218 | context: context, 219 | builder: (BuildContext context) { 220 | return AlertDialog( 221 | title: Center( 222 | child: Text( 223 | yo, 224 | )), 225 | elevation: 5, 226 | shape: RoundedRectangleBorder( 227 | borderRadius: BorderRadius.circular(30), 228 | ), 229 | actions: [ 230 | Row( 231 | children: [ 232 | GestureDetector( 233 | onTap: () { 234 | Navigator.of(context).pop(); 235 | }, 236 | child: Padding( 237 | padding: const EdgeInsets.only(left: 20), 238 | child: Text( 239 | "cancel", 240 | style: TextStyle( 241 | fontSize: 21, 242 | color: Color(0xff151515), 243 | ), 244 | ), 245 | ), 246 | ), 247 | SizedBox( 248 | width: MediaQuery.of(context).size.width * 0.14, 249 | ), 250 | MaterialButton( 251 | elevation: 10, 252 | shape: RoundedRectangleBorder( 253 | borderRadius: BorderRadius.circular(30), 254 | ), 255 | color: Colors.red, 256 | minWidth: 120, 257 | height: 50, 258 | onPressed: () { 259 | Navigator.of(context).pop(); 260 | }, 261 | child: Text( 262 | 'Restart', 263 | style: TextStyle( 264 | fontWeight: FontWeight.bold, 265 | fontSize: 18, 266 | color: Colors.white, 267 | ), 268 | ), 269 | ), 270 | ], 271 | ), 272 | ], 273 | ); 274 | }); 275 | } 276 | 277 | } 278 | -------------------------------------------------------------------------------- /privacy.md: -------------------------------------------------------------------------------- 1 | PRIVACY NOTICE 2 | 3 | Last updated October 07, 2020 4 | 5 | 6 | 7 | Thank you for choosing to be part of our community at BlackHole ("Company", "we", "us", "our"). We are committed to protecting your personal information and your right to privacy. If you have any questions or concerns about this privacy notice, or our practices with regards to your personal information, please contact us at ayush7known@gmail.com. 8 | 9 | When you use our mobile application, as the case may be (the "App") and more generally, use any of our services (the "Services", which include the App), we appreciate that you are trusting us with your personal information. We take your privacy very seriously. In this privacy notice, we seek to explain to you in the clearest way possible what information we collect, how we use it and what rights you have in relation to it. We hope you take some time to read through it carefully, as it is important. If there are any terms in this privacy notice that you do not agree with, please discontinue use of our Services immediately. 10 | 11 | This privacy notice applies to all information collected through our Services (which, as described above, includes our App), as well as, any related services, sales, marketing or events. 12 | 13 | Please read this privacy notice carefully as it will help you understand what we do with the information that we collect. 14 | 15 | TABLE OF CONTENTS 16 | 17 | 1. WHAT INFORMATION DO WE COLLECT? 18 | 2. WILL YOUR INFORMATION BE SHARED WITH ANYONE? 19 | 3. IS YOUR INFORMATION TRANSFERRED INTERNATIONALLY? 20 | 4. WHAT IS OUR STANCE ON THIRD-PARTY WEBSITES? 21 | 5. HOW LONG DO WE KEEP YOUR INFORMATION? 22 | 6. WHAT ARE YOUR PRIVACY RIGHTS? 23 | 7. CONTROLS FOR DO-NOT-TRACK FEATURES 24 | 8. DO CALIFORNIA RESIDENTS HAVE SPECIFIC PRIVACY RIGHTS? 25 | 9. DO WE MAKE UPDATES TO THIS NOTICE? 26 | 10. HOW CAN YOU CONTACT US ABOUT THIS NOTICE? 27 | 11. HOW CAN YOU REVIEW, UPDATE OR DELETE THE DATA WE COLLECT FROM YOU? 28 | 29 | 1. WHAT INFORMATION DO WE COLLECT? 30 | 31 | 2. WILL YOUR INFORMATION BE SHARED WITH ANYONE? 32 | 33 | In Short: We only share information with your consent, to comply with laws, to provide you with services, to protect your rights, or to fulfill business obligations. 34 | 35 | We may process or share your data that we hold based on the following legal basis: 36 | More specifically, we may need to process your data or share your personal information in the following situations: 37 | Business Transfers. We may share or transfer your information in connection with, or during negotiations of, any merger, sale of company assets, financing, or acquisition of all or a portion of our business to another company. 38 | 39 | 3. IS YOUR INFORMATION TRANSFERRED INTERNATIONALLY? 40 | 41 | In Short: We may transfer, store, and process your information in countries other than your own. 42 | 43 | Our servers are located in. If you are accessing our App from outside, please be aware that your information may be transferred to, stored, and processed by us in our facilities and by those third parties with whom we may share your personal information (see "WILL YOUR INFORMATION BE SHARED WITH ANYONE?" above), in and other countries. 44 | 45 | If you are a resident in the European Economic Area, then these countries may not necessarily have data protection laws or other similar laws as comprehensive as those in your country. We will however take all necessary measures to protect your personal information in accordance with this privacy notice and applicable law. 46 | 47 | 4. WHAT IS OUR STANCE ON THIRD-PARTY WEBSITES? 48 | 49 | In Short: We are not responsible for the safety of any information that you share with third-party providers who advertise, but are not affiliated with, our Website. 50 | 51 | The App may contain advertisements from third parties that are not affiliated with us and which may link to other websites, online services or mobile applications. We cannot guarantee the safety and privacy of data you provide to any third parties. Any data collected by third parties is not covered by this privacy notice. We are not responsible for the content or privacy and security practices and policies of any third parties, including other websites, services or applications that may be linked to or from the App. You should review the policies of such third parties and contact them directly to respond to your questions. 52 | 53 | 5. HOW LONG DO WE KEEP YOUR INFORMATION? 54 | 55 | In Short: We keep your information for as long as necessary to fulfill the purposes outlined in this privacy notice unless otherwise required by law. 56 | 57 | We will only keep your personal information for as long as it is necessary for the purposes set out in this privacy notice, unless a longer retention period is required or permitted by law (such as tax, accounting or other legal requirements). No purpose in this notice will require us keeping your personal information for longer than __________. 58 | 59 | When we have no ongoing legitimate business need to process your personal information, we will either delete or anonymize such information, or, if this is not possible (for example, because your personal information has been stored in backup archives), then we will securely store your personal information and isolate it from any further processing until deletion is possible. 60 | 61 | 6. WHAT ARE YOUR PRIVACY RIGHTS? 62 | 63 | In Short: You may review, change, or terminate your account at any time. 64 | 65 | If you are a resident in the European Economic Area and you believe we are unlawfully processing your personal information, you also have the right to complain to your local data protection supervisory authority. You can find their contact details here: http://ec.europa.eu/justice/data-protection/bodies/authorities/index_en.htm. 66 | 67 | If you are a resident in Switzerland, the contact details for the data protection authorities are available here: https://www.edoeb.admin.ch/edoeb/en/home.html. 68 | 69 | 7. CONTROLS FOR DO-NOT-TRACK FEATURES 70 | 71 | Most web browsers and some mobile operating systems and mobile applications include a Do-Not-Track ("DNT") feature or setting you can activate to signal your privacy preference not to have data about your online browsing activities monitored and collected. At this stage no uniform technology standard for recognizing and implementing DNT signals has been finalized. As such, we do not currently respond to DNT browser signals or any other mechanism that automatically communicates your choice not to be tracked online. If a standard for online tracking is adopted that we must follow in the future, we will inform you about that practice in a revised version of this privacy notice. 72 | 73 | 8. DO CALIFORNIA RESIDENTS HAVE SPECIFIC PRIVACY RIGHTS? 74 | 75 | In Short: Yes, if you are a resident of California, you are granted specific rights regarding access to your personal information. 76 | 77 | California Civil Code Section 1798.83, also known as the "Shine The Light" law, permits our users who are California residents to request and obtain from us, once a year and free of charge, information about categories of personal information (if any) we disclosed to third parties for direct marketing purposes and the names and addresses of all third parties with which we shared personal information in the immediately preceding calendar year. If you are a California resident and would like to make such a request, please submit your request in writing to us using the contact information provided below. 78 | 79 | If you are under 18 years of age, reside in California, and have a registered account with the App, you have the right to request removal of unwanted data that you publicly post on the App. To request removal of such data, please contact us using the contact information provided below, and include the email address associated with your account and a statement that you reside in California. We will make sure the data is not publicly displayed on the App, but please be aware that the data may not be completely or comprehensively removed from all our systems (e.g. backups, etc.). 80 | 81 | 9. DO WE MAKE UPDATES TO THIS NOTICE? 82 | 83 | In Short: Yes, we will update this notice as necessary to stay compliant with relevant laws. 84 | 85 | We may update this privacy notice from time to time. The updated version will be indicated by an updated "Revised" date and the updated version will be effective as soon as it is accessible. If we make material changes to this privacy notice, we may notify you either by prominently posting a notice of such changes or by directly sending you a notification. We encourage you to review this privacy notice frequently to be informed of how we are protecting your information. 86 | 87 | 10. HOW CAN YOU CONTACT US ABOUT THIS NOTICE? 88 | 89 | If you have questions or comments about this notice, you may email us at ayush7known@gmail.com or by post to: 90 | 91 | 92 | India 93 | 94 | 11. HOW CAN YOU REVIEW, UPDATE, OR DELETE THE DATA WE COLLECT FROM YOU? 95 | 96 | Based on the applicable laws of your country, you may have the right to request access to the personal information we collect from you, change that information, or delete it in some circumstances. To request to review, update, or delete your personal information, please submit a request form by clicking here. We will respond to your request within 30 days. 97 | This privacy policy was created using Termly’s Privacy Policy Generator. 98 | -------------------------------------------------------------------------------- /lib/screen/setting.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:google_mobile_ads/google_mobile_ads.dart'; 3 | import 'package:memory/data/data.dart'; 4 | import 'package:memory/screen/high%20score.dart'; 5 | import 'package:shared_preferences/shared_preferences.dart'; 6 | 7 | import 'help.dart'; 8 | import 'home screen.dart'; 9 | 10 | class Setting extends StatefulWidget { 11 | @override 12 | _SettingState createState() => _SettingState(); 13 | } 14 | 15 | class _SettingState extends State { 16 | 17 | bool isLoaded = false; 18 | 19 | @override 20 | void initState() { 21 | super.initState(); 22 | if(Data.showAds == true){ 23 | bannerAds(); 24 | } 25 | } 26 | 27 | BannerAd _ad; 28 | 29 | bannerAds(){ 30 | _ad = BannerAd( 31 | adUnitId: "ca-app-pub-3028010056599796/1626317951", 32 | size: AdSize.mediumRectangle, 33 | request: AdRequest( 34 | keywords: ["amazon", "games", "land", "collage","toys","learn","coding","food"], 35 | ), 36 | listener: AdListener( 37 | onAdLoaded: (_){ 38 | setState(() { 39 | isLoaded = true; 40 | }); 41 | }, 42 | onAdFailedToLoad: (_ad,error){ 43 | } 44 | ), 45 | ); 46 | _ad.load(); 47 | } 48 | 49 | checkForAd(){ 50 | if(isLoaded == true){ 51 | return Container( 52 | child: Center( 53 | child: AdWidget( 54 | ad: _ad, 55 | ), 56 | ), 57 | height: 250, 58 | width: 320, 59 | alignment: Alignment.center, 60 | ); 61 | }else{ 62 | return Container( 63 | height: 250, 64 | width: 320, 65 | ); 66 | } 67 | } 68 | 69 | musicStop() async{ 70 | SharedPreferences myPrefs = await SharedPreferences.getInstance(); 71 | myPrefs.setBool("play", Data.neverPlay); 72 | } 73 | 74 | @override 75 | Widget build(BuildContext context) { 76 | return Container( 77 | decoration: BoxDecoration( 78 | gradient: LinearGradient( 79 | begin: Alignment.topRight, 80 | end: Alignment.bottomLeft, 81 | 82 | stops: [0,0.46,1], 83 | 84 | colors: [ 85 | Color(0xffFFCC70), 86 | Color(0xffC850C0), 87 | Color(0xff4158D0), 88 | ] 89 | ) 90 | ), 91 | child: Scaffold( 92 | backgroundColor: Colors.transparent, 93 | appBar: AppBar( 94 | backgroundColor: Colors.transparent, 95 | centerTitle: true, 96 | leading: IconButton( 97 | icon: Icon(Icons.arrow_back_ios), 98 | onPressed: (){ 99 | Navigator.of(context).pop(); 100 | }, 101 | ), 102 | title: Text("Settings", 103 | style: TextStyle( 104 | color: Colors.white, 105 | fontSize: 25, 106 | fontWeight: FontWeight.w600 107 | ),), 108 | elevation: 0, 109 | ), 110 | body: Container( 111 | height: MediaQuery.of(context).size.height, 112 | width: MediaQuery.of(context).size.width, 113 | color: Colors.transparent, 114 | child: Column( 115 | crossAxisAlignment: CrossAxisAlignment.center, 116 | mainAxisAlignment: MainAxisAlignment.start, 117 | children: [ 118 | Padding( 119 | padding: const EdgeInsets.only(top: 20), 120 | child: Container( 121 | height: 70, 122 | width: MediaQuery.of(context).size.width*0.9, 123 | color: Colors.transparent, 124 | child: Card( 125 | shape: RoundedRectangleBorder( 126 | borderRadius: BorderRadius.circular(15), 127 | ), 128 | color: Colors.white, 129 | child: Center( 130 | child: Row( 131 | mainAxisAlignment: MainAxisAlignment.spaceEvenly, 132 | crossAxisAlignment: CrossAxisAlignment.center, 133 | children: [ 134 | Text("Music", 135 | style: TextStyle( 136 | color: Color(0xffDD2A7B), 137 | fontWeight: FontWeight.w600, 138 | fontSize: 20, 139 | ),), 140 | Switch( 141 | value: Data.neverPlay == false ? true : false, 142 | onChanged: (value){ 143 | setState(() { 144 | if(Data.neverPlay == false){ 145 | setState(() { 146 | audioPlayer.pause(); 147 | Data.neverPlay = true; 148 | musicStop(); 149 | }); 150 | }else{ 151 | setState(() { 152 | audioPlayer.resume(); 153 | Data.neverPlay = false; 154 | musicStop(); 155 | }); 156 | } 157 | }); 158 | }, 159 | activeTrackColor: Color(0xffDD2A7B), 160 | activeColor: Colors.white, 161 | inactiveTrackColor: Colors.grey, 162 | ), 163 | ], 164 | ), 165 | ), 166 | ), 167 | ), 168 | ), 169 | Padding( 170 | padding: const EdgeInsets.only(top: 15), 171 | child: GestureDetector( 172 | onTap: (){ 173 | Navigator.push(context, MaterialPageRoute(builder: (context) { 174 | return Help(); 175 | },)); 176 | }, 177 | child: Container( 178 | color: Colors.transparent, 179 | height: 60, 180 | width: MediaQuery.of(context).size.width*0.5, 181 | child: Card( 182 | shape: RoundedRectangleBorder( 183 | borderRadius: BorderRadius.circular(25), 184 | ), 185 | color: Colors.white, 186 | child: Center( 187 | child: Text("About us", 188 | style: TextStyle( 189 | color: Color(0xffDD2A7B), 190 | fontWeight: FontWeight.w600, 191 | fontSize: 20, 192 | ),), 193 | ), 194 | ), 195 | ), 196 | ), 197 | ), 198 | Padding( 199 | padding: const EdgeInsets.only(top: 15), 200 | child: GestureDetector( 201 | onTap: (){ 202 | Navigator.push(context, MaterialPageRoute(builder: (context) { 203 | return HighScore(); 204 | },)); 205 | }, 206 | child: Container( 207 | color: Colors.transparent, 208 | height: 60, 209 | width: MediaQuery.of(context).size.width*0.5, 210 | child: Card( 211 | shape: RoundedRectangleBorder( 212 | borderRadius: BorderRadius.circular(25), 213 | ), 214 | color: Colors.white, 215 | child: Center( 216 | child: Text("High Score", 217 | style: TextStyle( 218 | color: Color(0xffDD2A7B), 219 | fontWeight: FontWeight.w600, 220 | fontSize: 20, 221 | ),), 222 | ), 223 | ), 224 | ), 225 | ), 226 | ), 227 | SizedBox(height: 15,), 228 | Container( 229 | height: 100, 230 | width: MediaQuery.of(context).size.width*0.9, 231 | color: Colors.transparent, 232 | child: Card( 233 | shape: RoundedRectangleBorder( 234 | borderRadius: BorderRadius.circular(15), 235 | ), 236 | elevation: 10, 237 | child: Center( 238 | child: Text(" If Ads are bothering try playing\n" 239 | " without internet. Subscription will\n" 240 | " be added soon. Thank you", 241 | style: TextStyle( 242 | fontSize: 16, 243 | fontWeight: FontWeight.w600, 244 | color: Color(0xffDD2A7B), 245 | ),), 246 | ), 247 | ), 248 | ), 249 | SizedBox(height: 15,), 250 | checkForAd(), 251 | ], 252 | ), 253 | ), 254 | ), 255 | ); 256 | } 257 | } 258 | -------------------------------------------------------------------------------- /lib/screen/high score.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:memory/data/data.dart'; 3 | import 'package:memory/screen/memoryGame.dart'; 4 | 5 | class HighScore extends StatefulWidget { 6 | @override 7 | _HighScoreState createState() => _HighScoreState(); 8 | } 9 | 10 | class _HighScoreState extends State { 11 | @override 12 | Widget build(BuildContext context) { 13 | return Container( 14 | decoration: BoxDecoration( 15 | gradient: LinearGradient( 16 | begin: Alignment.topRight, 17 | end: Alignment.bottomLeft, 18 | stops: [0,0.46,1], 19 | colors: [ 20 | Color(0xffFFCC70), 21 | Color(0xffC850C0), 22 | Color(0xff4158D0), 23 | ] 24 | ) 25 | ), 26 | child: Scaffold( 27 | backgroundColor: Colors.transparent, 28 | appBar: AppBar( 29 | title: Text("High Score", 30 | style: TextStyle( 31 | color: Colors.white, 32 | fontSize: 25, 33 | fontWeight: FontWeight.w600, 34 | ),), 35 | leading: IconButton( 36 | color: Colors.white, 37 | icon: Icon(Icons.arrow_back_ios), 38 | onPressed: (){ 39 | Navigator.of(context).pop(); 40 | }, 41 | ), 42 | centerTitle: true, 43 | backgroundColor: Colors.transparent, 44 | elevation: 0, 45 | ), 46 | body: Center( 47 | child: Column( 48 | crossAxisAlignment: CrossAxisAlignment.center, 49 | mainAxisAlignment: MainAxisAlignment.spaceEvenly, 50 | children: [ 51 | Container( 52 | height: MediaQuery.of(context).size.height*0.21, 53 | width: MediaQuery.of(context).size.width*0.85, 54 | child: Card( 55 | margin: EdgeInsets.all(0), 56 | shape: RoundedRectangleBorder( 57 | borderRadius: BorderRadius.circular(20), 58 | ), 59 | elevation: 10, 60 | color: Color(0xffDD2A7B), 61 | child: Stack( 62 | children: [ 63 | Positioned( 64 | top: 20, 65 | left: 12, 66 | child: Column( 67 | mainAxisAlignment: MainAxisAlignment.start, 68 | crossAxisAlignment: CrossAxisAlignment.start, 69 | children: [ 70 | Text("Pokemon", 71 | style: TextStyle( 72 | color: Colors.white, 73 | fontSize: 22, 74 | fontWeight: FontWeight.w600, 75 | ),), 76 | Padding( 77 | padding: const EdgeInsets.only(top: 4), 78 | child: Text("${Data.highScoreInPokemon} turns in ${Data.timeInPokemon}", 79 | style: TextStyle( 80 | color: Colors.white, 81 | fontSize: 21, 82 | fontWeight: FontWeight.w600, 83 | ), 84 | ), 85 | ), 86 | ], 87 | ), 88 | ), 89 | Positioned( 90 | top: -35, 91 | right: -30, 92 | child: CircleAvatar( 93 | radius: 90, 94 | backgroundColor: Colors.white.withOpacity(0.12), 95 | child: CircleAvatar( 96 | radius: 70, 97 | backgroundColor: Colors.white.withOpacity(0.2), 98 | child: CircleAvatar( 99 | radius: 52, 100 | backgroundColor: Colors.white.withOpacity(0.18), 101 | child: CircleAvatar( 102 | radius: 40, 103 | child: Image.asset("asset/images/3.png", 104 | width: 65,), 105 | backgroundColor: Color(0xffDD2A7B), 106 | ), 107 | ), 108 | ), 109 | ), 110 | ), 111 | ], 112 | ), 113 | ), 114 | ), 115 | Container( 116 | height: MediaQuery.of(context).size.height*0.21, 117 | width: MediaQuery.of(context).size.width*0.85, 118 | child: Card( 119 | margin: EdgeInsets.all(0), 120 | shape: RoundedRectangleBorder( 121 | borderRadius: BorderRadius.circular(20), 122 | ), 123 | elevation: 10, 124 | color: Color(0xffDD2A7B), 125 | child: Stack( 126 | children: [ 127 | Positioned( 128 | top: 20, 129 | left: 12, 130 | child: Column( 131 | mainAxisAlignment: MainAxisAlignment.start, 132 | crossAxisAlignment: CrossAxisAlignment.start, 133 | children: [ 134 | Text("Emoji", 135 | style: TextStyle( 136 | color: Colors.white, 137 | fontSize: 22, 138 | fontWeight: FontWeight.w600, 139 | ),), 140 | Padding( 141 | padding: const EdgeInsets.only(top: 4), 142 | child: Text("${Data.highScoreInEmoji} turns in ${Data.timeInEmoji}", 143 | style: TextStyle( 144 | color: Colors.white, 145 | fontSize: 21, 146 | fontWeight: FontWeight.w600, 147 | ), 148 | ), 149 | ), 150 | ], 151 | ), 152 | ), 153 | Positioned( 154 | top: -35, 155 | right: -30, 156 | child: CircleAvatar( 157 | radius: 90, 158 | backgroundColor: Colors.white.withOpacity(0.12), 159 | child: CircleAvatar( 160 | radius: 70, 161 | backgroundColor: Colors.white.withOpacity(0.2), 162 | child: CircleAvatar( 163 | radius: 52, 164 | backgroundColor: Colors.white.withOpacity(0.18), 165 | child: CircleAvatar( 166 | radius: 40, 167 | child: Text("😃", 168 | style: TextStyle( 169 | fontSize: 45, 170 | ),), 171 | backgroundColor: Color(0xffDD2A7B), 172 | ), 173 | ), 174 | ), 175 | ), 176 | ), 177 | ], 178 | ), 179 | ), 180 | ), 181 | Container( 182 | height: MediaQuery.of(context).size.height*0.21, 183 | width: MediaQuery.of(context).size.width*0.85, 184 | color: Colors.transparent, 185 | child: Card( 186 | margin: EdgeInsets.all(0), 187 | shape: RoundedRectangleBorder( 188 | borderRadius: BorderRadius.circular(20), 189 | ), 190 | elevation: 10, 191 | color: Color(0xffDD2A7B), 192 | child: Stack( 193 | children: [ 194 | Positioned( 195 | top: 20, 196 | left: 12, 197 | child: Column( 198 | mainAxisAlignment: MainAxisAlignment.start, 199 | crossAxisAlignment: CrossAxisAlignment.start, 200 | children: [ 201 | Text("Number", 202 | style: TextStyle( 203 | color: Colors.white, 204 | fontSize: 22, 205 | fontWeight: FontWeight.w600, 206 | ),), 207 | Padding( 208 | padding: const EdgeInsets.only(top: 4), 209 | child: Text("${Data.highScoreInNumber} turns in ${Data.timeInNumber}", 210 | style: TextStyle( 211 | color: Colors.white, 212 | fontSize: 21, 213 | fontWeight: FontWeight.w600, 214 | ), 215 | ), 216 | ), 217 | ], 218 | ), 219 | ), 220 | Positioned( 221 | top: -35, 222 | right: -30, 223 | child: CircleAvatar( 224 | radius: 90, 225 | backgroundColor: Colors.white.withOpacity(0.12), 226 | child: CircleAvatar( 227 | radius: 70, 228 | backgroundColor: Colors.white.withOpacity(0.2), 229 | child: CircleAvatar( 230 | radius: 52, 231 | backgroundColor: Colors.white.withOpacity(0.18), 232 | child: CircleAvatar( 233 | radius: 40, 234 | child: Text("7", 235 | style: TextStyle( 236 | fontSize: 45, 237 | color: Colors.white, 238 | fontWeight: FontWeight.w600 239 | ),), 240 | backgroundColor: Color(0xffDD2A7B), 241 | ), 242 | ), 243 | ), 244 | ), 245 | ), 246 | ], 247 | ), 248 | ), 249 | ), 250 | GestureDetector( 251 | onTap: (){ 252 | Navigator.pushReplacement(context, MaterialPageRoute(builder: (context){ 253 | return Memory(); 254 | })); 255 | }, 256 | child: Container( 257 | width: MediaQuery.of(context).size.width*0.9, 258 | height: 55, 259 | decoration: BoxDecoration( 260 | color: Color(0xffDD2A7B), 261 | borderRadius: BorderRadius.circular(15), 262 | ), 263 | child: Center( 264 | child: Text("Play", 265 | style: TextStyle( 266 | color: Colors.white, 267 | fontWeight: FontWeight.w600, 268 | fontSize: 25 269 | ),), 270 | ), 271 | ), 272 | ), 273 | ], 274 | ), 275 | ), 276 | ), 277 | ); 278 | } 279 | } 280 | -------------------------------------------------------------------------------- /lib/screen/help.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:url_launcher/url_launcher.dart'; 3 | import 'package:cloud_firestore/cloud_firestore.dart'; 4 | import 'package:firebase_core/firebase_core.dart'; 5 | 6 | class Help extends StatefulWidget { 7 | @override 8 | _HelpState createState() => _HelpState(); 9 | } 10 | 11 | class _HelpState extends State { 12 | 13 | final _scaffoldKey = GlobalKey(); 14 | final fireStore = Firebase.initializeApp(); 15 | 16 | socialMedias(String s) async{ 17 | fireStore.then((value) async { 18 | FirebaseFirestore.instance. 19 | collection("memory").doc("1") 20 | .get().then((result){ 21 | if(result.get(s) == ""){ 22 | snackBar("We don't have $s account try Instagram"); 23 | }else{ 24 | launch(result.get(s)); 25 | } 26 | }); 27 | }); 28 | } 29 | 30 | mail(String s) async{ 31 | await launch(s); 32 | } 33 | 34 | snackBar(String s){ 35 | // ignore: deprecated_member_use 36 | _scaffoldKey.currentState.showSnackBar( 37 | SnackBar(duration: Duration(milliseconds: 2000),backgroundColor: Colors.white, 38 | padding: EdgeInsets.only(left: 25), 39 | shape: RoundedRectangleBorder(borderRadius: BorderRadius.circular(15)), 40 | content: Text(s, 41 | style: TextStyle( 42 | color: Colors.black, fontSize: 16, 43 | fontWeight: FontWeight.w600),), 44 | behavior: SnackBarBehavior.floating)); 45 | } 46 | 47 | 48 | @override 49 | Widget build(BuildContext context) { 50 | return Container( 51 | decoration: BoxDecoration( 52 | gradient: LinearGradient( 53 | begin: Alignment.topRight, 54 | end: Alignment.bottomLeft, 55 | stops: [0,0.46,1], 56 | colors: [ 57 | Color(0xffFFCC70), 58 | Color(0xffC850C0), 59 | Color(0xff4158D0), 60 | ] 61 | ) 62 | ), 63 | child: Scaffold( 64 | key: _scaffoldKey, 65 | backgroundColor: Colors.transparent, 66 | appBar: AppBar( 67 | title: Text("About", 68 | style: TextStyle( 69 | // fontFamily: Data.font, 70 | color: Colors.white, 71 | fontSize: 25, 72 | fontWeight: FontWeight.w600, 73 | ),), 74 | centerTitle: true, 75 | elevation: 0, 76 | backgroundColor: Colors.transparent, 77 | leading: IconButton( 78 | icon: Icon(Icons.arrow_back_ios, 79 | color: Colors.white, 80 | ), 81 | onPressed: (){ 82 | Navigator.of(context).pop(); 83 | }, 84 | ), 85 | ), 86 | body: SingleChildScrollView( 87 | physics: BouncingScrollPhysics(), 88 | child: Stack( 89 | alignment: Alignment.center, 90 | children: [ 91 | Container( 92 | height: MediaQuery.of(context).size.height*1.1, 93 | ), 94 | Positioned( 95 | top: 10, 96 | child: Container( 97 | height: MediaQuery.of(context).size.height*0.28, 98 | width: MediaQuery.of(context).size.width*0.97, 99 | child: Card( 100 | elevation: 0, 101 | color: Colors.white, 102 | shape: RoundedRectangleBorder( 103 | borderRadius: BorderRadius.circular(25), 104 | ), 105 | child: Column( 106 | mainAxisAlignment: MainAxisAlignment.spaceEvenly, 107 | crossAxisAlignment: CrossAxisAlignment.center, 108 | children: [ 109 | Text("Version Details", 110 | style: TextStyle( 111 | fontSize: 24, 112 | color: Colors.black.withOpacity(0.7), 113 | ),), 114 | Text("v1.1.20", 115 | style: TextStyle( 116 | fontSize: 22, 117 | color: Colors.black.withOpacity(0.7), 118 | ),), 119 | GestureDetector( 120 | onTap: (){ 121 | showAboutDialog( 122 | context: context, 123 | applicationVersion: "1.1.20", 124 | ); 125 | }, 126 | child: Container( 127 | height: 55, 128 | width: 180, 129 | child: Card( 130 | shape: RoundedRectangleBorder( 131 | borderRadius: BorderRadius.circular(10), 132 | side: BorderSide(color: Colors.black26), 133 | ), 134 | color: Colors.white, 135 | child: Center( 136 | child: Text("LICENSES", 137 | style: TextStyle( 138 | fontSize: 18, 139 | color: Colors.black45, 140 | ),)), 141 | ), 142 | ), 143 | ), 144 | ], 145 | ), 146 | ), 147 | ), 148 | ), 149 | Positioned( 150 | top: MediaQuery.of(context).size.height*0.3, 151 | child: Container( 152 | height: MediaQuery.of(context).size.height*0.5, 153 | width: MediaQuery.of(context).size.width*0.97, 154 | child: Card( 155 | color: Colors.white, 156 | shape: RoundedRectangleBorder( 157 | borderRadius: BorderRadius.circular(25), 158 | ), 159 | child: Column( 160 | mainAxisAlignment: MainAxisAlignment.spaceEvenly, 161 | crossAxisAlignment: CrossAxisAlignment.center, 162 | children: [ 163 | Text("Social Media", 164 | style: TextStyle( 165 | fontSize: 24, 166 | // fontFamily: Data.font, 167 | color: Colors.black.withOpacity(0.7), 168 | ),), 169 | Padding( 170 | padding: const EdgeInsets.only( 171 | left: 15, 172 | right: 15 173 | ), 174 | child: Text( 175 | "If you enjoy using Memory Game or want to know more about it, consider " 176 | "following us on different social medias. You will get all the latest news " 177 | "regarding to updates or ask any query we will always there to help you.", 178 | style: TextStyle( 179 | fontSize: 15, 180 | color: Colors.black.withOpacity(0.5), 181 | ),), 182 | ), 183 | Column( 184 | children: [ 185 | GestureDetector( 186 | onTap: () { 187 | socialMedias("instagram"); 188 | }, 189 | child: Container( 190 | height: 50, 191 | width: MediaQuery.of(context).size.width*0.8, 192 | child: Card( 193 | shape: RoundedRectangleBorder( 194 | borderRadius: BorderRadius.circular(15), 195 | side: BorderSide(color: Colors.red.shade300), 196 | ), 197 | color: Colors.white, 198 | child: Center(child: Text("Follow us on Instagram", 199 | style: TextStyle( 200 | fontSize: 18, 201 | color: Colors.red.shade800 202 | ),)), 203 | ), 204 | ), 205 | ), 206 | SizedBox(height: 6,), 207 | GestureDetector( 208 | onTap: (){ 209 | socialMedias("twitter"); 210 | }, 211 | child: Container( 212 | height: 50, 213 | width: MediaQuery.of(context).size.width*0.8, 214 | child: Card( 215 | shape: RoundedRectangleBorder( 216 | borderRadius: BorderRadius.circular(15), 217 | side: BorderSide(color: Colors.blue.shade400), 218 | ), 219 | color: Colors.white, 220 | child: Center(child: Text("Follow us on Twitter", 221 | style: TextStyle( 222 | fontSize: 18, 223 | fontWeight: FontWeight.w600, 224 | color: Colors.blue 225 | ),)), 226 | ), 227 | ), 228 | ), 229 | SizedBox(height: 6,), 230 | GestureDetector( 231 | onTap: (){ 232 | socialMedias("facebook"); 233 | }, 234 | child: Container( 235 | height: 50, 236 | width: MediaQuery.of(context).size.width*0.8, 237 | child: Card( 238 | shape: RoundedRectangleBorder( 239 | borderRadius: BorderRadius.circular(15), 240 | side: BorderSide(color: Colors.blue.shade800), 241 | ), 242 | color: Colors.white, 243 | child: Center(child: Text("Follow us on Facebook", 244 | style: TextStyle( 245 | fontSize: 18, 246 | fontWeight: FontWeight.w600, 247 | color: Colors.blue.shade900 248 | ),)), 249 | ), 250 | ), 251 | ), 252 | ], 253 | ), 254 | ], 255 | ), 256 | ), 257 | ), 258 | ), 259 | Positioned( 260 | top: MediaQuery.of(context).size.height*0.81, 261 | child: Container( 262 | height: MediaQuery.of(context).size.height*0.28, 263 | width: MediaQuery.of(context).size.width*0.97, 264 | child: Card( 265 | color: Colors.white, 266 | shape: RoundedRectangleBorder( 267 | borderRadius: BorderRadius.circular(25), 268 | ), 269 | child: Column( 270 | mainAxisAlignment: MainAxisAlignment.spaceEvenly, 271 | crossAxisAlignment: CrossAxisAlignment.center, 272 | children: [ 273 | Text("Feedback", 274 | style: TextStyle( 275 | fontSize: 23, 276 | color: Colors.black.withOpacity(0.7), 277 | ),), 278 | Padding( 279 | padding: const EdgeInsets.only( 280 | left: 15, 281 | right: 15, 282 | ), 283 | child: Text( 284 | "Give us feedback to improve the app\n" 285 | " or Ask query", 286 | style: TextStyle( 287 | fontSize: 15, 288 | color: Colors.black.withOpacity(0.5), 289 | ),), 290 | ), 291 | GestureDetector( 292 | onTap: (){ 293 | mail("mailto:ayush7known@gmail.com"); 294 | }, 295 | child: Container( 296 | height: 60, 297 | width: MediaQuery.of(context).size.width*0.8, 298 | child: Card( 299 | shape: RoundedRectangleBorder( 300 | borderRadius: BorderRadius.circular(20), 301 | ), 302 | color: Colors.blue, 303 | child: Center(child: Text("Help & Feedback", 304 | style: TextStyle( 305 | fontSize: 20, 306 | color: Colors.white, 307 | fontWeight: FontWeight.w600, 308 | ),)), 309 | ), 310 | ), 311 | ), 312 | ], 313 | ), 314 | ), 315 | ), 316 | ), 317 | ], 318 | ), 319 | ), 320 | ), 321 | ); 322 | } 323 | } 324 | -------------------------------------------------------------------------------- /pubspec.lock: -------------------------------------------------------------------------------- 1 | # Generated by pub 2 | # See https://dart.dev/tools/pub/glossary#lockfile 3 | packages: 4 | animated_text_kit: 5 | dependency: "direct main" 6 | description: 7 | name: animated_text_kit 8 | url: "https://pub.dartlang.org" 9 | source: hosted 10 | version: "4.2.1" 11 | async: 12 | dependency: transitive 13 | description: 14 | name: async 15 | url: "https://pub.dartlang.org" 16 | source: hosted 17 | version: "2.8.2" 18 | audioplayers: 19 | dependency: "direct main" 20 | description: 21 | name: audioplayers 22 | url: "https://pub.dartlang.org" 23 | source: hosted 24 | version: "0.20.1" 25 | boolean_selector: 26 | dependency: transitive 27 | description: 28 | name: boolean_selector 29 | url: "https://pub.dartlang.org" 30 | source: hosted 31 | version: "2.1.0" 32 | characters: 33 | dependency: transitive 34 | description: 35 | name: characters 36 | url: "https://pub.dartlang.org" 37 | source: hosted 38 | version: "1.2.0" 39 | charcode: 40 | dependency: transitive 41 | description: 42 | name: charcode 43 | url: "https://pub.dartlang.org" 44 | source: hosted 45 | version: "1.3.1" 46 | clock: 47 | dependency: transitive 48 | description: 49 | name: clock 50 | url: "https://pub.dartlang.org" 51 | source: hosted 52 | version: "1.1.0" 53 | cloud_firestore: 54 | dependency: "direct main" 55 | description: 56 | name: cloud_firestore 57 | url: "https://pub.dartlang.org" 58 | source: hosted 59 | version: "3.1.11" 60 | cloud_firestore_platform_interface: 61 | dependency: transitive 62 | description: 63 | name: cloud_firestore_platform_interface 64 | url: "https://pub.dartlang.org" 65 | source: hosted 66 | version: "5.5.2" 67 | cloud_firestore_web: 68 | dependency: transitive 69 | description: 70 | name: cloud_firestore_web 71 | url: "https://pub.dartlang.org" 72 | source: hosted 73 | version: "2.6.11" 74 | collection: 75 | dependency: transitive 76 | description: 77 | name: collection 78 | url: "https://pub.dartlang.org" 79 | source: hosted 80 | version: "1.15.0" 81 | crypto: 82 | dependency: transitive 83 | description: 84 | name: crypto 85 | url: "https://pub.dartlang.org" 86 | source: hosted 87 | version: "3.0.1" 88 | cupertino_icons: 89 | dependency: "direct main" 90 | description: 91 | name: cupertino_icons 92 | url: "https://pub.dartlang.org" 93 | source: hosted 94 | version: "1.0.4" 95 | fake_async: 96 | dependency: transitive 97 | description: 98 | name: fake_async 99 | url: "https://pub.dartlang.org" 100 | source: hosted 101 | version: "1.2.0" 102 | ffi: 103 | dependency: transitive 104 | description: 105 | name: ffi 106 | url: "https://pub.dartlang.org" 107 | source: hosted 108 | version: "1.1.2" 109 | file: 110 | dependency: transitive 111 | description: 112 | name: file 113 | url: "https://pub.dartlang.org" 114 | source: hosted 115 | version: "6.1.2" 116 | firebase_core: 117 | dependency: "direct main" 118 | description: 119 | name: firebase_core 120 | url: "https://pub.dartlang.org" 121 | source: hosted 122 | version: "1.14.0" 123 | firebase_core_platform_interface: 124 | dependency: transitive 125 | description: 126 | name: firebase_core_platform_interface 127 | url: "https://pub.dartlang.org" 128 | source: hosted 129 | version: "4.2.5" 130 | firebase_core_web: 131 | dependency: transitive 132 | description: 133 | name: firebase_core_web 134 | url: "https://pub.dartlang.org" 135 | source: hosted 136 | version: "1.6.1" 137 | firebase_messaging: 138 | dependency: "direct main" 139 | description: 140 | name: firebase_messaging 141 | url: "https://pub.dartlang.org" 142 | source: hosted 143 | version: "11.2.12" 144 | firebase_messaging_platform_interface: 145 | dependency: transitive 146 | description: 147 | name: firebase_messaging_platform_interface 148 | url: "https://pub.dartlang.org" 149 | source: hosted 150 | version: "3.2.2" 151 | firebase_messaging_web: 152 | dependency: transitive 153 | description: 154 | name: firebase_messaging_web 155 | url: "https://pub.dartlang.org" 156 | source: hosted 157 | version: "2.2.10" 158 | firebase_storage: 159 | dependency: "direct main" 160 | description: 161 | name: firebase_storage 162 | url: "https://pub.dartlang.org" 163 | source: hosted 164 | version: "10.2.11" 165 | firebase_storage_platform_interface: 166 | dependency: transitive 167 | description: 168 | name: firebase_storage_platform_interface 169 | url: "https://pub.dartlang.org" 170 | source: hosted 171 | version: "4.1.2" 172 | firebase_storage_web: 173 | dependency: transitive 174 | description: 175 | name: firebase_storage_web 176 | url: "https://pub.dartlang.org" 177 | source: hosted 178 | version: "3.2.11" 179 | flutter: 180 | dependency: "direct main" 181 | description: flutter 182 | source: sdk 183 | version: "0.0.0" 184 | flutter_test: 185 | dependency: "direct dev" 186 | description: flutter 187 | source: sdk 188 | version: "0.0.0" 189 | flutter_web_plugins: 190 | dependency: transitive 191 | description: flutter 192 | source: sdk 193 | version: "0.0.0" 194 | google_mobile_ads: 195 | dependency: "direct main" 196 | description: 197 | name: google_mobile_ads 198 | url: "https://pub.dartlang.org" 199 | source: hosted 200 | version: "0.12.2+1" 201 | http: 202 | dependency: transitive 203 | description: 204 | name: http 205 | url: "https://pub.dartlang.org" 206 | source: hosted 207 | version: "0.13.4" 208 | http_parser: 209 | dependency: transitive 210 | description: 211 | name: http_parser 212 | url: "https://pub.dartlang.org" 213 | source: hosted 214 | version: "4.0.0" 215 | js: 216 | dependency: transitive 217 | description: 218 | name: js 219 | url: "https://pub.dartlang.org" 220 | source: hosted 221 | version: "0.6.4" 222 | matcher: 223 | dependency: transitive 224 | description: 225 | name: matcher 226 | url: "https://pub.dartlang.org" 227 | source: hosted 228 | version: "0.12.11" 229 | material_color_utilities: 230 | dependency: transitive 231 | description: 232 | name: material_color_utilities 233 | url: "https://pub.dartlang.org" 234 | source: hosted 235 | version: "0.1.3" 236 | meta: 237 | dependency: transitive 238 | description: 239 | name: meta 240 | url: "https://pub.dartlang.org" 241 | source: hosted 242 | version: "1.7.0" 243 | mime: 244 | dependency: transitive 245 | description: 246 | name: mime 247 | url: "https://pub.dartlang.org" 248 | source: hosted 249 | version: "1.0.1" 250 | path: 251 | dependency: transitive 252 | description: 253 | name: path 254 | url: "https://pub.dartlang.org" 255 | source: hosted 256 | version: "1.8.1" 257 | path_provider: 258 | dependency: transitive 259 | description: 260 | name: path_provider 261 | url: "https://pub.dartlang.org" 262 | source: hosted 263 | version: "2.0.9" 264 | path_provider_android: 265 | dependency: transitive 266 | description: 267 | name: path_provider_android 268 | url: "https://pub.dartlang.org" 269 | source: hosted 270 | version: "2.0.12" 271 | path_provider_ios: 272 | dependency: transitive 273 | description: 274 | name: path_provider_ios 275 | url: "https://pub.dartlang.org" 276 | source: hosted 277 | version: "2.0.8" 278 | path_provider_linux: 279 | dependency: transitive 280 | description: 281 | name: path_provider_linux 282 | url: "https://pub.dartlang.org" 283 | source: hosted 284 | version: "2.1.5" 285 | path_provider_macos: 286 | dependency: transitive 287 | description: 288 | name: path_provider_macos 289 | url: "https://pub.dartlang.org" 290 | source: hosted 291 | version: "2.0.5" 292 | path_provider_platform_interface: 293 | dependency: transitive 294 | description: 295 | name: path_provider_platform_interface 296 | url: "https://pub.dartlang.org" 297 | source: hosted 298 | version: "2.0.3" 299 | path_provider_windows: 300 | dependency: transitive 301 | description: 302 | name: path_provider_windows 303 | url: "https://pub.dartlang.org" 304 | source: hosted 305 | version: "2.0.5" 306 | platform: 307 | dependency: transitive 308 | description: 309 | name: platform 310 | url: "https://pub.dartlang.org" 311 | source: hosted 312 | version: "3.1.0" 313 | plugin_platform_interface: 314 | dependency: transitive 315 | description: 316 | name: plugin_platform_interface 317 | url: "https://pub.dartlang.org" 318 | source: hosted 319 | version: "2.1.2" 320 | process: 321 | dependency: transitive 322 | description: 323 | name: process 324 | url: "https://pub.dartlang.org" 325 | source: hosted 326 | version: "4.2.4" 327 | share: 328 | dependency: "direct main" 329 | description: 330 | name: share 331 | url: "https://pub.dartlang.org" 332 | source: hosted 333 | version: "2.0.4" 334 | shared_preferences: 335 | dependency: "direct main" 336 | description: 337 | name: shared_preferences 338 | url: "https://pub.dartlang.org" 339 | source: hosted 340 | version: "2.0.13" 341 | shared_preferences_android: 342 | dependency: transitive 343 | description: 344 | name: shared_preferences_android 345 | url: "https://pub.dartlang.org" 346 | source: hosted 347 | version: "2.0.11" 348 | shared_preferences_ios: 349 | dependency: transitive 350 | description: 351 | name: shared_preferences_ios 352 | url: "https://pub.dartlang.org" 353 | source: hosted 354 | version: "2.1.0" 355 | shared_preferences_linux: 356 | dependency: transitive 357 | description: 358 | name: shared_preferences_linux 359 | url: "https://pub.dartlang.org" 360 | source: hosted 361 | version: "2.1.0" 362 | shared_preferences_macos: 363 | dependency: transitive 364 | description: 365 | name: shared_preferences_macos 366 | url: "https://pub.dartlang.org" 367 | source: hosted 368 | version: "2.0.3" 369 | shared_preferences_platform_interface: 370 | dependency: transitive 371 | description: 372 | name: shared_preferences_platform_interface 373 | url: "https://pub.dartlang.org" 374 | source: hosted 375 | version: "2.0.0" 376 | shared_preferences_web: 377 | dependency: transitive 378 | description: 379 | name: shared_preferences_web 380 | url: "https://pub.dartlang.org" 381 | source: hosted 382 | version: "2.0.3" 383 | shared_preferences_windows: 384 | dependency: transitive 385 | description: 386 | name: shared_preferences_windows 387 | url: "https://pub.dartlang.org" 388 | source: hosted 389 | version: "2.1.0" 390 | sky_engine: 391 | dependency: transitive 392 | description: flutter 393 | source: sdk 394 | version: "0.0.99" 395 | source_span: 396 | dependency: transitive 397 | description: 398 | name: source_span 399 | url: "https://pub.dartlang.org" 400 | source: hosted 401 | version: "1.8.1" 402 | stack_trace: 403 | dependency: transitive 404 | description: 405 | name: stack_trace 406 | url: "https://pub.dartlang.org" 407 | source: hosted 408 | version: "1.10.0" 409 | stream_channel: 410 | dependency: transitive 411 | description: 412 | name: stream_channel 413 | url: "https://pub.dartlang.org" 414 | source: hosted 415 | version: "2.1.0" 416 | string_scanner: 417 | dependency: transitive 418 | description: 419 | name: string_scanner 420 | url: "https://pub.dartlang.org" 421 | source: hosted 422 | version: "1.1.0" 423 | term_glyph: 424 | dependency: transitive 425 | description: 426 | name: term_glyph 427 | url: "https://pub.dartlang.org" 428 | source: hosted 429 | version: "1.2.0" 430 | test_api: 431 | dependency: transitive 432 | description: 433 | name: test_api 434 | url: "https://pub.dartlang.org" 435 | source: hosted 436 | version: "0.4.9" 437 | typed_data: 438 | dependency: transitive 439 | description: 440 | name: typed_data 441 | url: "https://pub.dartlang.org" 442 | source: hosted 443 | version: "1.3.0" 444 | url_launcher: 445 | dependency: "direct main" 446 | description: 447 | name: url_launcher 448 | url: "https://pub.dartlang.org" 449 | source: hosted 450 | version: "6.0.20" 451 | url_launcher_android: 452 | dependency: transitive 453 | description: 454 | name: url_launcher_android 455 | url: "https://pub.dartlang.org" 456 | source: hosted 457 | version: "6.0.15" 458 | url_launcher_ios: 459 | dependency: transitive 460 | description: 461 | name: url_launcher_ios 462 | url: "https://pub.dartlang.org" 463 | source: hosted 464 | version: "6.0.15" 465 | url_launcher_linux: 466 | dependency: transitive 467 | description: 468 | name: url_launcher_linux 469 | url: "https://pub.dartlang.org" 470 | source: hosted 471 | version: "3.0.0" 472 | url_launcher_macos: 473 | dependency: transitive 474 | description: 475 | name: url_launcher_macos 476 | url: "https://pub.dartlang.org" 477 | source: hosted 478 | version: "3.0.0" 479 | url_launcher_platform_interface: 480 | dependency: transitive 481 | description: 482 | name: url_launcher_platform_interface 483 | url: "https://pub.dartlang.org" 484 | source: hosted 485 | version: "2.0.5" 486 | url_launcher_web: 487 | dependency: transitive 488 | description: 489 | name: url_launcher_web 490 | url: "https://pub.dartlang.org" 491 | source: hosted 492 | version: "2.0.6" 493 | url_launcher_windows: 494 | dependency: transitive 495 | description: 496 | name: url_launcher_windows 497 | url: "https://pub.dartlang.org" 498 | source: hosted 499 | version: "3.0.0" 500 | uuid: 501 | dependency: transitive 502 | description: 503 | name: uuid 504 | url: "https://pub.dartlang.org" 505 | source: hosted 506 | version: "3.0.6" 507 | vector_math: 508 | dependency: transitive 509 | description: 510 | name: vector_math 511 | url: "https://pub.dartlang.org" 512 | source: hosted 513 | version: "2.1.1" 514 | win32: 515 | dependency: transitive 516 | description: 517 | name: win32 518 | url: "https://pub.dartlang.org" 519 | source: hosted 520 | version: "2.5.1" 521 | xdg_directories: 522 | dependency: transitive 523 | description: 524 | name: xdg_directories 525 | url: "https://pub.dartlang.org" 526 | source: hosted 527 | version: "0.2.0+1" 528 | sdks: 529 | dart: ">=2.16.0 <3.0.0" 530 | flutter: ">=2.8.0" 531 | -------------------------------------------------------------------------------- /lib/screen/challenges page.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:memory/data/data.dart'; 3 | import 'package:memory/screen/Challenges%20level.dart'; 4 | import 'package:shared_preferences/shared_preferences.dart'; 5 | 6 | class ChooseChallenges extends StatefulWidget { 7 | @override 8 | _ChooseChallengesState createState() => _ChooseChallengesState(); 9 | } 10 | 11 | class _ChooseChallengesState extends State { 12 | 13 | @override 14 | void initState() { 15 | super.initState(); 16 | getHighScore(); 17 | } 18 | 19 | getHighScore() async { 20 | SharedPreferences myPrefs = await SharedPreferences.getInstance(); 21 | if(myPrefs.getBool("c1") != null) { 22 | setState(() { 23 | Data.challenge_1 = myPrefs.getBool("c1"); 24 | }); 25 | } 26 | if(myPrefs.getBool("c2") != null) { 27 | setState(() { 28 | Data.challenge_2 = myPrefs.getBool("c2"); 29 | }); 30 | } 31 | if(myPrefs.getBool("c3") != null) { 32 | setState(() { 33 | Data.challenge_3 = myPrefs.getBool("c3"); 34 | }); 35 | } 36 | } 37 | 38 | @override 39 | Widget build(BuildContext context) { 40 | return Container( 41 | decoration: BoxDecoration( 42 | gradient: LinearGradient( 43 | begin: Alignment.topRight, 44 | end: Alignment.bottomLeft, 45 | 46 | stops: [0,0.46,1], 47 | 48 | colors: [ 49 | Color(0xffFFCC70), 50 | Color(0xffC850C0), 51 | Color(0xff4158D0), 52 | ] 53 | ) 54 | ), 55 | child: Scaffold( 56 | backgroundColor: Colors.transparent, 57 | appBar: AppBar( 58 | title: Text("Challenges", 59 | style: TextStyle( 60 | color: Colors.white, 61 | fontSize: 25, 62 | fontWeight: FontWeight.w600, 63 | ),), 64 | leading: IconButton( 65 | color: Colors.white, 66 | icon: Icon(Icons.arrow_back_ios), 67 | onPressed: (){ 68 | Navigator.of(context).pop(); 69 | }, 70 | ), 71 | centerTitle: true, 72 | backgroundColor: Colors.transparent, 73 | elevation: 0, 74 | ), 75 | body: Center( 76 | child: Column( 77 | crossAxisAlignment: CrossAxisAlignment.center, 78 | mainAxisAlignment: MainAxisAlignment.spaceEvenly, 79 | children: [ 80 | GestureDetector( 81 | onTap: (){ 82 | Navigator.push(context, MaterialPageRoute(builder: (context) { 83 | return ChallengesLevel(challenge: 1,); 84 | },)); 85 | }, 86 | child: Container( 87 | height: MediaQuery.of(context).size.height*0.21, 88 | width: MediaQuery.of(context).size.width*0.85, 89 | child: Card( 90 | margin: EdgeInsets.all(0), 91 | shape: RoundedRectangleBorder( 92 | borderRadius: BorderRadius.circular(20), 93 | ), 94 | elevation: 10, 95 | color: Data.challenge_1 == false ? 96 | Color(0xffDD2A7B) : Colors.green, 97 | child: Stack( 98 | children: [ 99 | Positioned( 100 | top: 18, 101 | left: 12, 102 | child: Column( 103 | mainAxisAlignment: MainAxisAlignment.start, 104 | crossAxisAlignment: CrossAxisAlignment.start, 105 | children: [ 106 | RichText( 107 | text: TextSpan( 108 | children: [ 109 | TextSpan( 110 | text: "Challenges ", 111 | style: TextStyle( 112 | color: Colors.white, 113 | fontSize: 22, 114 | fontWeight: FontWeight.w700, 115 | ), 116 | ), 117 | TextSpan( 118 | text: "१", 119 | style: TextStyle( 120 | color: Colors.white, 121 | fontSize: 26, 122 | fontWeight: FontWeight.w700, 123 | ), 124 | ), 125 | ] 126 | ), 127 | ), 128 | Padding( 129 | padding: const EdgeInsets.only(top: 8), 130 | child: Text("complete the level\n" 131 | "in given time", 132 | style: TextStyle( 133 | color: Colors.white.withOpacity(0.9), 134 | fontSize: 18, 135 | fontWeight: FontWeight.w500, 136 | ), 137 | ), 138 | ), 139 | ], 140 | ), 141 | ), 142 | Positioned( 143 | top: -35, 144 | right: -30, 145 | child: CircleAvatar( 146 | radius: 90, 147 | backgroundColor: Colors.white.withOpacity(0.12), 148 | child: CircleAvatar( 149 | radius: 70, 150 | backgroundColor: Colors.white.withOpacity(0.2), 151 | child: CircleAvatar( 152 | radius: 52, 153 | backgroundColor: Colors.white.withOpacity(0.18), 154 | child: CircleAvatar( 155 | radius: 40, 156 | child: Text("20", 157 | style: TextStyle( 158 | fontSize: 34, 159 | color: Colors.white, 160 | fontWeight: FontWeight.w600 161 | ),), 162 | backgroundColor: Data.challenge_1 == false ? 163 | Color(0xffDD2A7B) : Colors.green, 164 | ), 165 | ), 166 | ), 167 | ), 168 | ), 169 | ], 170 | ), 171 | ), 172 | ), 173 | ), 174 | GestureDetector( 175 | onTap: (){ 176 | Navigator.push(context, MaterialPageRoute(builder: (context) { 177 | return ChallengesLevel(challenge: 2,); 178 | },)); 179 | }, 180 | child: Container( 181 | height: MediaQuery.of(context).size.height*0.21, 182 | width: MediaQuery.of(context).size.width*0.85, 183 | child: Card( 184 | margin: EdgeInsets.all(0), 185 | shape: RoundedRectangleBorder( 186 | borderRadius: BorderRadius.circular(20), 187 | ), 188 | elevation: 10, 189 | color: Data.challenge_2 == false ? 190 | Color(0xffDD2A7B) : Colors.green, 191 | child: Stack( 192 | children: [ 193 | Positioned( 194 | top: 18, 195 | left: 12, 196 | child: Column( 197 | mainAxisAlignment: MainAxisAlignment.start, 198 | crossAxisAlignment: CrossAxisAlignment.start, 199 | children: [ 200 | RichText( 201 | text: TextSpan( 202 | children: [ 203 | TextSpan( 204 | text: "Challenges ", 205 | style: TextStyle( 206 | color: Colors.white, 207 | fontSize: 22, 208 | fontWeight: FontWeight.w700, 209 | ), 210 | ), 211 | TextSpan( 212 | text: "२", 213 | style: TextStyle( 214 | color: Colors.white, 215 | fontSize: 26, 216 | fontWeight: FontWeight.w700, 217 | ), 218 | ), 219 | ] 220 | ), 221 | ), 222 | Padding( 223 | padding: const EdgeInsets.only(top: 8), 224 | child: Text("complete the level\n" 225 | "in given turns", 226 | style: TextStyle( 227 | color: Colors.white.withOpacity(0.9), 228 | fontSize: 18, 229 | fontWeight: FontWeight.w500, 230 | ), 231 | ), 232 | ), 233 | ], 234 | ), 235 | ), 236 | Positioned( 237 | top: -35, 238 | right: -30, 239 | child: CircleAvatar( 240 | radius: 90, 241 | backgroundColor: Colors.white.withOpacity(0.12), 242 | child: CircleAvatar( 243 | radius: 70, 244 | backgroundColor: Colors.white.withOpacity(0.2), 245 | child: CircleAvatar( 246 | radius: 52, 247 | backgroundColor: Colors.white.withOpacity(0.18), 248 | child: CircleAvatar( 249 | radius: 40, 250 | child: Text("38", 251 | style: TextStyle( 252 | fontSize: 34, 253 | color: Colors.white, 254 | fontWeight: FontWeight.w600 255 | ),), 256 | backgroundColor: Data.challenge_2 == false ? 257 | Color(0xffDD2A7B) : Colors.green, 258 | ), 259 | ), 260 | ), 261 | ), 262 | ), 263 | ], 264 | ), 265 | ), 266 | ), 267 | ), 268 | GestureDetector( 269 | onTap: (){ 270 | Navigator.push(context, MaterialPageRoute(builder: (context) { 271 | return ChallengesLevel(challenge: 3,); 272 | },)); 273 | }, 274 | child: Container( 275 | height: MediaQuery.of(context).size.height*0.21, 276 | width: MediaQuery.of(context).size.width*0.85, 277 | color: Colors.transparent, 278 | child: Card( 279 | margin: EdgeInsets.all(0), 280 | shape: RoundedRectangleBorder( 281 | borderRadius: BorderRadius.circular(20), 282 | ), 283 | elevation: 10, 284 | color: Data.challenge_3 == false ? 285 | Color(0xffDD2A7B) : Colors.green, 286 | child: Stack( 287 | children: [ 288 | Positioned( 289 | top: 18, 290 | left: 12, 291 | child: Column( 292 | mainAxisAlignment: MainAxisAlignment.start, 293 | crossAxisAlignment: CrossAxisAlignment.start, 294 | children: [ 295 | RichText( 296 | text: TextSpan( 297 | children: [ 298 | TextSpan( 299 | text: "Challenges ", 300 | style: TextStyle( 301 | color: Colors.white, 302 | fontSize: 22, 303 | fontWeight: FontWeight.w700, 304 | ), 305 | ), 306 | TextSpan( 307 | text: "३", 308 | style: TextStyle( 309 | color: Colors.white, 310 | fontSize: 26, 311 | fontWeight: FontWeight.w700, 312 | ), 313 | ), 314 | ] 315 | ), 316 | ), 317 | Padding( 318 | padding: const EdgeInsets.only(top: 8), 319 | child: Text("complete the level\n" 320 | "in given time &\n" 321 | "turn", 322 | style: TextStyle( 323 | color: Colors.white.withOpacity(0.9), 324 | fontSize: 18, 325 | fontWeight: FontWeight.w500, 326 | ), 327 | ), 328 | ), 329 | ], 330 | ), 331 | ), 332 | Positioned( 333 | top: -35, 334 | right: -30, 335 | child: CircleAvatar( 336 | radius: 90, 337 | backgroundColor: Colors.white.withOpacity(0.12), 338 | child: CircleAvatar( 339 | radius: 70, 340 | backgroundColor: Colors.white.withOpacity(0.2), 341 | child: CircleAvatar( 342 | radius: 52, 343 | backgroundColor: Colors.white.withOpacity(0.18), 344 | child: CircleAvatar( 345 | radius: 40, 346 | child: Text("36", 347 | style: TextStyle( 348 | fontSize: 34, 349 | color: Colors.white, 350 | fontWeight: FontWeight.w600 351 | ),), 352 | backgroundColor: Data.challenge_3 == false ? 353 | Color(0xffDD2A7B) : Colors.green, 354 | ), 355 | ), 356 | ), 357 | ), 358 | ), 359 | ], 360 | ), 361 | ), 362 | ), 363 | ), 364 | ], 365 | ), 366 | ), 367 | ), 368 | ); 369 | } 370 | } 371 | -------------------------------------------------------------------------------- /lib/screen/Challenges level.dart: -------------------------------------------------------------------------------- 1 | import 'dart:async'; 2 | import 'package:firebase_core/firebase_core.dart'; 3 | import 'package:flutter/cupertino.dart'; 4 | import 'package:flutter/material.dart'; 5 | import 'package:flutter/rendering.dart'; 6 | import 'package:google_mobile_ads/google_mobile_ads.dart'; 7 | import 'package:memory/data/data.dart'; 8 | import 'package:shared_preferences/shared_preferences.dart'; 9 | 10 | // ignore: must_be_immutable 11 | class ChallengesLevel extends StatefulWidget { 12 | int challenge = 1; 13 | ChallengesLevel({this.challenge}); 14 | @override 15 | _ChallengesLevelState createState() => _ChallengesLevelState(); 16 | } 17 | 18 | class _ChallengesLevelState extends State { 19 | 20 | final fireStore = Firebase.initializeApp(); 21 | 22 | bool show = true; 23 | bool choose = false; 24 | bool restartG = false; 25 | bool allow = true; 26 | bool isLoaded = false; 27 | bool isLoadedIn = false; 28 | int i; 29 | int ab = 2; 30 | int y; 31 | String q = ""; 32 | String w = ""; 33 | int numberOfTurns = 0; 34 | int sec = 700; 35 | List a = []; 36 | List b = []; 37 | 38 | Timer timer; 39 | int gameTime = 0; 40 | 41 | @override 42 | void initState() { 43 | super.initState(); 44 | first(); 45 | if(Data.showAds == true){ 46 | bannerAds(); 47 | loadReAds(); 48 | } 49 | } 50 | 51 | @override 52 | void dispose() { 53 | super.dispose(); 54 | timer?.cancel(); 55 | if(Data.showAds == true){ 56 | _ad?.dispose(); 57 | } 58 | } 59 | 60 | BannerAd _ad; 61 | 62 | bannerAds() async{ 63 | _ad = BannerAd( 64 | adUnitId: "ca-app-pub-3028010056599796/1626317951", 65 | size: AdSize.banner, 66 | request: AdRequest(), 67 | listener: AdListener( 68 | onAdLoaded: (_){ 69 | setState(() { 70 | isLoaded = true; 71 | }); 72 | }, 73 | onAdFailedToLoad: (_ad,error){ 74 | } 75 | ), 76 | ); 77 | } 78 | 79 | checkForAd(){ 80 | if(isLoaded == true){ 81 | return Container( 82 | child: Center( 83 | child: AdWidget( 84 | ad: _ad, 85 | ), 86 | ), 87 | height: 50, 88 | width: 320, 89 | alignment: Alignment.center, 90 | ); 91 | }else{ 92 | return Container( 93 | height: 50, 94 | width: 320, 95 | ); 96 | } 97 | } 98 | 99 | RewardedAd _re; 100 | 101 | loadReAds(){ 102 | if(Data.showAds == true){ 103 | _re = RewardedAd( 104 | adUnitId: 'ca-app-pub-3028010056599796/3446334882', 105 | request: AdRequest( 106 | keywords: ["amazon", "games", "land", "collage","toys","learn","coding","food"], 107 | ), 108 | listener: AdListener( 109 | onRewardedAdUserEarnedReward: (RewardedAd ad, RewardItem reward) { 110 | }, 111 | onAdFailedToLoad: (Ad ad, LoadAdError error) { 112 | }, 113 | ), 114 | ); 115 | _re.load(); 116 | } 117 | } 118 | 119 | showReAds(){ 120 | if(Data.showAds == true){ 121 | _re.show(); 122 | } 123 | } 124 | 125 | setHighScore() async { 126 | SharedPreferences myPrefs = await SharedPreferences.getInstance(); 127 | setState(() { 128 | if(widget.challenge == 1){ 129 | myPrefs.setBool("c1", Data.challenge_1); 130 | }else if(widget.challenge == 2){ 131 | myPrefs.setBool("c2", Data.challenge_2); 132 | }else if(widget.challenge == 3){ 133 | myPrefs.setBool("c3", Data.challenge_3); 134 | 135 | } 136 | }); 137 | } 138 | 139 | first(){ 140 | for( int i = 1; 141 | widget.challenge == 1 ? i <= 8 : 142 | widget.challenge == 2 ? i <= 10 : 143 | widget.challenge == 3 ? i <= 10 : 144 | i <= 8; i++){ 145 | a.add(i.toString()); 146 | a.add(i.toString()); 147 | } 148 | a.shuffle(); 149 | } 150 | 151 | number(int index){ 152 | if(index == i || y == index){ 153 | return Image.asset("asset/images/${a[index]}.png", 154 | fit: BoxFit.contain, 155 | width: 60, 156 | ); 157 | } else { 158 | return 159 | Image.asset("asset/images/3.png", 160 | width: 50, 161 | fit: BoxFit.contain, 162 | color: Color(0xffDD2A7B).withOpacity(0.85), 163 | ); 164 | } 165 | } 166 | 167 | time(){ 168 | timer = Timer.periodic(Duration(seconds: 1), (timer) { 169 | setState(() { 170 | gameTime++; 171 | if(widget.challenge == 1){ 172 | if(gameTime >= 20){ 173 | setState(() { 174 | timer.cancel(); 175 | allow = false; 176 | showWinDialog("Time is over"); 177 | }); 178 | } 179 | }else if(widget.challenge == 3){ 180 | if(gameTime >= 28){ 181 | setState(() { 182 | timer.cancel(); 183 | allow = false; 184 | showWinDialog("Time is over"); 185 | }); 186 | } 187 | } 188 | }); 189 | }); 190 | } 191 | 192 | @override 193 | Widget build(BuildContext context) { 194 | return GestureDetector( 195 | onTap: (){ 196 | setState(() { 197 | choose = false; 198 | }); 199 | }, 200 | child: Container( 201 | decoration: BoxDecoration( 202 | gradient: LinearGradient( 203 | begin: Alignment.topRight, 204 | end: Alignment.bottomLeft, 205 | 206 | stops: [0,0.46,1], 207 | 208 | colors: [ 209 | Color(0xffFFCC70), 210 | Color(0xffC850C0), 211 | Color(0xff4158D0), 212 | ] 213 | ) 214 | ), 215 | child: Scaffold( 216 | backgroundColor: Colors.transparent, 217 | appBar: AppBar( 218 | centerTitle: true, 219 | backgroundColor: Colors.transparent, 220 | leading: IconButton( 221 | icon: Icon(Icons.arrow_back_ios), 222 | onPressed: (){ 223 | Navigator.of(context).pop(); 224 | }, 225 | ), 226 | title: Text("challenge ${widget.challenge}", 227 | style: TextStyle( 228 | color: Colors.white, 229 | fontSize: 25, 230 | fontWeight: FontWeight.w600 231 | ), 232 | ), 233 | elevation: 0, 234 | ), 235 | body: Stack( 236 | alignment: Alignment.center, 237 | children: [ 238 | Positioned( 239 | top: MediaQuery.of(context).size.height*0.03, 240 | child: 241 | numberOfTurns >= 1 ? 242 | Row( 243 | children: [ 244 | Padding( 245 | padding: const EdgeInsets.only(left: 10), 246 | child: Text( widget.challenge == 1 ? 247 | "${20 - gameTime} " : 248 | widget.challenge == 2 ? 249 | "${38 - numberOfTurns} " : 250 | widget.challenge == 3 ? 251 | "${38 - numberOfTurns} turns &\n" 252 | "${28 - gameTime} sec left" : "", 253 | style: TextStyle( 254 | fontSize: 30, 255 | color: Colors.white, 256 | fontWeight: FontWeight.bold, 257 | ), 258 | ), 259 | ), 260 | Padding( 261 | padding: const EdgeInsets.only(left: 6), 262 | child: Text( 263 | widget.challenge == 1 ? 264 | "sec left" : 265 | widget.challenge == 2 ? 266 | "turns left" :"", 267 | style: TextStyle( 268 | fontSize: 25, 269 | color: Colors.white, 270 | fontWeight: FontWeight.bold, 271 | ), 272 | ), 273 | ), 274 | SizedBox( 275 | width: MediaQuery.of(context).size.width*0.06, 276 | ), 277 | MaterialButton( 278 | elevation: 10, 279 | shape: RoundedRectangleBorder( 280 | borderRadius: BorderRadius.circular(10), 281 | ), 282 | color: Colors.white, 283 | splashColor: Color(0xffDD2A7B), 284 | minWidth: 120, 285 | height: 50, 286 | onPressed: () { 287 | showWinDialog("Memory Game"); 288 | setState(() { 289 | restartG = true; 290 | choose = false; 291 | }); 292 | }, 293 | child: Text( 294 | 'Restart', 295 | style: TextStyle( 296 | fontWeight: FontWeight.bold, 297 | fontSize: 18, 298 | color: Color(0xffDD2A7B), 299 | // fontFamily: 'David', 300 | ), 301 | ), 302 | ), 303 | ], 304 | ) : 305 | Container( 306 | width: 350, 307 | height: 90, 308 | child: Card( 309 | shape: RoundedRectangleBorder( 310 | borderRadius: BorderRadius.circular(10), 311 | ), 312 | color: Colors.white, 313 | child: Center( 314 | child: Text( 315 | widget.challenge == 1 ? 316 | "Complete this level under 20 sec" : 317 | widget.challenge == 2 ? 318 | "Complete this level under 38 turns" : 319 | widget.challenge == 3 ? 320 | "complete the level in\n" 321 | " 36 turns & 26 sec" : "", 322 | style: TextStyle( 323 | fontSize: 21, 324 | color: Color(0xffDD2A7B), 325 | fontWeight: FontWeight.w600, 326 | ), 327 | ), 328 | ), 329 | ), 330 | ), 331 | ), 332 | AnimatedPositioned( 333 | duration: Duration(milliseconds: 350), 334 | top: numberOfTurns >= 1 ? 335 | MediaQuery.of(context).size.height*0.135 : 336 | MediaQuery.of(context).size.height*0.165, 337 | 338 | height: MediaQuery.of(context).size.height, 339 | 340 | width: MediaQuery.of(context).size.width, 341 | child: Padding( 342 | padding: const EdgeInsets.all(10), 343 | child: GridView.builder( 344 | shrinkWrap: true, 345 | physics: BouncingScrollPhysics(), 346 | itemCount: a.length == null ? 0 : a.length, 347 | gridDelegate: SliverGridDelegateWithFixedCrossAxisCount( 348 | crossAxisCount: 4, 349 | crossAxisSpacing: 4, 350 | mainAxisSpacing: 4, 351 | ), 352 | itemBuilder: (BuildContext context, int index) { 353 | return GestureDetector( 354 | onTap: () { 355 | if(allow == true){ 356 | setState(() { 357 | choose = false; 358 | }); 359 | if(numberOfTurns == 0){ 360 | if(Data.showAds == true){ 361 | _ad.load(); 362 | } 363 | if(widget.challenge != 2){ 364 | time(); 365 | } 366 | } 367 | if(i != index && !b.contains(a[index]) && show == true){ 368 | setState(() { 369 | numberOfTurns++; 370 | i = index; 371 | if(ab%2 == 0){ 372 | y = i; 373 | q = a[index].toString(); 374 | }else{ 375 | w = a[index].toString(); 376 | show = false; 377 | check(); 378 | } 379 | if(ab%2 != 0){ 380 | Timer(Duration(milliseconds: sec), () { 381 | setState(() { 382 | i = null; 383 | y = null; 384 | show = true; 385 | }); 386 | }); 387 | sec = 700; 388 | } 389 | ab++; 390 | }); 391 | } 392 | } 393 | }, 394 | child: Card( 395 | color: b.contains(a[index]) ? Colors.green : i == index || y == index ? Colors.red : Colors.white, 396 | shape: RoundedRectangleBorder( 397 | borderRadius: BorderRadius.circular(10.0), 398 | ), 399 | elevation: 8, 400 | child: Center( 401 | child: b.contains(a[index]) ? 402 | Image.asset("asset/images/${a[index]}.png", 403 | fit: BoxFit.contain, 404 | width: 65, 405 | ) : 406 | number(index), 407 | ), 408 | ), 409 | ); 410 | }, 411 | ), 412 | ), 413 | ), 414 | Positioned( 415 | bottom: 0, 416 | height: 50, 417 | width: 320, 418 | child: checkForAd(), 419 | ), 420 | ], 421 | ), 422 | ), 423 | ), 424 | ); 425 | } 426 | 427 | check(){ 428 | if(q == w){ 429 | b.add(w); 430 | b.add(q); 431 | setState(() { 432 | sec = 1; 433 | }); 434 | } 435 | 436 | if(b.length >= a.length){ 437 | if(widget.challenge == 1){ 438 | setState(() { 439 | timer.cancel(); 440 | Data.challenge_1 = true; 441 | setHighScore(); 442 | showWinDialog("Challenge completed in \n " 443 | " $gameTime seconds"); 444 | }); 445 | }else if(widget.challenge == 2){ 446 | setState(() { 447 | Data.challenge_2 = true; 448 | setHighScore(); 449 | showWinDialog("Challenge completed in \n " 450 | " $numberOfTurns turns"); 451 | }); 452 | }else if(widget.challenge == 3){ 453 | setState(() { 454 | timer.cancel(); 455 | Data.challenge_3 = true; 456 | setHighScore(); 457 | showWinDialog("Challenge completed in \n " 458 | " $numberOfTurns turns & $gameTime sec"); 459 | }); 460 | } 461 | } 462 | 463 | if(numberOfTurns >= 36){ 464 | if(widget.challenge == 3){ 465 | setState(() { 466 | allow = false; 467 | showWinDialog("Turns are over"); 468 | }); 469 | }else if(widget.challenge == 2){ 470 | if(numberOfTurns >= 38){ 471 | setState(() { 472 | allow = false; 473 | showWinDialog("Turns are over"); 474 | }); 475 | } 476 | } 477 | } 478 | 479 | } 480 | 481 | restart(){ 482 | setState(() { 483 | i = null; 484 | ab = 2; 485 | y = null; 486 | q = ""; 487 | w = ""; 488 | numberOfTurns = 0; 489 | a = []; 490 | sec = 700; 491 | show = true; 492 | allow = true; 493 | b = []; 494 | first(); 495 | if(gameTime > 0){ 496 | if(timer.isActive == true){ 497 | timer.cancel(); 498 | } 499 | gameTime = 0; 500 | } 501 | gameTime = 0; 502 | restartG = false; 503 | }); 504 | } 505 | 506 | showWinDialog(String yo) { 507 | showDialog( 508 | context: context, 509 | builder: (BuildContext context){ 510 | return AlertDialog( 511 | title: Center(child: Text( 512 | yo 513 | )), 514 | elevation: 5, 515 | shape: RoundedRectangleBorder( 516 | borderRadius: BorderRadius.circular(30), 517 | ), 518 | actions: [ 519 | Row( 520 | mainAxisAlignment: MainAxisAlignment.spaceEvenly, 521 | crossAxisAlignment: CrossAxisAlignment.center, 522 | children: [ 523 | GestureDetector( 524 | onTap: (){ 525 | Navigator.of(context).pop(); 526 | }, 527 | child: Padding( 528 | padding: const EdgeInsets.only(left: 20), 529 | child: Text("cancel", 530 | style: TextStyle( 531 | fontSize: 21, 532 | color: Color(0xff151515), 533 | ), 534 | ), 535 | ), 536 | ), 537 | SizedBox( 538 | width: MediaQuery.of(context).size.width*0.11, 539 | ), 540 | MaterialButton( 541 | elevation: 10, 542 | shape: RoundedRectangleBorder( 543 | borderRadius: BorderRadius.circular(30), 544 | ), 545 | color: Colors.red, 546 | minWidth: 120, 547 | height: 50, 548 | onPressed: (){ 549 | if(Data.showAds == true){ 550 | showReAds(); 551 | loadReAds(); 552 | } 553 | restart(); 554 | Navigator.of(context).pop(); 555 | }, 556 | child: Text( 557 | 'Restart', 558 | style: TextStyle( 559 | fontWeight: FontWeight.bold, 560 | fontSize: 18, 561 | color: Colors.white, 562 | ), 563 | ), 564 | ), 565 | ], 566 | ), 567 | ], 568 | ); 569 | } 570 | ); 571 | } 572 | } 573 | -------------------------------------------------------------------------------- /lib/screen/home screen.dart: -------------------------------------------------------------------------------- 1 | import 'dart:async'; 2 | import 'package:audioplayers/audioplayers.dart'; 3 | import 'package:firebase_core/firebase_core.dart'; 4 | import 'package:flutter/cupertino.dart'; 5 | import 'package:flutter/material.dart'; 6 | import 'package:memory/data/data.dart'; 7 | import 'package:memory/screen/brain_jam.dart'; 8 | import 'package:memory/screen/challenges.dart'; 9 | import 'package:memory/screen/high%20score.dart'; 10 | import 'package:memory/screen/memoryGame.dart'; 11 | import 'package:memory/screen/setting.dart'; 12 | import 'package:share/share.dart'; 13 | import 'package:shared_preferences/shared_preferences.dart'; 14 | import 'package:animated_text_kit/animated_text_kit.dart'; 15 | import 'package:url_launcher/url_launcher.dart'; 16 | import 'package:cloud_firestore/cloud_firestore.dart'; 17 | import 'challenges page.dart'; 18 | import 'help.dart'; 19 | 20 | class HomeScreen extends StatefulWidget { 21 | @override 22 | _HomeScreenState createState() => _HomeScreenState(); 23 | } 24 | 25 | AudioPlayer audioPlayer = AudioPlayer(); 26 | 27 | class _HomeScreenState extends State with WidgetsBindingObserver{ 28 | 29 | final _scaffoldKey = GlobalKey(); 30 | final fireStore = Firebase.initializeApp(); 31 | 32 | bool change = false; 33 | Timer timer; 34 | 35 | bool newGame = false; 36 | bool level = false; 37 | bool challenges = false; 38 | bool highScore = false; 39 | 40 | @override 41 | void initState() { 42 | super.initState(); 43 | getHighScore(); 44 | WidgetsBinding.instance.addObserver(this); 45 | musicName(); 46 | showAds(); 47 | timer = Timer.periodic( 48 | Duration( 49 | milliseconds: 2700), (timer) { 50 | setState(() { 51 | if(Data.play == true && Data.neverPlay == false){ 52 | playAgain(); 53 | } 54 | change = !change; 55 | }); 56 | }); 57 | } 58 | 59 | showAds(){ 60 | fireStore.then((value) async { 61 | FirebaseFirestore.instance. 62 | collection("memory").doc("1") 63 | .get().then((result){ 64 | setState(() { 65 | // Data.showAds = result.get("showAds"); 66 | }); 67 | }); 68 | }); 69 | } 70 | 71 | musicName() async{ 72 | fireStore.then((value) async { 73 | FirebaseFirestore.instance. 74 | collection("memory").doc("1") 75 | .get().then((result){ 76 | Data.music = result.get("music"); 77 | }); 78 | }); 79 | } 80 | 81 | @override 82 | void didChangeAppLifecycleState(AppLifecycleState state){ 83 | super.didChangeAppLifecycleState(state); 84 | switch(state){ 85 | case AppLifecycleState.paused : 86 | if(Data.neverPlay == false){ 87 | setState(() { 88 | audioPlayer.pause(); 89 | Data.play = false; 90 | }); 91 | } 92 | break; 93 | case AppLifecycleState.resumed : 94 | if(Data.neverPlay == false){ 95 | setState(() { 96 | audioPlayer.resume(); 97 | Data.play = true; 98 | }); 99 | } 100 | break; 101 | case AppLifecycleState.inactive : 102 | if(Data.neverPlay == false){ 103 | setState(() { 104 | audioPlayer.pause(); 105 | Data.play = false; 106 | }); 107 | } 108 | break; 109 | case AppLifecycleState.detached : 110 | if(Data.neverPlay == false){ 111 | setState(() { 112 | audioPlayer.pause(); 113 | Data.play = false; 114 | }); 115 | } 116 | break; 117 | } 118 | } 119 | 120 | playAgain() async{ 121 | await audioPlayer.play(Data.music == "" ? 122 | "https://firebasestorage.googleapis.com/v0/b/memory-game-3236c.appspot.com/o/ES_Gentle%20Melody%20-%20Megan%20Wofford.mp3?alt=media&token=987b1275-673c-4cb2-9919-ec088b2c662a": 123 | Data.music); 124 | } 125 | 126 | getHighScore() async { 127 | SharedPreferences myPrefs = await SharedPreferences.getInstance(); 128 | 129 | if(myPrefs.getInt("hp") != null && myPrefs.getInt("tp") != null) { 130 | setState(() { 131 | Data.highScoreInPokemon = myPrefs.getInt("hp"); 132 | Data.timeInPokemon = myPrefs.getInt("tp"); 133 | }); 134 | } 135 | 136 | if(myPrefs.getInt("he") != null && myPrefs.getInt("te") != null) { 137 | setState(() { 138 | Data.highScoreInEmoji = myPrefs.getInt("he"); 139 | Data.timeInEmoji = myPrefs.getInt("te"); 140 | }); 141 | } 142 | 143 | if(myPrefs.getInt("hn") != null && myPrefs.getInt("tn") != null) { 144 | setState(() { 145 | Data.highScoreInNumber = myPrefs.getInt("hn"); 146 | Data.timeInNumber = myPrefs.getInt("tn"); 147 | }); 148 | } 149 | 150 | if(myPrefs.getBool("play") != null) { 151 | setState(() { 152 | Data.neverPlay = myPrefs.getBool("play"); 153 | }); 154 | } 155 | } 156 | 157 | rate() async{ 158 | try{ 159 | fireStore.then((value) async { 160 | FirebaseFirestore.instance. 161 | collection("memory").doc("1") 162 | .get().then((result){ 163 | launch(result.get("stars")); 164 | }); 165 | }); 166 | }catch (e){ 167 | snackBar("Something went wrong"); 168 | } 169 | } 170 | 171 | Future share() async { 172 | try{ 173 | fireStore.then((value) async { 174 | FirebaseFirestore.instance. 175 | collection("memory").doc("1") 176 | .get().then((result){ 177 | Share.share(result.get("share")); 178 | }); 179 | }); 180 | }catch (e){ 181 | snackBar("Something went wrong"); 182 | } 183 | } 184 | 185 | snackBar(String s){ 186 | // ignore: deprecated_member_use 187 | _scaffoldKey.currentState.showSnackBar( 188 | SnackBar(duration: Duration(milliseconds: 2000),backgroundColor: Colors.white, 189 | padding: EdgeInsets.only(left: 25), 190 | shape: RoundedRectangleBorder(borderRadius: BorderRadius.circular(15)), 191 | content: Text(s, 192 | style: TextStyle( 193 | color: Colors.black, 194 | fontSize: 16, 195 | fontWeight: FontWeight.w600),), 196 | behavior: SnackBarBehavior.floating)); 197 | } 198 | 199 | @override 200 | void dispose() { 201 | super.dispose(); 202 | timer.cancel(); 203 | } 204 | 205 | @override 206 | Widget build(BuildContext context) { 207 | return Scaffold( 208 | key: _scaffoldKey, 209 | body: AnimatedContainer( 210 | duration: Duration(milliseconds: 2500), 211 | decoration: BoxDecoration( 212 | 213 | gradient: LinearGradient( 214 | 215 | begin: change == false ? Alignment.topRight: Alignment.topLeft, 216 | end: change == false ? Alignment.bottomLeft : Alignment.bottomRight, 217 | 218 | stops: [0, 219 | change == false ? 0.4 : 0.6, 220 | 1], 221 | 222 | colors: [ 223 | Color(0xffFFCC70), 224 | Color(0xffC850C0), 225 | Color(0xff4158D0), 226 | ] 227 | ) 228 | ), 229 | child: Stack( 230 | alignment: Alignment.center, 231 | children: [ 232 | Positioned( 233 | top: MediaQuery.of(context).size.height*0.14, 234 | child: Column( 235 | mainAxisAlignment: MainAxisAlignment.start, 236 | crossAxisAlignment: CrossAxisAlignment.center, 237 | children: [ 238 | Container( 239 | height: MediaQuery.of(context).size.height*0.2, 240 | width: MediaQuery.of(context).size.width*0.75, 241 | child: Card( 242 | margin: EdgeInsets.all(0), 243 | color: Colors.white, 244 | shape: RoundedRectangleBorder( 245 | borderRadius: BorderRadius.circular(25), 246 | ), 247 | elevation: 10, 248 | child: Center( 249 | child: AnimatedTextKit( 250 | animatedTexts: [ 251 | WavyAnimatedText("Memory Game", 252 | speed: Duration(milliseconds: 450), 253 | textStyle: TextStyle( 254 | fontSize: 29, 255 | fontFamily: "Source", 256 | fontWeight: FontWeight.w600, 257 | color: Color(0xffDD2A7B), 258 | )), 259 | ], 260 | repeatForever: true, 261 | isRepeatingAnimation: true, 262 | ), 263 | ), 264 | ), 265 | ), 266 | SizedBox( 267 | height: MediaQuery.of(context).size.width*0.12, 268 | ), 269 | GestureDetector( 270 | onTap: (){ 271 | setState((){ 272 | Data.level = 1; 273 | }); 274 | Navigator.push(context, MaterialPageRoute(builder: (context) { 275 | return Challenges(); 276 | },)); 277 | }, 278 | 279 | onTapDown: (value){ 280 | setState(() { 281 | newGame = true; 282 | }); 283 | }, 284 | 285 | onTapUp: (value){ 286 | setState(() { 287 | newGame = false; 288 | }); 289 | }, 290 | 291 | child: AnimatedContainer( 292 | duration: Duration(milliseconds: 200), 293 | curve: Curves.bounceInOut, 294 | height: newGame == false ? 65 : 60, 295 | width: newGame == false ? 200 : 185, 296 | child: Card( 297 | margin: EdgeInsets.all(0), 298 | color: Colors.white, 299 | shape: RoundedRectangleBorder( 300 | borderRadius: BorderRadius.circular(20), 301 | ), 302 | elevation: 10, 303 | child: Center( 304 | child: Text("Levels", 305 | style: TextStyle( 306 | fontSize: 20, 307 | fontFamily: "Source", 308 | fontWeight: FontWeight.w600, 309 | color: Color(0xffDD2A7B), 310 | ),) 311 | ), 312 | ), 313 | ), 314 | ), 315 | SizedBox( 316 | height: 30, 317 | ), 318 | GestureDetector( 319 | onTap: (){ 320 | Navigator.push(context, MaterialPageRoute(builder: (context) { 321 | return ChooseChallenges(); 322 | },)); 323 | }, 324 | 325 | onTapDown: (value){ 326 | setState(() { 327 | level = true; 328 | }); 329 | }, 330 | 331 | onTapUp: (value){ 332 | setState(() { 333 | level = false; 334 | }); 335 | }, 336 | child: AnimatedContainer( 337 | duration: Duration(milliseconds: 200), 338 | curve: Curves.bounceInOut, 339 | height: level == false ? 70 : 65, 340 | width: level == false ? 215 : 200, 341 | child: Card( 342 | margin: EdgeInsets.all(0), 343 | color: Colors.white, 344 | shape: RoundedRectangleBorder( 345 | borderRadius: BorderRadius.circular(20), 346 | ), 347 | elevation: 10, 348 | child: Center( 349 | child: Text("Challenges", 350 | style: TextStyle( 351 | fontSize: 20, 352 | fontFamily: "Source", 353 | fontWeight: FontWeight.w600, 354 | color: Color(0xffDD2A7B), 355 | ),)), 356 | ), 357 | ), 358 | ), 359 | SizedBox( 360 | height: 30, 361 | ), 362 | GestureDetector( 363 | onTap: (){ 364 | Navigator.push(context, MaterialPageRoute(builder: (context) { 365 | return Memory(); 366 | },)); 367 | }, 368 | onTapDown: (value){ 369 | setState(() { 370 | challenges = true; 371 | }); 372 | }, 373 | onTapUp: (value){ 374 | setState(() { 375 | challenges = false; 376 | }); 377 | }, 378 | child: AnimatedContainer( 379 | duration: Duration(milliseconds: 200), 380 | curve: Curves.bounceInOut, 381 | height: challenges == false ? 70 : 65, 382 | width: challenges == false ? 215 : 200, 383 | child: Card( 384 | margin: EdgeInsets.all(0), 385 | color: Colors.white, 386 | shape: RoundedRectangleBorder( 387 | borderRadius: BorderRadius.circular(20), 388 | ), 389 | elevation: 10, 390 | child: Center(child: Text("Marathon", 391 | style: TextStyle( 392 | fontSize: 20, 393 | fontFamily: "Source", 394 | fontWeight: FontWeight.w600, 395 | color: Color(0xffDD2A7B), 396 | ),)), 397 | ), 398 | ), 399 | ), 400 | SizedBox( 401 | height: 30, 402 | ), 403 | GestureDetector( 404 | onTap: (){ 405 | Navigator.push(context, MaterialPageRoute(builder: (context) { 406 | return BrainJam(); 407 | },)); 408 | }, 409 | 410 | onTapDown: (value){ 411 | setState(() { 412 | highScore = true; 413 | }); 414 | }, 415 | 416 | onTapUp: (value){ 417 | setState(() { 418 | highScore = false; 419 | }); 420 | }, 421 | child: AnimatedContainer( 422 | duration: Duration(milliseconds: 200), 423 | curve: Curves.bounceInOut, 424 | height: highScore == false ? 65 : 60, 425 | width: highScore == false ? 200 : 185, 426 | child: Card( 427 | margin: EdgeInsets.all(0), 428 | color: Colors.white, 429 | shape: RoundedRectangleBorder( 430 | borderRadius: BorderRadius.circular(20), 431 | ), 432 | elevation: 10, 433 | child: Center( 434 | child: Text("Brain Jam", 435 | style: TextStyle( 436 | fontSize: 20, 437 | fontFamily: "Source", 438 | fontWeight: FontWeight.w600, 439 | color: Color(0xffDD2A7B), 440 | ),)), 441 | ), 442 | ), 443 | ), 444 | ], 445 | ), 446 | ), 447 | Positioned( 448 | bottom: 5, 449 | right: 0, 450 | child: Row( 451 | mainAxisAlignment: MainAxisAlignment.start, 452 | crossAxisAlignment: CrossAxisAlignment.center, 453 | children: [ 454 | IconButton( 455 | icon: Icon(Data.neverPlay == true ? 456 | Icons.play_circle_outline : 457 | Icons.pause_circle_outline), 458 | iconSize: 28, 459 | color: Colors.white, 460 | onPressed: (){ 461 | setState(() { 462 | if(Data.neverPlay == false){ 463 | audioPlayer.pause(); 464 | Data.neverPlay = true; 465 | }else{ 466 | audioPlayer.resume(); 467 | Data.neverPlay = false; 468 | } 469 | }); 470 | }, 471 | ), 472 | 473 | IconButton( 474 | icon: Icon(Icons.help), 475 | iconSize: 26, 476 | color: Colors.white, 477 | onPressed: (){ 478 | Navigator.push(context, MaterialPageRoute(builder: (context){ 479 | return Help(); 480 | })); 481 | }, 482 | ), 483 | 484 | IconButton( 485 | icon: Icon(Icons.star), 486 | iconSize: 26, 487 | color: Colors.white, 488 | onPressed: (){ 489 | rate(); 490 | }, 491 | ), 492 | 493 | IconButton( 494 | icon: Icon(Icons.share), 495 | iconSize: 25, 496 | color: Colors.white, 497 | onPressed: (){ 498 | share(); 499 | }, 500 | ), 501 | 502 | IconButton( 503 | icon: Icon(Icons.settings), 504 | iconSize: 25, 505 | color: Colors.white, 506 | onPressed: (){ 507 | Navigator.push(context, MaterialPageRoute(builder: (context) { 508 | return Setting(); 509 | },)); 510 | }, 511 | ), 512 | ], 513 | ), 514 | ) 515 | ], 516 | ), 517 | 518 | ), 519 | ); 520 | } 521 | } 522 | -------------------------------------------------------------------------------- /ios/Runner.xcodeproj/project.pbxproj: -------------------------------------------------------------------------------- 1 | // !$*UTF8*$! 2 | { 3 | archiveVersion = 1; 4 | classes = { 5 | }; 6 | objectVersion = 46; 7 | objects = { 8 | 9 | /* Begin PBXBuildFile section */ 10 | 1498D2341E8E89220040F4C2 /* GeneratedPluginRegistrant.m in Sources */ = {isa = PBXBuildFile; fileRef = 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */; }; 11 | 3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */ = {isa = PBXBuildFile; fileRef = 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */; }; 12 | 978B8F6F1D3862AE00F588F7 /* AppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 7AFFD8EE1D35381100E5BB4D /* AppDelegate.m */; }; 13 | 97C146F31CF9000F007C117D /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 97C146F21CF9000F007C117D /* main.m */; }; 14 | 97C146FC1CF9000F007C117D /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FA1CF9000F007C117D /* Main.storyboard */; }; 15 | 97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FD1CF9000F007C117D /* Assets.xcassets */; }; 16 | 97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */; }; 17 | /* End PBXBuildFile section */ 18 | 19 | /* Begin PBXCopyFilesBuildPhase section */ 20 | 9705A1C41CF9048500538489 /* Embed Frameworks */ = { 21 | isa = PBXCopyFilesBuildPhase; 22 | buildActionMask = 2147483647; 23 | dstPath = ""; 24 | dstSubfolderSpec = 10; 25 | files = ( 26 | ); 27 | name = "Embed Frameworks"; 28 | runOnlyForDeploymentPostprocessing = 0; 29 | }; 30 | /* End PBXCopyFilesBuildPhase section */ 31 | 32 | /* Begin PBXFileReference section */ 33 | 1498D2321E8E86230040F4C2 /* GeneratedPluginRegistrant.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = GeneratedPluginRegistrant.h; sourceTree = ""; }; 34 | 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = GeneratedPluginRegistrant.m; sourceTree = ""; }; 35 | 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = AppFrameworkInfo.plist; path = Flutter/AppFrameworkInfo.plist; sourceTree = ""; }; 36 | 7AFA3C8E1D35360C0083082E /* Release.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; name = Release.xcconfig; path = Flutter/Release.xcconfig; sourceTree = ""; }; 37 | 7AFFD8ED1D35381100E5BB4D /* AppDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AppDelegate.h; sourceTree = ""; }; 38 | 7AFFD8EE1D35381100E5BB4D /* AppDelegate.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = AppDelegate.m; sourceTree = ""; }; 39 | 9740EEB21CF90195004384FC /* Debug.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Debug.xcconfig; path = Flutter/Debug.xcconfig; sourceTree = ""; }; 40 | 9740EEB31CF90195004384FC /* Generated.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Generated.xcconfig; path = Flutter/Generated.xcconfig; sourceTree = ""; }; 41 | 97C146EE1CF9000F007C117D /* Runner.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = Runner.app; sourceTree = BUILT_PRODUCTS_DIR; }; 42 | 97C146F21CF9000F007C117D /* main.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = ""; }; 43 | 97C146FB1CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; }; 44 | 97C146FD1CF9000F007C117D /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; 45 | 97C147001CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; }; 46 | 97C147021CF9000F007C117D /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 47 | /* End PBXFileReference section */ 48 | 49 | /* Begin PBXFrameworksBuildPhase section */ 50 | 97C146EB1CF9000F007C117D /* Frameworks */ = { 51 | isa = PBXFrameworksBuildPhase; 52 | buildActionMask = 2147483647; 53 | files = ( 54 | ); 55 | runOnlyForDeploymentPostprocessing = 0; 56 | }; 57 | /* End PBXFrameworksBuildPhase section */ 58 | 59 | /* Begin PBXGroup section */ 60 | 9740EEB11CF90186004384FC /* Flutter */ = { 61 | isa = PBXGroup; 62 | children = ( 63 | 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */, 64 | 9740EEB21CF90195004384FC /* Debug.xcconfig */, 65 | 7AFA3C8E1D35360C0083082E /* Release.xcconfig */, 66 | 9740EEB31CF90195004384FC /* Generated.xcconfig */, 67 | ); 68 | name = Flutter; 69 | sourceTree = ""; 70 | }; 71 | 97C146E51CF9000F007C117D = { 72 | isa = PBXGroup; 73 | children = ( 74 | 9740EEB11CF90186004384FC /* Flutter */, 75 | 97C146F01CF9000F007C117D /* Runner */, 76 | 97C146EF1CF9000F007C117D /* Products */, 77 | CF3B75C9A7D2FA2A4C99F110 /* Frameworks */, 78 | ); 79 | sourceTree = ""; 80 | }; 81 | 97C146EF1CF9000F007C117D /* Products */ = { 82 | isa = PBXGroup; 83 | children = ( 84 | 97C146EE1CF9000F007C117D /* Runner.app */, 85 | ); 86 | name = Products; 87 | sourceTree = ""; 88 | }; 89 | 97C146F01CF9000F007C117D /* Runner */ = { 90 | isa = PBXGroup; 91 | children = ( 92 | 7AFFD8ED1D35381100E5BB4D /* AppDelegate.h */, 93 | 7AFFD8EE1D35381100E5BB4D /* AppDelegate.m */, 94 | 97C146FA1CF9000F007C117D /* Main.storyboard */, 95 | 97C146FD1CF9000F007C117D /* Assets.xcassets */, 96 | 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */, 97 | 97C147021CF9000F007C117D /* Info.plist */, 98 | 97C146F11CF9000F007C117D /* Supporting Files */, 99 | 1498D2321E8E86230040F4C2 /* GeneratedPluginRegistrant.h */, 100 | 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */, 101 | ); 102 | path = Runner; 103 | sourceTree = ""; 104 | }; 105 | 97C146F11CF9000F007C117D /* Supporting Files */ = { 106 | isa = PBXGroup; 107 | children = ( 108 | 97C146F21CF9000F007C117D /* main.m */, 109 | ); 110 | name = "Supporting Files"; 111 | sourceTree = ""; 112 | }; 113 | /* End PBXGroup section */ 114 | 115 | /* Begin PBXNativeTarget section */ 116 | 97C146ED1CF9000F007C117D /* Runner */ = { 117 | isa = PBXNativeTarget; 118 | buildConfigurationList = 97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */; 119 | buildPhases = ( 120 | 9740EEB61CF901F6004384FC /* Run Script */, 121 | 97C146EA1CF9000F007C117D /* Sources */, 122 | 97C146EB1CF9000F007C117D /* Frameworks */, 123 | 97C146EC1CF9000F007C117D /* Resources */, 124 | 9705A1C41CF9048500538489 /* Embed Frameworks */, 125 | 3B06AD1E1E4923F5004D2608 /* Thin Binary */, 126 | ); 127 | buildRules = ( 128 | ); 129 | dependencies = ( 130 | ); 131 | name = Runner; 132 | productName = Runner; 133 | productReference = 97C146EE1CF9000F007C117D /* Runner.app */; 134 | productType = "com.apple.product-type.application"; 135 | }; 136 | /* End PBXNativeTarget section */ 137 | 138 | /* Begin PBXProject section */ 139 | 97C146E61CF9000F007C117D /* Project object */ = { 140 | isa = PBXProject; 141 | attributes = { 142 | LastUpgradeCheck = 1020; 143 | ORGANIZATIONNAME = ""; 144 | TargetAttributes = { 145 | 97C146ED1CF9000F007C117D = { 146 | CreatedOnToolsVersion = 7.3.1; 147 | }; 148 | }; 149 | }; 150 | buildConfigurationList = 97C146E91CF9000F007C117D /* Build configuration list for PBXProject "Runner" */; 151 | compatibilityVersion = "Xcode 9.3"; 152 | developmentRegion = en; 153 | hasScannedForEncodings = 0; 154 | knownRegions = ( 155 | en, 156 | Base, 157 | ); 158 | mainGroup = 97C146E51CF9000F007C117D; 159 | productRefGroup = 97C146EF1CF9000F007C117D /* Products */; 160 | projectDirPath = ""; 161 | projectRoot = ""; 162 | targets = ( 163 | 97C146ED1CF9000F007C117D /* Runner */, 164 | ); 165 | }; 166 | /* End PBXProject section */ 167 | 168 | /* Begin PBXResourcesBuildPhase section */ 169 | 97C146EC1CF9000F007C117D /* Resources */ = { 170 | isa = PBXResourcesBuildPhase; 171 | buildActionMask = 2147483647; 172 | files = ( 173 | 97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */, 174 | 3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */, 175 | 97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */, 176 | 97C146FC1CF9000F007C117D /* Main.storyboard in Resources */, 177 | ); 178 | runOnlyForDeploymentPostprocessing = 0; 179 | }; 180 | /* End PBXResourcesBuildPhase section */ 181 | 182 | /* Begin PBXShellScriptBuildPhase section */ 183 | 3B06AD1E1E4923F5004D2608 /* Thin Binary */ = { 184 | isa = PBXShellScriptBuildPhase; 185 | buildActionMask = 2147483647; 186 | files = ( 187 | ); 188 | inputPaths = ( 189 | ); 190 | name = "Thin Binary"; 191 | outputPaths = ( 192 | ); 193 | runOnlyForDeploymentPostprocessing = 0; 194 | shellPath = /bin/sh; 195 | shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" embed_and_thin"; 196 | }; 197 | 9740EEB61CF901F6004384FC /* Run Script */ = { 198 | isa = PBXShellScriptBuildPhase; 199 | buildActionMask = 2147483647; 200 | files = ( 201 | ); 202 | inputPaths = ( 203 | ); 204 | name = "Run Script"; 205 | outputPaths = ( 206 | ); 207 | runOnlyForDeploymentPostprocessing = 0; 208 | shellPath = /bin/sh; 209 | shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" build"; 210 | }; 211 | /* End PBXShellScriptBuildPhase section */ 212 | 213 | /* Begin PBXSourcesBuildPhase section */ 214 | 97C146EA1CF9000F007C117D /* Sources */ = { 215 | isa = PBXSourcesBuildPhase; 216 | buildActionMask = 2147483647; 217 | files = ( 218 | 978B8F6F1D3862AE00F588F7 /* AppDelegate.m in Sources */, 219 | 97C146F31CF9000F007C117D /* main.m in Sources */, 220 | 1498D2341E8E89220040F4C2 /* GeneratedPluginRegistrant.m in Sources */, 221 | ); 222 | runOnlyForDeploymentPostprocessing = 0; 223 | }; 224 | /* End PBXSourcesBuildPhase section */ 225 | 226 | /* Begin PBXVariantGroup section */ 227 | 97C146FA1CF9000F007C117D /* Main.storyboard */ = { 228 | isa = PBXVariantGroup; 229 | children = ( 230 | 97C146FB1CF9000F007C117D /* Base */, 231 | ); 232 | name = Main.storyboard; 233 | sourceTree = ""; 234 | }; 235 | 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */ = { 236 | isa = PBXVariantGroup; 237 | children = ( 238 | 97C147001CF9000F007C117D /* Base */, 239 | ); 240 | name = LaunchScreen.storyboard; 241 | sourceTree = ""; 242 | }; 243 | /* End PBXVariantGroup section */ 244 | 245 | /* Begin XCBuildConfiguration section */ 246 | 249021D3217E4FDB00AE95B9 /* Profile */ = { 247 | isa = XCBuildConfiguration; 248 | buildSettings = { 249 | ALWAYS_SEARCH_USER_PATHS = NO; 250 | CLANG_ANALYZER_NONNULL = YES; 251 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 252 | CLANG_CXX_LIBRARY = "libc++"; 253 | CLANG_ENABLE_MODULES = YES; 254 | CLANG_ENABLE_OBJC_ARC = YES; 255 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; 256 | CLANG_WARN_BOOL_CONVERSION = YES; 257 | CLANG_WARN_COMMA = YES; 258 | CLANG_WARN_CONSTANT_CONVERSION = YES; 259 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; 260 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 261 | CLANG_WARN_EMPTY_BODY = YES; 262 | CLANG_WARN_ENUM_CONVERSION = YES; 263 | CLANG_WARN_INFINITE_RECURSION = YES; 264 | CLANG_WARN_INT_CONVERSION = YES; 265 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; 266 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; 267 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; 268 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 269 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; 270 | CLANG_WARN_STRICT_PROTOTYPES = YES; 271 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 272 | CLANG_WARN_UNREACHABLE_CODE = YES; 273 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 274 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 275 | COPY_PHASE_STRIP = NO; 276 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; 277 | ENABLE_NS_ASSERTIONS = NO; 278 | ENABLE_STRICT_OBJC_MSGSEND = YES; 279 | GCC_C_LANGUAGE_STANDARD = gnu99; 280 | GCC_NO_COMMON_BLOCKS = YES; 281 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 282 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 283 | GCC_WARN_UNDECLARED_SELECTOR = YES; 284 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 285 | GCC_WARN_UNUSED_FUNCTION = YES; 286 | GCC_WARN_UNUSED_VARIABLE = YES; 287 | IPHONEOS_DEPLOYMENT_TARGET = 9.0; 288 | MTL_ENABLE_DEBUG_INFO = NO; 289 | SDKROOT = iphoneos; 290 | SUPPORTED_PLATFORMS = iphoneos; 291 | TARGETED_DEVICE_FAMILY = "1,2"; 292 | VALIDATE_PRODUCT = YES; 293 | }; 294 | name = Profile; 295 | }; 296 | 249021D4217E4FDB00AE95B9 /* Profile */ = { 297 | isa = XCBuildConfiguration; 298 | baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */; 299 | buildSettings = { 300 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 301 | CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; 302 | ENABLE_BITCODE = NO; 303 | FRAMEWORK_SEARCH_PATHS = ( 304 | "$(inherited)", 305 | "$(PROJECT_DIR)/Flutter", 306 | ); 307 | INFOPLIST_FILE = Runner/Info.plist; 308 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; 309 | LIBRARY_SEARCH_PATHS = ( 310 | "$(inherited)", 311 | "$(PROJECT_DIR)/Flutter", 312 | ); 313 | PRODUCT_BUNDLE_IDENTIFIER = com.blackhole.memory; 314 | PRODUCT_NAME = "$(TARGET_NAME)"; 315 | VERSIONING_SYSTEM = "apple-generic"; 316 | }; 317 | name = Profile; 318 | }; 319 | 97C147031CF9000F007C117D /* Debug */ = { 320 | isa = XCBuildConfiguration; 321 | buildSettings = { 322 | ALWAYS_SEARCH_USER_PATHS = NO; 323 | CLANG_ANALYZER_NONNULL = YES; 324 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 325 | CLANG_CXX_LIBRARY = "libc++"; 326 | CLANG_ENABLE_MODULES = YES; 327 | CLANG_ENABLE_OBJC_ARC = YES; 328 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; 329 | CLANG_WARN_BOOL_CONVERSION = YES; 330 | CLANG_WARN_COMMA = YES; 331 | CLANG_WARN_CONSTANT_CONVERSION = YES; 332 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; 333 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 334 | CLANG_WARN_EMPTY_BODY = YES; 335 | CLANG_WARN_ENUM_CONVERSION = YES; 336 | CLANG_WARN_INFINITE_RECURSION = YES; 337 | CLANG_WARN_INT_CONVERSION = YES; 338 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; 339 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; 340 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; 341 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 342 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; 343 | CLANG_WARN_STRICT_PROTOTYPES = YES; 344 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 345 | CLANG_WARN_UNREACHABLE_CODE = YES; 346 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 347 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 348 | COPY_PHASE_STRIP = NO; 349 | DEBUG_INFORMATION_FORMAT = dwarf; 350 | ENABLE_STRICT_OBJC_MSGSEND = YES; 351 | ENABLE_TESTABILITY = YES; 352 | GCC_C_LANGUAGE_STANDARD = gnu99; 353 | GCC_DYNAMIC_NO_PIC = NO; 354 | GCC_NO_COMMON_BLOCKS = YES; 355 | GCC_OPTIMIZATION_LEVEL = 0; 356 | GCC_PREPROCESSOR_DEFINITIONS = ( 357 | "DEBUG=1", 358 | "$(inherited)", 359 | ); 360 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 361 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 362 | GCC_WARN_UNDECLARED_SELECTOR = YES; 363 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 364 | GCC_WARN_UNUSED_FUNCTION = YES; 365 | GCC_WARN_UNUSED_VARIABLE = YES; 366 | IPHONEOS_DEPLOYMENT_TARGET = 9.0; 367 | MTL_ENABLE_DEBUG_INFO = YES; 368 | ONLY_ACTIVE_ARCH = YES; 369 | SDKROOT = iphoneos; 370 | TARGETED_DEVICE_FAMILY = "1,2"; 371 | }; 372 | name = Debug; 373 | }; 374 | 97C147041CF9000F007C117D /* Release */ = { 375 | isa = XCBuildConfiguration; 376 | buildSettings = { 377 | ALWAYS_SEARCH_USER_PATHS = NO; 378 | CLANG_ANALYZER_NONNULL = YES; 379 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 380 | CLANG_CXX_LIBRARY = "libc++"; 381 | CLANG_ENABLE_MODULES = YES; 382 | CLANG_ENABLE_OBJC_ARC = YES; 383 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; 384 | CLANG_WARN_BOOL_CONVERSION = YES; 385 | CLANG_WARN_COMMA = YES; 386 | CLANG_WARN_CONSTANT_CONVERSION = YES; 387 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; 388 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 389 | CLANG_WARN_EMPTY_BODY = YES; 390 | CLANG_WARN_ENUM_CONVERSION = YES; 391 | CLANG_WARN_INFINITE_RECURSION = YES; 392 | CLANG_WARN_INT_CONVERSION = YES; 393 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; 394 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; 395 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; 396 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 397 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; 398 | CLANG_WARN_STRICT_PROTOTYPES = YES; 399 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 400 | CLANG_WARN_UNREACHABLE_CODE = YES; 401 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 402 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 403 | COPY_PHASE_STRIP = NO; 404 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; 405 | ENABLE_NS_ASSERTIONS = NO; 406 | ENABLE_STRICT_OBJC_MSGSEND = YES; 407 | GCC_C_LANGUAGE_STANDARD = gnu99; 408 | GCC_NO_COMMON_BLOCKS = YES; 409 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 410 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 411 | GCC_WARN_UNDECLARED_SELECTOR = YES; 412 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 413 | GCC_WARN_UNUSED_FUNCTION = YES; 414 | GCC_WARN_UNUSED_VARIABLE = YES; 415 | IPHONEOS_DEPLOYMENT_TARGET = 9.0; 416 | MTL_ENABLE_DEBUG_INFO = NO; 417 | SDKROOT = iphoneos; 418 | SUPPORTED_PLATFORMS = iphoneos; 419 | TARGETED_DEVICE_FAMILY = "1,2"; 420 | VALIDATE_PRODUCT = YES; 421 | }; 422 | name = Release; 423 | }; 424 | 97C147061CF9000F007C117D /* Debug */ = { 425 | isa = XCBuildConfiguration; 426 | baseConfigurationReference = 9740EEB21CF90195004384FC /* Debug.xcconfig */; 427 | buildSettings = { 428 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 429 | CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; 430 | ENABLE_BITCODE = NO; 431 | FRAMEWORK_SEARCH_PATHS = ( 432 | "$(inherited)", 433 | "$(PROJECT_DIR)/Flutter", 434 | ); 435 | INFOPLIST_FILE = Runner/Info.plist; 436 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; 437 | LIBRARY_SEARCH_PATHS = ( 438 | "$(inherited)", 439 | "$(PROJECT_DIR)/Flutter", 440 | ); 441 | PRODUCT_BUNDLE_IDENTIFIER = com.blackhole.memory; 442 | PRODUCT_NAME = "$(TARGET_NAME)"; 443 | VERSIONING_SYSTEM = "apple-generic"; 444 | }; 445 | name = Debug; 446 | }; 447 | 97C147071CF9000F007C117D /* Release */ = { 448 | isa = XCBuildConfiguration; 449 | baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */; 450 | buildSettings = { 451 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 452 | CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; 453 | ENABLE_BITCODE = NO; 454 | FRAMEWORK_SEARCH_PATHS = ( 455 | "$(inherited)", 456 | "$(PROJECT_DIR)/Flutter", 457 | ); 458 | INFOPLIST_FILE = Runner/Info.plist; 459 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; 460 | LIBRARY_SEARCH_PATHS = ( 461 | "$(inherited)", 462 | "$(PROJECT_DIR)/Flutter", 463 | ); 464 | PRODUCT_BUNDLE_IDENTIFIER = com.blackhole.memory; 465 | PRODUCT_NAME = "$(TARGET_NAME)"; 466 | VERSIONING_SYSTEM = "apple-generic"; 467 | }; 468 | name = Release; 469 | }; 470 | /* End XCBuildConfiguration section */ 471 | 472 | /* Begin XCConfigurationList section */ 473 | 97C146E91CF9000F007C117D /* Build configuration list for PBXProject "Runner" */ = { 474 | isa = XCConfigurationList; 475 | buildConfigurations = ( 476 | 97C147031CF9000F007C117D /* Debug */, 477 | 97C147041CF9000F007C117D /* Release */, 478 | 249021D3217E4FDB00AE95B9 /* Profile */, 479 | ); 480 | defaultConfigurationIsVisible = 0; 481 | defaultConfigurationName = Release; 482 | }; 483 | 97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */ = { 484 | isa = XCConfigurationList; 485 | buildConfigurations = ( 486 | 97C147061CF9000F007C117D /* Debug */, 487 | 97C147071CF9000F007C117D /* Release */, 488 | 249021D4217E4FDB00AE95B9 /* Profile */, 489 | ); 490 | defaultConfigurationIsVisible = 0; 491 | defaultConfigurationName = Release; 492 | }; 493 | /* End XCConfigurationList section */ 494 | }; 495 | rootObject = 97C146E61CF9000F007C117D /* Project object */; 496 | } 497 | --------------------------------------------------------------------------------