dir.by  
  Поиск  
Компьютер, программы
MonoGame - develop games on C# for computers (Windows, Linux), phones (Android, iOS), game consoles (Xbox, PlayStation, Nintendo Switch)
 Запуск и отладка MonoGame приложения на компьютере(Windows) в режиме эмулятора Android 
посмотрели 8141 раз
обновлено: 16 Augusta 2023
1) Компилирем приложение: Menu → Build → Build Solution (Ctrl + Shift + B)
нет ошибок
2) Запускаем приложение: Menu → Debug → Start Without Debugging (Ctrl + F5)
При запуске видим телефон и надпись "Game1 has stopped"
Чтобы понять где ошибка запускаем проект в debug режиме (F5)
  Видим ошибки
Android application is debugging.
10-10 17:59:27.851 I/art ( 3361): Not late-enabling -Xcheck:jni (already on)
10-10 17:59:27.851 W/art ( 3361): Unexpected CPU variant for X86 using defaults: x86_64
10-10 17:59:27.935 D/AndroidRuntime( 3361): Shutting down VM
10-10 17:59:27.936 E/AndroidRuntime( 3361): FATAL EXCEPTION: main
10-10 17:59:27.936 E/AndroidRuntime( 3361): Process: Game1.Game1, PID: 3361
10-10 17:59:27.936 E/AndroidRuntime( 3361): java.lang.UnsatisfiedLinkError: dalvik.system.PathClassLoader[DexPathList[[zip file "/data/app/Game1.Game1-1/base.apk"],nativeLibraryDirectories=[/data/app/Game1.Game1-1/lib/x86_64, /system/fake-libs64, /data/app/Game1.Game1-1/base.apk!/lib/x86_64, /system/lib64, /vendor/lib64]]] couldn't find "libmonodroid.so"
10-10 17:59:27.936 E/AndroidRuntime( 3361): at java.lang.Runtime.loadLibrary0(Runtime.java:984)
10-10 17:59:27.936 E/AndroidRuntime( 3361): at java.lang.System.loadLibrary(System.java:1530)
10-10 17:59:27.936 E/AndroidRuntime( 3361): at mono.MonoPackageManager.LoadApplication(MonoPackageManager.java:34)
10-10 17:59:27.936 E/AndroidRuntime( 3361): at mono.MonoRuntimeProvider.attachInfo(MonoRuntimeProvider.java:42)
10-10 17:59:27.936 E/AndroidRuntime( 3361): at android.app.ActivityThread.installProvider(ActivityThread.java:5853)
10-10 17:59:27.936 E/AndroidRuntime( 3361): at android.app.ActivityThread.installContentProviders(ActivityThread.java:5445)
10-10 17:59:27.936 E/AndroidRuntime( 3361): at android.app.ActivityThread.handleBindApplication(ActivityThread.java:5384)
Ошибка: error: 10-10 17:59:27.851 W/art ( 3361): Unexpected CPU variant for X86 using defaults: x86_64
Эта ошибка означает что нам надо создать свое виртуальное устройство с x86
Читать: Создаем Android виртуальное устройство в Visual Studio ... (4 фото и полное описание).
Выбираем наше виртуальное устройство "MyAndroidEmul_Game"
Запускам приложение
Запускаем приложение: Menu → Debug → Start Without Debugging (Ctrl + F5)
Ждем сначала появится черный экран
потом загрузится эмулятор с телефоном
Приложение с MonoGame полность загрузилось
Мы видим синий экран
 
← Previous topic
Create a new MonoGame application on the computer (Windows) in emulator mode Android
 
Next topic →
Runs the old version of the MonoGame app in debug in Android emulator mode
 
Your feedback ... Comments ...
   
Your Name
Your comment (www links can only be added by a logged-in user)

  Объявления  
  Объявления  
 
MonoGame
What is MonoGame?
What is Mono (Virtual Machine for C# on Unix) ?
What are the advantages of Monogame?
How to write a game in MonoGame and compile to different platforms: Windows computer, macOS computer, Android phone, iOS apple phone, Nintendo Switch game console
Download and install MonoGame
Download and install Microsoft Visual Studio to write MonoGame games on a computer with the Windows system
Open Visual Studio (to write a game using MonoGame)
Installing MonoGame (download and install) for Windows inside Visual Studio
Create and run a MonoGame application on a computer (Windows) in Android emulator mode
Create a new MonoGame application on the computer (Windows) in emulator mode Android
Running and debugging the MonoGame app on your computer (Windows) in Android emulator mode
Runs the old version of the MonoGame app in debug in Android emulator mode
Running and debugging the MonoGame application on your phone via USB
Running the MonoGame application on an Android phone (creating an apk file)
Android (install)
Installing the Android Platform (SDK 7.1.1 API 25) in Visual Studio ...
Create a Android virtual device in Visual Studio
Installing, running the MonoGame application on a computer with the MacOSX system
Installing, running MonoGame application on a computer with the operating system iOS (MacOSX) using Xamarin Studio
Installing, running MonoGame application on a computer with the operating system iOS (MacOSX) using Visual Studio
MonoGame Functionality
How to Draw a Rectangle in the New MonoGame App
Add a png file and draw a picture in the new MonoGame application
How to draw text in the new MonoGame app
Books
Books to learn MonoGame

  Ваши вопросы присылайте по почте: info@dir.by