تنظيم صفحاتك في مجموعات
يمكنك حفظ المحتوى وتصنيفه حسب إعداداتك المفضّلة.
يوضّح هذا الدليل كيفية إعداد مشروع على "استوديو Android" لاستخدام
حزمة SDK لـ "خدمات ألعاب Play". يجب إكمال هذه الخطوات قبل
إعداد ميزة تسجيل الدخول في "خدمات ألعاب Play" وإضافة
ميزات "خدمات ألعاب Play" إلى لعبتك.
قبل البدء
لإعداد تطبيقك، أكمِل الخطوات الواردة في الأقسام التالية.
متطلبات التطبيق الأساسية
تأكَّد من أنّ ملف إنشاء تطبيقك يستخدم القيم التالية:
minSdkVersion من 19 أو أعلى
compileSdkVersion من 28 أو أعلى
إعداد لعبتك في Google Play Console
يمكنك من خلال Play Console إدارة "خدمات ألعاب Google Play" للعبة
وضبط البيانات الوصفية لمنح الأذونات اللازمة للّعبة والمصادقة عليها. للحصول على
مزيد من المعلومات، يُرجى الاطّلاع على
إعداد "خدمات ألعاب Google Play".
بعد إكمال هذه الخطوات، عليك إعداد ميزة
تسجيل الدخول
لكي تتمكّن اللعبة من الوصول إلى ميزات "خدمات ألعاب Play".
يخضع كل من المحتوى وعيّنات التعليمات البرمجية في هذه الصفحة للتراخيص الموضحّة في ترخيص استخدام المحتوى. إنّ Java وOpenJDK هما علامتان تجاريتان مسجَّلتان لشركة Oracle و/أو الشركات التابعة لها.
تاريخ التعديل الأخير: 2025-07-26 (حسب التوقيت العالمي المتفَّق عليه)
[[["يسهُل فهم المحتوى.","easyToUnderstand","thumb-up"],["ساعَدني المحتوى في حلّ مشكلتي.","solvedMyProblem","thumb-up"],["غير ذلك","otherUp","thumb-up"]],[["لا يحتوي على المعلومات التي أحتاج إليها.","missingTheInformationINeed","thumb-down"],["الخطوات معقدة للغاية / كثيرة جدًا.","tooComplicatedTooManySteps","thumb-down"],["المحتوى قديم.","outOfDate","thumb-down"],["ثمة مشكلة في الترجمة.","translationIssue","thumb-down"],["مشكلة في العيّنات / التعليمات البرمجية","samplesCodeIssue","thumb-down"],["غير ذلك","otherDown","thumb-down"]],["تاريخ التعديل الأخير: 2025-07-26 (حسب التوقيت العالمي المتفَّق عليه)"],[],[],null,["# Get started with Play Games Services for Android games\n\n| **Note:** This guide is for the Play Games Services v2 SDK. For information on the previous version of this SDK, see the [Play Games Services v1\n| documentation](/games/pgs/v1/android).\n\nThis guide describes how to set up an Android Studio project to use the\nPlay Games Services SDK. You must complete these steps before you\nset up Play Games Services [sign-in](/games/pgs/android/android-signin) and add\nPlay Games Services features to your game.\n\nBefore you begin\n----------------\n\nTo prepare your app, complete the steps in the following sections.\n\n### App prerequisites\n\nMake sure that your app's build file uses the following values:\n\n- A `minSdkVersion` of `19` of higher\n- A `compileSdkVersion` of `28` or higher\n\n### Set up your game in Google Play Console\n\nThe Google Play Console is where you manage Google Play games services for your\ngame, and configure metadata for authorizing and authenticating your game. For\nmore information, see\n[Set Up Google Play Games Services](/games/pgs/console/setup).\n\nConfigure your app\n------------------\n\nIn your project-level `build.gradle` file, include\n[Google's Maven repository](https://maven.google.com/web/index.html)\nand [Maven central repository](https://search.maven.org/artifact)\nin both your `buildscript` and `allprojects` sections: \n\n buildscript {\n repositories {\n google()\n mavenCentral()\n }\n }\n\n allprojects {\n repositories {\n google()\n mavenCentral()\n }\n }\n\nAdd the [Google Play services](https://developers.google.com/android)\ndependency for the Play Games SDK to your\n[module's Gradle build file](/studio/build#module-level), which is commonly\n\n`app/build.gradle`: \n\n dependencies {\n implementation \"com.google.android.gms:play-services-games-v2:+\"\n }\n\nAfter completing these steps you must set up\n[sign-in](/games/pgs/android/android-signin)\nin order for the game to access Play Games Services features."]]