#📱┃mobile
1 messages · Page 3 of 1
Others using linux
All is fine i appreciate your help
With mac is different
Hope you know a way
Thanks in advance
☺️
let me try ...give some time please...
Oh yes. I m waiting. Tell me what you want for
okay
go to control panel
u will find an option "advanced variables setting"
well....srry ....find out yours configuration as yours one is a mac os
u must have environment variables option there
over there u have to create new variable for user(not for the system)
name it by "JAVA_HOME"
and paste the path u copied then save it
and restart your pc
i hope it will work this time
good luck on it
hey there, for the last months, I have seen a lot of
Thread Performance Checker: Thread running at QOS_CLASS_USER_INTERACTIVE waiting on a thread without a QoS class specified. Investigate ways to avoid priority inversions
on iOS 15 and 16 when running apps.
Is there any official info on this?
I'm making a game about guessing words.
I'trying to hide "suggestions" while typing on android.
I'm manually opening up the on screen keyboard like this;
keyboard = TouchScreenKeyboard.Open("", TouchScreenKeyboardType.NamePhonePad, false, false, false, false);
I think there is a way to do it on Java but there is no property to hide suggestions on TouchScreenKeyboard class. I tried to export project and add this to AndroidManifest.xml but it didnt work.
android:inputType="textFilter"
and i tried this one;
android:inputType="textNoSuggestions|textVisiblePassword"
Details:
*I don't wanna create custom unity ui keyboard for players
*I don't wanna hide the textbox that comes with this TouchScreenKeyboard.
I know I can create a custom java library and rewrite the whole TouchScreenKeyboard library to add this feature but is there any other way to do this inside of Unity without coding my own soft keyboard library?
hi, can help me this?
where is your app-ads.txt hosted? did you set it up?
yes
so what's your developer website url and what happens if you try to access app-ads.txt there?
https://youniverse.game/app-ads.txt this my url, and nothing happen, its said need to wait 24 hour , but i wait from yesterday and still error
assuming your youniverse.game url is in your listing, just give it some more time. I've had to wait almost 2 days before
oh really?damn
Well guys I'm back again lol. I am still trying to get leaderboards to work on my game, and its still not working. Looking at logcat its giving me this error whenever I try to pull up a leaderboard:
AndroidJavaException: java.lang.NoSuchMethodError: no static method with name='initialize' signature='(Lcom.unity3d.player.UnityPlayerActivity;)V' in class Ljava.lang.Object;
I'm just using Social.ShowLeaderboardUI() to show the leaderboard.
On top of that, whenever I try to report a score it says leaderboard not found. Any help would be appreciated!
usually this indicates a proguard problem
I have a custom proguard file. Here's the contents:
-keep class com.google.android.gms.* { }
-keep class com.google.android.gms.games.* { }```
What exactly could the problem be?
based on your snippet, it looks like the static method initialize is being stripped from com.unity3d.player.UnityPlayerActivity
is that the whole error in logcat?
2022/10/27 01:12:51.567 14559 14580 Error Unity AndroidJavaException: java.lang.NoSuchMethodError: no static method with name='initialize' signature='(Lcom.unity3d.player.UnityPlayerActivity;)V' in class Ljava.lang.Object;
2022/10/27 01:12:51.567 14559 14580 Error Unity java.lang.NoSuchMethodError: no static method with name='initialize' signature='(Lcom.unity3d.player.UnityPlayerActivity;)V' in class Ljava.lang.Object;
2022/10/27 01:12:51.567 14559 14580 Error Unity at com.unity3d.player.ReflectionHelper.getMethodID(Unknown Source:162)
2022/10/27 01:12:51.567 14559 14580 Error Unity at com.unity3d.player.UnityPlayer.nativeRender(Native Method)
2022/10/27 01:12:51.567 14559 14580 Error Unity at com.unity3d.player.UnityPlayer.access$300(Unknown Source:0)
2022/10/27 01:12:51.567 14559 14580 Error Unity at com.unity3d.player.UnityPlayer$e$1.handleMessage(Unknown Source:95)
2022/10/27 01:12:51.567 14559 14580 Error Unity at android.os.Handler.dispatchMessage(Handler.java:102)
2022/10/27 01:12:51.567 14559 14580 Error Unity at android.os.Looper.loopOnce(Looper.java:226)
2022/10/27 01:12:51.567 14559 14580 Error Unity at android.os.Looper.loop(Looper.java:313)
2022/10/27 01:12:51.567 14559 14580 Error Unity at com.unity3d.player.UnityPlayer$e.run(Unknown Source:20)
2022/10/27 01:12:51.567 14559 14580 Error Unity at UnityEngine._AndroidJNIHelper.GetMethodID (System.IntPtr jclass, System.String methodName, System.String signature, System.Boolean isStatic) [0x00000] in <00000000000000000000000000000000>:0
2022/10/27 01:12:51.567 14559 14580 Error Unity at UnityEngine.A
this is a little unreadable give me a second
AndroidJavaException: java.lang.NoSuchMethodError: no static method with name='initialize' signature='(Lcom.unity3d.player.UnityPlayerActivity;)V' in class Ljava.lang.Object;
java.lang.NoSuchMethodError: no static method with name='initialize' signature='(Lcom.unity3d.player.UnityPlayerActivity;)V' in class Ljava.lang.Object;
at com.unity3d.player.ReflectionHelper.getMethodID(Unknown Source:162)
at com.unity3d.player.UnityPlayer.nativeRender(Native Method)
at com.unity3d.player.UnityPlayer.access$300(Unknown Source:0)
at com.unity3d.player.UnityPlayer$e$1.handleMessage(Unknown Source:95)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loopOnce(Looper.java:226)
at android.os.Looper.loop(Looper.java:313)
at com.unity3d.player.UnityPlayer$e.run(Unknown Source:20)
at UnityEngine._AndroidJNIHelper.GetMethodID (System.IntPtr jclass, System.String methodName, System.String signature, System.Boolean isStatic) [0x00000] in <00000000000000000000000000000000> at UnityEngine.A
can anyone tell me what unity modules do i need to port a simple pc game to android
in the android dev module, there are a couple of extra stuff. Do i need those
well assuming you haven't already installed all of that then yeah install that
while coding for android do i have to write code in java instead of c#
How would I find out about device onscreen keyboard sizes. I've noticed there's some scripts to determine the size of the specific device, but I would like an idea of many different phone devices cause right now my phone keyboard kinda butchers a lot of my screen space and I'm trying to build around that.
no its still c#
then why do i need to download jdk for android dev in unity
Unity uses them to build the mobile app package.
hi guys, i need to embed my unity app in a native ios. It it possible to send a string while launching from native? How can i reda the message in my unity library?
Thank you so much. I‘ll try and come back to you
My mobile app have a size of 2,2GB. Its normal? I saw After I took a back up
In this matter can I change the keystores Dedicated location name in external tools?
only if you can provide all the stuffs what unity gets from that location
When you test iOS builds do you tend to/recommend testing it on your personal phone or an old phone or a used testing device? Provisioning profiles are pretty locked down as I understand it to only run that app on that version, cert and device, but just wondering if there any concerns I wouldn't think of.
Also developer mode and account settings
For most test builds, use what's easiest.
For performance optimisation use a lower end device
For feature testing use a phone with the features you need
Is there a difference in performance if :
- i create one object in Blender, import it into Unity and use it 100 times as a prefab.
- i create this mesh 100 times in Blender and combine it to one object and export it to unity.
I'm just guessing, but if they are seperate objects unity would have to keep track of all the transforms, otherwise it's only one transform. But if they are seperate you could disable the ones you currently don't need, which would probably help performance. Testing is your best bet :)
i guess i have to.. im a real noob in Profiler/FrameDebugger 😄 😄
Ok. I still looking for the enviremont variables on mac
@fallen compass hey so in testing with android logcat but not sure what to look for
i see a bunch of red lines but it dont make much sense
this seems most viable
dunno
for anyone that doesnt know
when i play the game in the editor it all works fine but when i export it to my phone it doesnt work
it tryes to start, but doesnt
says begining of crash
com.facebook.FacebookContentProvider is not found. Either you're missing that dependency or proguard has removed it. Edit proguard-user.txt and add
-keep class com.facebook.FacebookContentProvider { *; } (enable custom proguard if not already)
i removed facebook sdk all together and still the same resault
im updating now the editor
see if that fixes it
my current version is 2021.3.6f1
updating to the latest did nothing
if you removed the facebook sdk, then what is accessing the FaceBook content provider?
did you edit the android manifest?
that log is with facebook sdk
i removed sdk after that log
havent tested now
ill post all the log now
then theres this
and again something about facebook for whtever reason
do you have anything in your android manifest that references FacebookContentProvider?
ill check
probably have
since facebook is too lazy to setup an uninstall...
culd the splash thing be causing this?
normally you'd have a build post processor that would tweak the android manifest, so you wouldn't have to do anything but delete the sdk. Unless you did something wrong or edited something manually
i did edit something manually,
its something we have to aways do
becouse lazy facebook
theres a bunch of stuff
in all of them
wuld unity regenerate if i just delete them
those ones, yes
look at Assets/Plugins/Android/androidManifest.xml, I assume you have a custom main manifest
then you probably have a postprocessor modifying it still
are you sure you deleted all the facebook stuff?
you must have something, or it's a dependency of something else
i didnt see anything about facebook in dependecies
close Unity, delete $ProjectRoot/Library and build again
yes
ok
you definitely missed either Facebook itself or something that depends on Facebook and is pulling it into your project
Just a general question, mostly related to tmpro and seems most relevant on mobile, but how do I smooth out my text more depending on different aspect ratios? It just seems to be extra jaggy on some ratios which further creates problems with the outlining shader options.
I've got the anchors/pivot presets correct, and my text autosizing, so while everything else looks good, the text is what's being the problem.
What could be the reason ads are not displayed on mobile build while on editor they work ?
I have a button which calls "ShowRewarded" methode. Calling the methode does work but the ad is not loaded.
On development build i get "AdFailedLoad" (OnFailedLoad) error.
I don't work with Unity mediation (I use applovin), but usually the editor is just fake placeholder ads that are only useful in confirming you're calling methods in the right order. Check your configuration. There is nothing useful in the error message? You should also confirm that the sdk initialized without issue
Did you set up a game ID in Edit > Project Settings > Services? Your init lacks a game ID and the docs for your mediation provider say that's where it goes to find it if you don't provide one explicitly
Yeah i have set up mediation.
I have linked the unity project id and recieved game ids. Unluckily there is no error beside methode "void AdFailedLoad(object sender, LoadErrorEventArgs e)" is called.
Intialization seem to be completed successfully.
No ads are shown in dev build neather in google play internal test build.
I have added a test device aswell on dashboard.unity3d with my play store advertising id
android or ios? Any errors in logcat or xcode?
android, no error log from logcat (root)
set a breakpoint on your ad load failed method and inspect the args, hopefully there's more info in there
"Autoconnected Player "Autoconnected Player" Ad failed loadedException raised while retrieving the Ad Unit Configuration: com.unity3d.mediation.j0: Failed to fetch Ad Unit due to connectivity issues: Request to https://mediation-instantiation.unityads.unity3d.com/v1/waterfall failed due to java.io.IOException: Instantiation Service configuration request failed with http status code 404 and server response: ad unit configuration not found for game id: XXXX, ad unitid: XXXX"
well there you go, looks like something is wrong with your waterfall configuration
everything was on default
I assume the game id and ad unit id from your error match your configuration, right?
and you're requesting with an ad unit id of "Rewarded_Android" and not the waterfall name?
oh god, the example code from unity which i was using was outdated (package example). Now i adjusted it and it started working finally. Thanks.
Whenever I try to submit my game to the ios app store they keep saying they can't get the iap working. and that they get this error "purchasingUnavailable" any idea how to solve this?
Is there anything more for the error?
Did you test the iap someway?
Hello guys!
I am developing an Android app, and I am using certain Android APIs that must run on the UIThread.
So I created a plugin and inserted it to the Unity, I invoke methods on the UIThread by calling something like _activity.Call("runOnUiThread", new AndroidJavaRunnable(func));
My question: is the thread that makes this _activity.Call("runOnUiThread", new AndroidJavaRunnable(func)); a main thread?
When I make such a call, is the func executed on the thread it was called, or is it executed on the other thread?
I have a question friends, After I try to build an apk for google play store several erros comes up with the information that my code runs dublicate billing adress. So, If I delete the one duplicate plugin in one of my several back ups does it delete in every back up ?
I have a question friends, After I try to build an apk for google play store several erros comes up with the information that my code runs dublicate billing adress. So, If I delete the one duplicate plugin in one of my several back ups does it delete in every back up ?
According to Unity Answers - It is caused by Google Billing. If you don't need it, you can remove it. go to Assets/GooglePlayPlugins and delete com.google.play.billing. I suspect you have Unity's IAP installed, and it looks like if oyu install both it breaks.
Hard to say with certainty though, I don't use or recommend Unity's ad or inapp services.
hey guys
using Facebook.Unity;
using UnityEngine.EventSystems;
public class StartFacebook : MonoBehaviour
{
private void Awake()
{
if (!FB.IsInitialized)
{
FB.Init(() =>
{
if (FB.IsInitialized)
FB.ActivateApp();
else
Debug.LogError("Couldn't initialize");
},
isGameShown =>
{
if (!isGameShown)
Time.timeScale = 0;
else
Time.timeScale = 1;
});
}
else
{
FB.ActivateApp();
}
}
private void Start()
{
EventSystem[] evs = FindObjectsOfType<EventSystem>();
if (evs.Length > 1)
{
int i = evs.Length;
while (i > 1)
{
Destroy(evs[1].gameObject);
i--;
}
}
}
}
i have this script that i run on my mobile projects
do i need it to see installs on facebook?
does it matter?
im only concerned for installs currently
Thank you so much. But there is written twice - duplicate class. It means there two of them right? So I want IAP for disabled google ads.
How are games like Call of Duty run on mobile? As in, how are they optimized? I'm having difficulties getting 60FPS with very low draw calls and vertices. Yet I see these super high quality games on mobile.
using a single material
cheap shaders
put everything on an atlas
also set your game to 60fps
for some reason by default they run at 30
Ok. Shall I delete IAP Unity and just usw Google? So if I do so will be Problem solved?
I luckily know about the 30FPS standard thing, and have set my game to 60, but I struggle mostly with the other stuff.
Cheap shaders? Like Unitys Mobile Shaders?
I use very little materials in my game, I have a 16x16 color palette which almost every model uses in my scenes. GPU instancing enabled as well.
What is that Atlas thing?
Oh I looked it up! So essentially I put many different textures into one thats a little higher in resolution, so there could be possibly only one material as you said.
Help
Anyone here ever used unity recorder asset before?
Am trying to record a clip via the Unity recorder asset but when i try to record, it throws an error saying something about videoEcoder unsupported
Unity needs to do a batch call for every material, and every non static mesh, by default.
So a texture atlas lets you combine many materials into a single material - so you can render the display in a single batch call... It is extremely important on XR and mobile. It essentially sacrificed ram for less GPU and CPU use.
Remove all unused faces.. static objects. Light baking.
?
My app have after duplicate a size of 2,29gb
Oh ok! What about dynamic objects? For instance, a multiplayer shooter, where player models are dynamic?
Hey guys, what's the best way to make touch controls on screen? I want to make two buttons on the left of the screen (left-right) and two on the right (jump-dash)
Is this tutorial any good?https://www.youtube.com/watch?v=NqrJHj9xlqY
In this short tutorial we will explore how to fast and easily handle touch input in your mobile game. I am currently working on a mobile game and I couldn't believe Unity made it so easy for use. Mobile controls can be added literally within minutes! I hope you enjoy the tutorial :). Love you!
00:00 What and how?
00:35 Setup
01:10 Mobile Stick...
Hi, does anyone know how to sign an .aab?
I have tried to follow the steps that Google Play gives downloading pepk-src.jar but it does not say "there is no main manifest in pepk-src.jar"
Hi, I'm actually trying to build an apk but unity is throwing the above error. I reinstalled and tried different SDK and NDK but still it is not working. IS there anyone know the fix.
Do you have gradle installed? Also, Lower your target API level or set it to use highest installed 🤔.
Btw click on the first error for more details
yeah i tried to target api level but still not working
Okay, can you click on the third error too for more details?
Try this 👆
Does anybody have experience removing frameworks from their XCode project using PostProcessBuild?
stilll not working
Oops, still throwing the same errors?
yes
Are you using keystore ?
If you're, disable it rebuild and see if it might work.
How can I make the hitbox of a touch control button bigger without making the sprite bugger?
edit the collider for it directly
@quartz lava i had similar issues but i solved it
Here's the things to know so you'll never have issues with building to android :
-
If you have a SDK in your project(Facebook, game analytics, ad, firebase e.t.c)...always force resolve
-
Before building, make sure you have steady internet connection... Trust me... This is needed to get Android SDKs
-
Select your minimum SDK to be 6.0 (5.1 below is long gone since phones don't support them anymore)
-
Build while internet connection is on.... And if you have errors building, look at the console, if you don't know how to read console error... It's easy
Follow these steps and you'll never have build issues anymore... It works for me and has been working for me... Now i don't even stress when building to android
Hi guys, I Just get into mobile game development using unity and faced a small issue related to the performance and entity speed using Vector3.MoveTowards. In Play Mode it is much faster then in build. I did a little research and people said I should use Time.deltaTime * Speed instead of a fixed float. Anyways - That won't solve the issue. It makes both speeds a little slower but the difference from mobile build to unitys play mode is still about times 30.
Edit: It was related to the CanvasScaler - The speed was fine but the target had to travel a longer distance due to the scaling..
Hello I making an app and I wonder how can I make a button when pressed you download pdf file with all the thinks you want to learn
Can someone help?
Hello! We are struggling with Android 12, because our Unity app gets a black screen after Splash Screen on Android 12 devices. Do you how to solve this? Thanks in advance
Which one should I add the option to have ads to support me on my game? ☑️ = yes ❌ = no
I think we've reached a point where you are better off with help from someone else or finding the answers on your own.
I have a question friends, After I try to build an apk for google play store several erros comes up with the information that my code runs dublicate billing adress. So, If I delete the one duplicate plugin in one of my several back ups does it delete in every back up ?
Hello, i have a problem with touch input. I want to ,,touchInput.GetAxis,, only when the user is touching the green space, And I dont wnat it to get the inputt when touching some UI elements.
Hello. How do you deal with these things on mobile screens? Is there maybe a way to check for it in code? Or do you just ignore it (lol)?
Try using Screen.safeArea: https://docs.unity3d.com/ScriptReference/Screen-safeArea.html
ok thanks
How do I track when the screen is swiped so basically Input.GetKey(Keycode.W) except touch
found solution?
using UnityEngine;
using UnityEngine.InputSystem;
using UnityEngine.EventSystems;
public class MouseLook : MonoBehaviour
{
public float mouseSensitivity = 100f;
public Transform playerBody;
float xRotation;
void Update()
{
float mouseX = 0;
float mouseY = 0;
/*
if(Mouse.current != null)
{
mouseX = Mouse.current.delta.ReadValue().x;
mouseY = Mouse.current.delta.ReadValue().y;
}
if (Gamepad.current != null)
{
mouseX = Gamepad.current.rightStick.ReadValue().x;
mouseY = Gamepad.current.rightStick.ReadValue().y;
}
//float mouseX = Input.GetAxis("Mouse X");
//float mouseY = Input.GetAxis("Mouse Y");
*/
if (Touchscreen.current.touches.Count == 0)
return;
if (EventSystem.current.IsPointerOverGameObject(Touchscreen.current.touches[0].touchId.ReadValue()))
{
if (Touchscreen.current.touches.Count > 1 &&
Touchscreen.current.touches[1].isInProgress)
{
if (EventSystem.current.IsPointerOverGameObject(Touchscreen.current.touches[1].touchId.ReadValue()))
return;
Vector2 touchDeltaPosition = Touchscreen.current.touches[1].delta.ReadValue();
mouseX = touchDeltaPosition.x;
mouseY = touchDeltaPosition.y;
}
}
else
{
if (Touchscreen.current.touches.Count > 0 &&
Touchscreen.current.touches[0].isInProgress)
{
if (EventSystem.current.IsPointerOverGameObject(Touchscreen.current.touches[0].touchId.ReadValue()))
return;
Vector2 touchDeltaPosition = Touchscreen.current.touches[0].delta.ReadValue();
mouseX = touchDeltaPosition.x;
mouseY = touchDeltaPosition.y;
}
}
mouseX *= mouseSensitivity;
mouseY *= mouseSensitivity;
xRotation -= mouseY * Time.deltaTime;
xRotation = Mathf.Clamp(xRotation, -80, 80);
transform.localRotation = Quaternion.Euler(xRotation, 0, 0);
playerBody.Rotate(Vector3.up * mouseX * Time.deltaTime);
}
}
this might help
Source: YouTube/GDTitans/FPSMobileInputControls
Thanks dude
I'm super late and sorry for not thanking you. This was super helpful thanks a ton!
How to format an android manifest?
where to put the "uses permission" tag in the manifest?
Anyone have any thoughts on the best multiplayer platform for a Unity mobile game?
Unsure of the relative merits of Gamesparks / Playfab / Photon etc
I have a game on Android and originally set the Target API Level to 31 since Google was getting me a warning and Minimum API Level to 22 (Android 5.1). I'm getting people telling me that they are not able to run the game on Android 11. The phone I'm testing on is Android 13 so it's hard to see what the issue is. Shouldn't the game work on all OS down to Android 5.1?
Also running Unity 2021.3.13f1 LTS if that impacts anything
is there a good tutorial on how to build to iOS when im on windows
what i found is using mac in virtual box with some other apps just wanted to ask if theres an easier way
There's a cost here of $7/mo but I use Unity Cloud build to build to iOS when I'm on Windows. Unity Cloud Build will build the app and I just download it on my phone.
Can also use cloud build to send it straight to the app store/testflight
thanks
So ran my app through browserstack to see if it runs in Android 10/11/12 etc, and the app does run. But I have a report from someone who said they're running Android 11 on a specific phone and can't install the game. Are there phone compatibilities?
Is it an architecture issue since I'm only building for ARM64?
Seems like the device in question is running Android 11 on ARMv8-a
We mostly used PlayFab/Photon (games). Or an internal framework (client experiences)
I'm using in app purchasing but neither of OnInitializeFailed or OnInitialized is called when testing on Android
ideas?
did you check logcat output? Usually you'll find that some class or method is missing because proguard removed it
yes but logcat shows nothing
I was using Codeless IAP before, logcat only printed "Is Not Initialized" so I changed to code
by the way I never know how to see Debug.Log("") messages in logcat
so instead I used a actual UI text to debug
like in the above code
that's a bad plan that will lead you to misery later, the least problem of which is that if your code throws an exception you won't see any output unless you catch exceptions in every possible place
where is the code that calls these two methods?
these two are just directly inherited from the IStoreListener
namespace UnityEngine.Purchasing
{
/// <summary>
/// Implemented by Application developers using Unity Purchasing.
/// </summary>
public interface IStoreListener
{
/// <summary>
/// Purchasing failed to initialise for a non recoverable reason.
/// </summary>
/// <param name="error"> The failure reason. </param>
void OnInitializeFailed(InitializationFailureReason error);
/// <summary>
/// A purchase succeeded.
/// </summary>
/// <param name="purchaseEvent"> The <c>PurchaseEventArgs</c> for the purchase event. </param>
/// <returns> The result of the successful purchase </returns>
PurchaseProcessingResult ProcessPurchase(PurchaseEventArgs purchaseEvent);
/// <summary>
/// A purchase failed with specified reason.
/// </summary>
/// <param name="product"> The product that was attempted to be purchased. </param>
/// <param name="failureReason"> The failure reason. </param>
void OnPurchaseFailed(Product product, PurchaseFailureReason failureReason);
/// <summary>
/// Purchasing initialized successfully.
///
/// The <c>IStoreController</c> and <c>IExtensionProvider</c> are
/// available for accessing purchasing functionality.
/// </summary>
/// <param name="controller"> The <c>IStoreController</c> created during initialization. </param>
/// <param name="extensions"> The <c>IExtensionProvider</c> created during initialization. </param>
void OnInitialized(IStoreController controller, IExtensionProvider extensions);
}
}
so they should be called internally
at least they are in the Editor
but not on Android and I don't know why
yes, and you initialize with what? What implements IStoreListener?
did you initialize UGS first?
Unity Gaming Services. The docs for setting up Unity IAP say this: "If you attempt to use the Unity IAP service without first initializing Unity Gaming Services, you will receive the following warning message:" so my assumption is you are getting a warning in the logs that you ignore because you're debugging using UI text
a lot of these APIs don't function in the editor or are stubbed out, so you wouldn't know anything is wrong necessarily until you tried it on an actual device
I'm unfamiliar with Unity IAP so I don't know if this is the case, but it's common for ad networks
every single tutorial out there didn't mention this and I know some friends all set it up this way but it works on their sides
now the question is how do I check the logs in logcat
does Debug.Log() gets included?
yes, filter by Unity tag
of course I tried that, but no Unity stuff at all
so they must just got all stripped?
Just wondering if anyone can help me with this — I'm really stuck! How can I use a pre-built .so lib file in my android project? I want to use classes derived from monobehaviour that are inside the .so file and attach them to gameobjects. I have been looking at dllimport and dllexport but I'm not sure if those are applicable in my case. Also, I do not have access to the source code. Thanks in advance!
there aren't going to be any classes derived from MonoBehavior in the so. Have a look at https://docs.unity3d.com/Manual/NativePlugins.html
Thank you! So using this method, can I create a monobehaviour script using only the functions/methods from the .so file?
yes, if you know what they are and they're accessible
Does anyone know how to fix this error I have tried a lot? but couldn't get it working
did you create a placement called Interstitial_Android for your game (and assuming 5010385 is your game id)?
wrong pic
wait nvm put could You see the error selected?
yes ... that's the Unity side. Did you do the configuration part in your dashboard?
hmmm looks okay to me. Make sure there aren't any dumb errors (spacing in names). It might also take a little while before your ad units become active. How long ago did you set this up?
What do you mean by accessible?
are they exported functions? Are you able to marshal data to them that matches their argument types? Is it designed to be interacted with from Unity? There might be some other hurdles for you
this is plenty of time. Did you create placements for your ad units?
what do you mean by placement
I don't use unity ads directly, but normally there is more configuration than just creating ad units. Did you do any setup for your waterfall?
I mean this is what my waterfall looks like
hmmm our dashboards are different, mine literally calls it "placements". If you go to the setup guide, does it say anything in there?
would I go under API management
no, Project Overview -> Setup Guide -> and then on mine there are 4 steps, step 3 is configure ad units and step 4 is setup placements
otherwise your setup looks correct to me, and I would just verify that it's also not working on a physical device since the sdk isn't really running in the editor
if I just use Unity ads do I have to mess with placement ID
no other meditation stuff
maybe somebody more experienced than I can chime on on that, I haven't had to mess with the configuration for ages. There is usually a test game id and test ad unit you can use, do those work?
again, if anyone has any ideas, please let me know
( Update: it was because I didn't add
implementation(name: 'common', ext:'aar')
in my gradle file)
This doesn't look like your IDE is setup correctly - inconsistent colouring.
Are you actually calling the initialization of purchasing?
nm , you edited your msg while I was scrolled up
Hey guys I have a been making an android game and when I try to build the game and it's almost done the build fails and drops me this error:
*In english Win32Exception Native error= The system cannot find the file specified
I am stuck at this can you pls help?
Hi is there some recommended number of polygons for character in mobile game
No, this depends on what devices are targeted, how much performance the other aspects of the game take up, how many bones can deform 1 vertex, and much more.
Is there anything that can help me with this?
Profiling tools
As it says, see the console for details
And thats where things get complicated
It give a path to jdk something but nothing else
Does 2021 Terrain still lags in Mobile?
I mean....is terrain now usable in mobile Devices?
anyone know how to fix this? "fix object name" button isnt doing anything at all
Hey guys I have been making an android game and when try to build it this error pops up
The system cannot find the specified file unity
See?
Can you pls help? I have been stuck at this for weeks
How to fix "Gradle build failed. See the console for details."? This is what i got in console:
might be a normal error. Are you running test ads? You won't always have an ad to show if no ad networks are willing to supply you with one
probably something is wrong with your android sdk or ndk. Try re-installing via Unity hub or updating Unity version. I remember some version of the sdk being broken because they moved a folder, but I don't remember which
you need to look at the details; click on the errors
i checked
i dont really understand what they want to mean
that sounds like a good reason to google/post them though, right? Lots of things can go wrong in an android build. It's almost impossible to help people when they won't post what the actual error(s) are
What's the confusion with your error? looks like you just need to enable useAndroidX. Build settings -> publishing -> use custom gradle properties template. Add line android.useAndroidX=true and line android.enableJetifier=true to it if they don't exist and rebuild
now i am getting this
do you have any missing dependencies?
how to check if i have?
Did you install any dependencies yourself? Are you using the external dependency manager? If you are, did you resolve with it?
I dont know what dependencies are in unity
you didn't install anything third-party?
some packages
Are they counted as dependencies?
uh, if they're needed to build your project and make it work then yes?
they're: photon, joystick, probuilder, progrids
I haven't encountered your specific problem before but some google results are promising
I tried some. And i still can't find one that will fix my problem.
you read through this right? https://docs.gradle.org/current/userguide/dependency_locking.html#disabling_dependency_locking
nah
Wait. That started to happen after i downloaded unityads package
It started to work when i removed unity ads
So there still a problem. I cant build with unity ads package installed.
Where is it written in packages which dependecies are work in my prokect?
package manager, external dependency manager, anything you manually installed to Plugins/Android or any subdir that matching that scheme, any scripts that do postprocessing on your project (BuildPostProcessor, IPostGenerateGradleAndroidProject) could add or edit them, any dependencies that are themselves dependencies of your dependencies and are resolved when you build the project
I assume you're trying to debug your duplicate class issue, so I'd be exporting the project and looking at what's in your build.gradle script for unityLibrary
Hi, im trying to connect unity to my phone with the app Unity remote 5, but my phone is not detected here in device settings, i don't why 😭 can someone help me please :d
did you enable developer mode on the device, allow debugging, and checked if it's detected by adb?
oh I didn't check that ^^ i'm downloading adb and i'll see thanks
you already have it in your android sdk under platform tools
i don't need nothing on my pc?
Anyone got experience with Kindred SDK for monetization ? The idea sounds pretty good, but how does it work out in reality
assuming you added the android support module so you can build to android devices, correct
my pc doesn't have android sdk also, i'll see if it will work with adb
seems like they're trying to get users to install a keyboard extension for their device browser. Which part of the idea sounds good? I'm curious
leaning more to commision / affiliate
affiliate can be pretty profitable, but usually not something that is put in an app
if i understand it right
was just interested if someone actually tried it
but calculation on their site wasnt super profitable
its still not working;( I did all the things to do on my phone but nope 😦
Had the same issue today and sometimes have, im on mac tho.
But what i did is use another android sdk, the one i had from android studio, and also make sure to use usb-debugging.
Also, do you get access to the phone outside of unity? If not, that maybe your usb is a charger only?
Google and see some stackoverflow threads too
I assume the sdks found in android studio is downloadable from their android google website too
i am on wibdows so idk why its not working
When i used pc i had littke problem
i can still transfer program to my phone with my USB cable so i don't think that's the issue
ye
You restarted unity?
Try restarting it and let the cable still be connected
I only build my games to the phone but the device not showing up is the same problem i had
You have android studio?
when i connect my phone to my pc its written that i'm connected, but its not written that USB debugging is on
but i did it
But your developer settings is on with usb debugging?
ya
Okay id say try see if your device shows up in android studio
If it does, use the sdk in unity path
i never used android studio atm, idk how to do^^
Create a "empty" project and call it android or smthng, then u go to tools and sdk manager
From there you can find out sdk etc
hmm ok i'll try it, just need to download some things
okay thanks
Np hope u work it out
That worked for me but it can be a bit messy and not knowing what is wrpng sometimes
Sdk tools
U see that window
Take the google usb driver too
Then since u have the sdk etc, probably got it now that you downloaded android s
Studio
Try also as said install google usb driver in the list
Then once u done go to unity, and pref, and insted of android sdk with unity u reference that sdk
For me i got a note saying i had another path to a sdk and i pressed that to use it
Sooo.. for me i unchecked sdk with unity and put the path to this one
do I need to download sdk android?
U got it
I said installen on the sdk tools list
Installed*
Jump in to unity and preferences and at the unity android sdk (or something alike) u now give the other (newest) sdk u got from android studio
Got it?
im here, but i don't understand how to transfer new sdk, well how to take it
done
If it asks id you want to use the other one and locates it good
Else search google for android studio android sdk path
i copied my sdk path in it
so normally it's fine
it changed nothing unfortunately, i think the problem come from my phone, because USB debugging message should be here, and it's not
Show me a scrn shot of the sdk path
To make sure
And hmm
Also on phone, try to revoke the debugging
And allow it once again when putting in your cable
that the one i took here
yup
that is so frustrating
idk what to do then'.', I watched different tuto but none worked
but i've done what they did xD
Yeah very annoying
Basic, but you restarted the computer?
Sometimes it just popped for me
Like taking out the usb cable and put it back in
Hey there! I am having errors when trying to build for android release build. They seem to be coming from Java JDK and Gradle. Does anyone know what is going on?
Try this, saw it on unity forum, @hushed harbor I resolve the problem. In USB connection mode, on my phone, there are 4 options:
Transfer files
transfer images
Connect a MIDI device
Charge this phone.
I ONLY changed the connection mode to TRANSFER IMAGES. After that, I reveived a prompt asking me to viladate this connection mode. I did it and it works fine.
i also tried it, but still not working;(
thanks for your help but idk why I'm cursed xD
any chance you're using some ad mediator? This looks exactly like something I encountered and had to make a hacky workaround for
This comes from installing a Game Analytics SDK from a publisher im working for. But i wont find them till Monday and i kinda want to workaround this
does their sdk assume admob is installed? That's what the problem I encountered was
I dont think so .. I mean i ve published for them before and it is always error after error lol
specifically I had the fyber ad network installed which referenced admob, so I had to install + disable admob
are you sure it's the game analytics sdk? the fyber sdk was installed in my case due to having fyber as one of the ad networks used in our mediation layer
assuming that's it, you could either try my workaround or downgrade to a previous version of fyber that doesn't cause the problem. It's kind of old-'ish (a year+?) though
So you propose to download AdMob and then disable it?
How would i disable it?
I dont even know what fyber is honestly
include it as a dependency, then edit your android manifest to:
- remove its InitProvider: com.google.android.gms.ads.MobileAdsInitProvider (it will crash app on launch without a valid application id)
- remove Service: com.google.android.gms.ads.AdService
- remove meta-data (optional): com.google.android.gms.ads.APPLICATION_ID
alternatively, the last fyber version I used that didn't cause a problem was 7.8.4 iirc
how can i change to that version?
when you say include it as a dependency on the step above i dont know what you mean 🙂
sorry for that i m really new to this
how is it getting added to your project?
something is causing it to be included in your build. If you're using external dependency manager, you might have dependencies in XML that reference it directly or indirectly
All those things got added when i imported the publishers SDK
So it is not something i did
Their SDK comes as a unity package
I assume they have an example app, does that one build? I'd bet it doesn't
Ahh .. i dont want to screw in this channel .. but they dont have s@@@
All they have is a package to install and it always causes different type of errors lol
I ll probably have to wait for Monday to contact them
do you just need it to build or are you making something for production? The easiest solution would be to test it with dev builds (no proguard) and then complain on Monday
I m making a build for Google Play
The game builds fine without it
Let me do a quick development build to see if i m actually correct
you'll bypass that error above if you do a dev build, you're getting it from a proguard validation step
yeah it is exactly as you mentioned
The build succeeds as dev build
Well i guess i have a day off tomorrow lol
Anyone knows the solution for text (legacy) and textmeshpro not showing in some android devices? I have tried a bunch of things from Unity forums but nothing seems to be working
Everything else in the UI is showing properly, just the text is missing
I've tried changing the canvas from overlay to world space, creating legacy instead of textmeshpro and a bunch of stuff
graphic raycaster is not working on android ,it works fine on my pc but on android doesn't work it doesn't work
This errors comes up after trying to build an apk on Imac for google store. It didnt work. Who have an idea?
the error's pretty clear. Find out what's adding an extra copy of google play billing and fix or remove it
This server isn't for recruiting. Read #📖┃code-of-conduct
Sorry
Sounds easy so where I‘ll find it?
I have an issue where my movement buttons for Android work in Remote and in editor, but in build they dont execute the assigned scripts.
I originally developed The game on pc and am trying to make it work on my phone.
Buttons have a separate script where left and right buttons change the move float to 1 and -1 in the original movement script.
Jump key has a script assigned which just executes the jump from the other movement script.
In build these buttons can be pressed but they dont do anything.
Can anyone help?
When I was testing the buttons in Unity Remote 5, they worked without issues, but now they wont work on phone.
Editor playtesting works but that's useless if I can't play game on phone..
You'll need to Debug it on the phone itself. You can use the built in Android logger in Unity (package manager) to pull the logs and see what is different. There isnt enough info here to help you, as we don't know how you added movement etc etc.
Movement on my character is through changing the rb velocity with the horizontal move float * movespeed. All movement is on Script A and work perfectly.
Mobile movement is through script B which is referencing script A and changing the move float to -1 on left and 1 on right. On pointer up, move sets to 0
I set up script B with referencing so that I wouldnt need to go through all levels to set player reference to the controls.
Basically Script B changes the move float which then causes movement in Script A's part.
Jump is just executing the Jump(); command from Script A in Script B
When uploading an app to the appstore, is there a way to hide your personal name from appearing on the app store as the publisher?
hard to tell without seeing your project. What third party dependencies do you have? Do you have a GooglePlayBilling that you put in your project somewhere? How do you resolve your dependencies? We can only guess from here
That's managed by the appstore - not by Unity. I'm assuming you are looking at apple, and the short answer is not really for individual accounts, no
Hello I am making a game and I was wondering if anyone can play test it to give me recommendations bug reports etc I can send a pc Mac android or iPhone build
Anyone knows how to get the new unity runner template?
I can't find where to download it and it's not in my latest unity hub
Found the solution - In my mobile script I was referencing the original movement script with "GameObject.FindObjectWithTag". Apparently that doesn't work on build so i changed it to "GameObject.FindObjectOfType" and that worked.
Hey so basically the issue was solved by deleting a fyber dependency xml that was installed with the SDK. It was unnecessary and their fix was telling me to delete that lol
Thnx for the help the other day you were really close to that
I just didnt know how to implement the fix
Hello everyone, we have a very weird bug with the app and it started after migration to plastic scm. We build the game for android with no errors in console but when we install the game it crash before it even opens. Since we didnt have any log or errors i launched the apk thru Android Studio and used Logcat to see what is going on and this is what i get upon launching the app.
If anyone has any idea please share.
Apk works fine when i build it in the project that is on github, so my best guess is that some android dependecies messed up upon migrating the project to plastic.
Hi so I am not sure id I should ask this here or not, but I am trying to bypass my ssl pinning certificate on my android build to check my network traffic using mitmproxy for debugging. I couldn't find a reliable way to do this could someone point me in the right direction?
I appreciate it. Here are my depencies:
make a dev build, if it builds and runs you're probably looking at a proguard issue. I assume you have already re-resolved any dependencies in case that's the problem
Hey so i got an issue with my Release build again. While the development build runs fine on my mobile when i test the game, when i make a Release build it always crashes on startup before even displaying the Unity logo. Just a black screen and the app doesnt close but minimizes from the screen. Trying to reopen it when minimized doesnt work either as it just minimizes again. Do you know anything about what might be the cause of it?
Do you have any output from logcat?
I dont know where to find that. Gimme a second to find that online and see
check external dependency manager's resolved libraries, too. I see you have play billing in there, so something is pulling in an extra copy. Look through your third party dependencies and try to find it. It might be there directly, or referenced through a dependency xml file that EDM is using, or implicitly referenced by something else
I got an app Logcat Extreme on my phone. The error that seems to show up when i try to play the game is "not starting debugger since process cannot load the jdwp agent" this seems to repeat when i try to open the game.
There is also a popup that says "(Game name) is stopping"
Why an app? you already have adb installed. I like to export to android studio and run a release build from there, it mostly does the right thing for you as far as filtering log messages goes
Ok i will try that i havent used that yet
if you look at Admir's output, you can see all the angry red that tells you exactly why the app isn't working. You're blind until you find out what's gone wrong in initialization
Ok thnx for opening my eyes here 🙂 I m really new to this all
atm you have 2 possibilities:
- proguard ripped something out that it shouldn't have (you'll see text like his)
- you have an ANR issue during startup on release builds, where you or one of your dependencies is stalling the main thread for so long that the OS decides your app is frozen and kills it
Ok new information i think it is proguard
I had this enabled
After disabling it the app runs fine on my phone
But is Google Play going to accept it that way?
okay, re-enable it, then look at logcat output for missing classes
yes, but it's just a matter of finding out what's missing and excluding those class(es) from being removed. We're talking a handful of text in proguard-user.txt now to fix it
you just need to find out what's gone missing
I am guessing the fyber file that the publisher dev team told me to delete to workaround the error i had yesterday lol
i just installed Android Studio let me figure this out
@tired lily Should i worry about that?
Can i install it in a different location instead?
you should use the sdk and ndk that Unity is using to build your app
This is asked during Android Studio installation
Should i copy the path form Unity --> External tools and put it there then?
if it's installing the sdk for you, fix it like it mentions. When you open your exported project Unity should have configured the right sdk for you. It's been a while since I installed android studio
I think i can just probably choose another location
@tired lily I went to Google Play to upload the new version of the app, as i had already uploaded the old one that wasn't working. Don't ask why i didn't check that, it is kind of embarrassing honestly. The old one was "In Review" status so no one saw that lol.
Now you think this will be fine and they ll upload the new version when that review passes?
I feel i m good, but i m not sure
I ll also try to read a bit about android studio tomorrow and try to find what caused the error then because it is almost 1am here and i think my main goal is completed
well it's your call, they're not going to reject it because you didn't obfuscate your code
ok nice i m glad this went well
@tired lily Thank you for your support during that stressful time ❤️
If I'm developing a VR game and testing it on my Meta Quest Pro, is there any way I can connect the editor to that for live debugging? If I want to see what certain properties are set to or make a change to test something, I don't want to have to rebuild the app.
Yep, using oculus link/airlink or virtual desktop
Quest Link is only available on windows
The only option you have for testing in editor is faking input like with the XR device simulator
BTW there is a dedicated #🥽┃virtual-reality channel
I saw that, but I figured the question I had was more specific to Android than VR.
hi all
im new here
im developing a mobile game where swiping is the movement.
i.e
hold -> swipe upwards or downwards -> release -> then player character 'jump's from one place to another.
i been trying various things with the rigidbody and the input system but in execution it looks odd. the player will sometimes gain so much speed that it goes through collision walls
do you have any other suggestions on how to implement this kind of movement controls?
Dev build also crashes before it even loads. I re-solved dependices, deleted library, apk still crashes on startup. We didnt import any new assets after migration, so the project should be the same, but still it works on git when we build but not when we build now on plastic.
In case anyone saw anything simillar here is the error from logcat, when i hook the apk to android studio
java.lang.RuntimeException: Unable to get provider androidx.startup.InitializationProvider: androidx.startup.StartupException: java.lang.NoClassDefFoundError: Failed resolution of: Lkotlin/collections/CollectionsKt
We even tried to download latest unity version. still the same, app crashes before it even loads.
I appreciate it. Where can i find the third parties?
you need to reauthorize debugging on your device (it should pop open a window)
presumably you installed them, so you'll find them under Assets or in packages
Thanks
Thank you. Do you know how it calls? And should I deinstalled?
Hey. Wrote up this code to get GPS user position data (in intervals when a button is pressed and on app start). It work's on my phone, but not on the Android 10 device that I'm actually building the app for. It seems to have a problem with getting location permissions from Android 10. What do I change? https://paste.ofcode.org/xadCBFPRQFrG5HRJ8iSVY4
The error:11-16 11:26:57.579 3966 3990 I Unity : Location service updates are not enabled. Check LocationService.status before querying last location. 11-16 11:26:57.579 3966 3990 I Unity : UnityEngine.LocationService:get_lastData() 11-16 11:26:57.579 3966 3990 I Unity : LocationService:LocationRefresh() 11-16 11:26:57.579 3966 3990 I Unity : 11-16 11:26:57.579 3966 3990 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 39) 11-16 11:26:57.579 3966 3990 I Unity : 11-16 11:26:57.581 3966 3990 I chatty : uid=10147(com.Microsoft.Maps.SampleProject) UnityMain identical 5 lines 11-16 11:26:57.581 3966 3990 I Unity : Location service updates are not enabled. Check LocationService.status before querying last location. 11-16 11:26:57.581 3966 3990 I Unity : UnityEngine.LocationService:get_lastData() 11-16 11:26:57.581 3966 3990 I Unity : LocationService:LocationRefresh() 11-16 11:26:57.581 3966 3990 I Unity : 11-16 11:26:57.581 3966 3990 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 39) 11-16 11:26:57.581 3966 3990 I Unity : 11-16 11:26:57.582 3966 3990 I Unity : KB: fetching GPS data... 11-16 11:26:57.582 3966 3990 I Unity : LocationService:LocationRefresh() 11-16 11:26:57.582 3966 3990 I Unity : 11-16 11:26:57.582 3966 3990 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 39)
It used to work on a different build when I started the refresh interval from the beginning instead of having it start/stop depending on the button status.
For one in Start you call RefreshLocation without waiting for the user to grant location permissions
and in the coroutine you wait for 10 seconds for the permissions and then continue regardless of whether the user gave permissions or not
Okay, I changed the script, still works on my phone, testing it on the Android 10 device this evening when I get the chance to do it. Thanks!
Hey guys,
Does anyone have any idea of how to deliver and use play store asset bundles when developing Unity as a Library app?
(i.e unity is embedded into another android app)
help I've been prepared my JDK but Unity refuses to route to according path
Leave it as is if you aren't using Unity's own. Otherwise tick that check box above.
Hey man, were you able to get the runner template?
I'm also facing similar problem.
hey are here any german devs who can help me with a law thing? 😄 sind hier deutsche die mir bei was rechtlichem helfen können?
Not really... I still can't find it in unity hub
Thank you. Do you know how it calls? And should I deinstalled?
how what calls? It's up to you to find whatever is breaking your project. Uninstalling stuff until you find out what it is would work, sure
is it possible for me to use unity on my phone?
I know stupid question but might as well ask
Hello!
I downloaded a sample android native plugin from unity docs.
https://docs.unity3d.com/Manual/android-native-plugins-call.html
My plan was to see how I can use .so files in my project. When I import the package, load the scene and hit play, I get an error dllnotfoundexception.
I've tried so many things and nothing works! I would really appreciate any help or suggestions! Thank you!
you can't call native android functions unless you're running on android
@onyx raft There's no crossposting allowed in this discord.
unity mediation isnt loading any editor test ads for me, and neither giving a message. I am able to initialize mediation services but loadAd call doesn't load any editor test ad, in debug logs show that this code isn't being called at all
I'm using unity mediation btw, and I have some questions about that. Will unity mediation continue to function the way it is and allow bidding, or will most ads be served on the ironSource LivePlay mediation?
The reason I am asking is because I learned how to set up unity mediation and I am comfortable using that long term, switching to LivePlay means to spending a week (usually frustrating. This is due to custom in game mechanics.) to set up the process again.
Stupid question... Does this mean I can't play the scene/run the script in editor then? I need to use an emulator e.g. Android studio
yes, you'll need an emulator or run on a physical device if you want to test the actual calls. Normally they're just stubbed out or approximate native behavior with some other logic in the editor
Thank you! I don't have an armv7 device so will set up an emulator then
do you need to own an iphone if you want to release a game on ios ?
No, you need a mac though.
Would be odd to release without being able to test your own game though.
i know but macs and iphones aint cheap
K sorry
Hey guys I just release my first app on the Android Store, but the login with Google Game Service and relative achievements doesn't work when downloading the app.
Instead they works while building directly the same app bundle on my phone. Any idea of why this is happening?
Just getting really confused about it.
disclaimer: I don't use google game service, but you might be missing the sha fingerprint of your game from whatever configuration you're using. Google signs your bundle with a private key so it won't be the same as your debug fingerprint
Hey guys! Unity is stuck on resolving mobile dependencies while labeling libraries
I can't find a solution for this
I'm also getting this error message when trying to build to android:
Stopped polling job due to exception: System.NullReferenceException: Object reference not set to an instance of an object
at GooglePlayServices.UnityCompat.VersionFromAndroidSDKVersionsEnum (System.String enumName, System.String fallbackPrefKey, System.Int32 fallbackValue) [0x00001] in <48abf529805a49c69e88ffb3f8b573e9>:0
at GooglePlayServices.UnityCompat.GetAndroidTargetSDKVersion () [0x00036] in <48abf529805a49c69e88ffb3f8b573e9>:0
at GooglePlayServices.PlayServicesResolver.CanEnableJetifierOrPromptUser (System.String titlePrefix) [0x000b0] in <48abf529805a49c69e88ffb3f8b573e9>:0
at GooglePlayServices.GradleResolver+<>c__DisplayClass7_0.<GradleResolution>b__5 (System.Collections.Generic.HashSet`1[T] unusedUnlabeled) [0x00026] in <48abf529805a49c69e88ffb3f8b573e9>:0
at GooglePlayServices.PlayServicesResolver+<>c__DisplayClass118_0.<LabelAssets>b__0 () [0x001e1] in <48abf529805a49c69e88ffb3f8b573e9>:0
at Google.RunOnMainThread.ExecutePollingJobs () [0x00052] in <ac8e755fbc27434ebdaf117e2c7041d9>:0
UnityEngine.Debug:LogError (object)
Google.RunOnMainThread:ExecutePollingJobs ()
Google.RunOnMainThread/<>c:<ExecuteAll>b__24_0 ()
Google.RunOnMainThread:RunAction (System.Action)
Google.RunOnMainThread:ExecuteAll ()
UnityEditor.EditorApplication:Internal_CallUpdateFunctions ()
Hello i have an issue with AdMob,for some reason after compiling the LoadAd() Function is changed to loadAd(), i get a logact error "java.lang.NoSuchMethodError: no non-static method with name='loadAd' signature='(Ljava/lang/String;Lcom.google.android.gms.ads.AdRequest;)V' in class Ljava.lang.Object;"
check your proguard rules
hey, this has probably been asked a few times im guessing. how do i apply behavior to mobile (specifically android) back return arrow w/ the new input system?
Hello everybody. I am a beginner game developer. Recently put my game on Google Play. Who doesn't mind, protest and offer ideas for development. Link - https://play.google.com/store/apps/details?id=com.PlayGoCorporation.ball
yes, it gives me a "Resolution failed" warning
nevermind I got force resolve to work
lets see if build is also working now
Go unity preferences, and uncheck Gradle, then again check
that's what I just did to fix force resolve lol
omg the build finally worked thank you!
Can try my game?
oh you mean this?
well okay yeah
Thanks
I have 2 years of game dev experience but not really much with android games but I'll try
in my opinion you should try to monetize a game only once you have like a bunch of game dev experience
Alright
my review:
that's good advice but it's my goal to make the game popular 🙂
yeah but I meant in-game purchases with that
and that doesn't make your game more popular
++ nice main menu music, fitting to the feel of the game (you should also put it in the actual game)
++ nice and simple graphics, not distracting
- nice UI and font choice (except for the icons in the main menu; they look really blurry and when clicking on the one in the top left I didn't know it would take me to play services)
++ really nice transitions, animations & effects
- since this game mechanic already exists multiple times, maybe add a twist to the game mechanics?
- the settings look pretty complicated (make toggles instead of buttons)
- for the quit button, make the popup also go down again once you cancelled quitting (looks weird moving all through the whole screen)
-- too easy, add a difficulty curve (smaller spike distances over time etc.) => I was easily able to get a highscore of 42 and could theoretically get infinite
-- add more game elements for more interesting scenarios
thanks for the feedback, it will help me improve my game
for the game page:
-- music doesn't fit at all
- thumbnail looks pretty pixelated and not interesting at all (add maybe bloom and color correction etc.)
- don't die so early in the trailer, just make fast transitions to other gameplay-situations which would look way more interesting
- show off more (not only gameplay, but also main menu etc.)
- for the game icon it's the same as for the trailer thumbnail; make it more interesting
- screenshots are good selected but there are too many and none shows the beautiful transition from the main menu to the game or even the main menu itself
all in all, really good and juicy feel of the game, but there's still much to improve in the backstage
I want to sell my imac to get a MacBook pro but how do i shift my files without losing it?
sorry, this is not a chat to discuss the sale, but you can throw them on Google Drive
@glossy sluice
@chilly canyon #502171626805133312
ok, sorry
Sry
Try resolve google services, if you have this
Please how do I move the inputfield ui above TouchKeyboard for Mobile?
When trying to have a banner ad. Do we use the services window and use the Unity packages, or do we have to use IronSource package?
Where to get channel id for Mobile Notifications?
Unity is the ultimate game development platform. Use Unity to build high-quality 3D and 2D games, deploy them across mobile, desktop, VR/AR, consoles or the Web, and connect with loyal and enthusiastic players and customers.
Hi guys, I'm trying to implement the admob ads on unity but to no avail, on unity editor will work but on android device the game crashes as soon as I click on the icon.
I also followed this tutorial but nothing:
https://www.youtube.com/watch?v=KKL3k-Uk5JU&t=67s
Unity version: 2021.3.2f1
ADMob version: v7..1.0
Somebody can help me with this?
Did you answered on my message above?
Yes
You can use the Android Logcat, in package manager, to see the error happening when it crashes out on you
Or through adb
Hey guys, im trying to use Unity ads and so Im following the Unity documentation, to install "Advertisement Legacy" and "Advertisement with Mediation". I copy pasted the script "Initializing the SDK in Unity" script but I am getting some errors when trying to access certain things as seen in this screen shot
I have been searching online and can't find what to do as various yt videos are out of date
Using Unity 2021.3.11f1 and Ads package 4.4.1
Alright I think I figured it out. If anyone runs into this issue this is what I found out.
If you try to make the script in a folder and are adding an assembly definition in it. Then these scripts can not see, the Unity Ads package since they are in another assembly. So I just created the same script outside that folder and fixed.
Hello I'm having problems with the Xcode build of my game, the error says "Duplicated Symbols for arquitecture ARM64" I'm been stuck for a few days now I don't know what to do can somebody help me please?
Also if you want to add this file to where your other files are with the assembly definition then you just have to add this reference on this spot of the assembly definition
If anybody has this problem, the issue it was that Unity needs to rebuild the script once you decide to change the platform. Just add a comment in a script and let it reload the script before building the project
From adb i don't get nothing because the game doesn't start. It crash before opening
adb will still give logs whan an app crashes whilst launching
why when I export my project to android studio seems to set the apk for armeabi arquitecture? where is that setting?
this is what appears when i try to run the project on the emulator
I'd apreciate any help im new on android till now i just did ios builds
I placed an ad in my game, but when the ad opens, the game's music continues to play in the background.
Is this happening because I'm in test mode or do I need to write some other code to fix this problem?
In project settings - player settings - android - other settings enable IL2CPP and enable 64 bit/arm64.
Also something else: you don't need android studio at all. You can simply build from unity for usually a faster workflow
If you don't stop the audio of the game I am not surprised the audio does not stop. Mute the game audio when the ad shows
thank you i got it done in a different way
guys I tried to connect my smartphone to Unity with usb,
hoping Unity will recognize my smartphone,
but pity it won't succeed, it tried to fetch but there is no such
brand shows up *I'm with samsung by now
also is there any particular configuration to build an .apk for android 11 ?
since my android say 'won't install the apk'
I just download the .apk manually from directory
Is your phone in dev mode with usb debugging on? @frail obsidian
Then you can see your phone in 'run device'
Otherwise show the error
now I switch to manual method
build the .apk manually and install it manually
new situation occur, the .apk is crashing for some reason ..
is there any particular configuration for android 11 ?
I'm making some AR with Vuforia,
and surprisingly the results really big it's around 70mb
for just the image tracking and animated cube
🤷♂️
this is my set up and still stopping
it works on runtime already
what is usually the best aspect ratio/resolution for me to make my game at?
Adb also lets you see the general Android logs. It should still show you the attempt to execute and if it closed the program for any reason before starting up
All of them (use a canvas set to scalar at 0.5). I usually test in landscape mostly, and then do a final ultra wide, wide, portrait, and square test to make sure all the UIs adjust properly
It's common for me to use two different UI stacks for widescreen and portrait though
Just to get a more comfortable layout
I might be in the wrong Channel here(Sorry if I am), but is it possible to set up a Repeated Local Notification but is repeated a limited times only?
ex:
for 7 days Notify Everyday at 12 noon.
i dont have an android phone 😄
also, what if you want to debug on device?
Make a debug build and use the logcat package (or with autoconnect profiler the logs will just show in the console)
can i connect Rider?
Not sure
Hi where i can learn about unity mobile third person player controller (move , look around , jump and fire)
Hi! Oh boy I am frustrated today. I switched on Symlink Sources on a totally working build to see if it might speed up iteration time. Well it failed miserably as expected, so I switched back off Symlink Sources. However, ever since that moment of great hubris when I ticked that checkbox, my game fails to build! It has this opaque error about an index being out of range:
System.IndexOutOfRangeException: Index was outside the bounds of the array.
at iOSPlayerBuildProgram.SetupTargetForInludedFile(IncludedFile file)
at iOSPlayerBuildProgram.AddProjectFile(NPath srcPath, NPath dstPath, Boolean addToEmbeddedBinaries, String targetGUID, Boolean shouldAddToProject, SymlinkType symlinkType)
at iOSPlayerBuildProgram.SetupCopyPlugin(NPath pluginPath, NPath pluginDest, Plugin plugin)+MoveNext()
at System.Collections.Generic.List`1.InsertRange(Int32 index, IEnumerable`1 collection)
at System.Collections.Generic.List`1.AddRange(IEnumerable`1 collection)
at PlayerBuildProgramLibrary.PlayerBuildProgramBase.SetupCopyPlugins() in /Users/bokken/build/output/unity/unity/Editor/IncrementalBuildPipeline/PlayerBuildProgramLibrary/PlayerBuildProgramBase.cs:line 537
at PlayerBuildProgramLibrary.PlayerBuildProgramBase.SetupPlayerBuild() in /Users/bokken/build/output/unity/unity/Editor/IncrementalBuildPipeline/PlayerBuildProgramLibrary/PlayerBuildProgramBase.cs:line 174
at iOSPlayerBuildProgram.SetupPlayerBuild()
at PlayerBuildProgramLibrary.PlayerBuildProgramBase.RunBuildProgram() in /Users/bokken/build/output/unity/unity/Editor/IncrementalBuildPipeline/PlayerBuildProgramLibrary/PlayerBuildProgramBase.cs:line 168
at PlayerBuildProgramTypeWrapper.Run(String[] args)
And so yeah, I am now completely dead in the water, all cuz I had the arrogance to momentarily tick a checkbox.
I would file a bug but the last one I filed two months ago hasn't seen any movement so I'm not willing to waste my time with Unity's bug reporting system. They don't respect my time, so I don't respect theirs.
And now, with the typical advice of Just delete your Library folder and restart, loser The project won't even open.
and that is why we use source control
You also have to keep in mind: They don't respect my time, so I don't respect theirs. the problem with this statement is it neglects the fact you are stuck with an issue, they are not. So really it only hurts yourself.
Not sure if you are just wanting to complain or actually seeking advice.
But if you read that stack trace, it sounds like it failed to copy a plugin for iOS. Which means either a plugin inside a package or a /plugin in your project isn't copying to the build folder and mostly likely needs to be toggled (or the /obj and /temp folders are causing a problem). A few possibilities there, but I don't really like to troubleshoot Apple stuff, and again not sure you really want help anyway ... So good luck in your journey.
https://docs.unity3d.com/Packages/com.unity.mobile.notifications@2.1/manual/index.html
The Unity Mobile Notifications package adds support for scheduling local one-time or repeatable notifications on Android and iOS.
It looks like you may be able to cancel it. But I suspect you need to code it at app run time, which only helps if they launch the app
You probably could create a manual plugin for it. But I'm not seeing an easy way
You could set 7 manually instead of a repeat though
notification.Title = "Your Title";
notification.Text = "Your Text";
notification.FireTime = System.DateTime.Now.AddMinutes(1);
AndroidNotificationCenter.SendNotification(notification, "channel_id");```
Basically loop that 7 times and increment the day for each one.
Hey everyone, I'm trying to create a mobile game where there's an image gallery of around 500 images. each image is around 1mb in size and so i can't load them all in at once because that would use a lot of memory.
So currently, i've placed all the images in the StreamingAssets folder and then at runtime loading it into a RawImage component. This works well but I was wondering if there is a more efficient way of loading this? I'll also use this same method for loading audioclips for each image. Hope someone can point me in the right direction!
Guys i want to ask, i've a ui when i start in editor it's normal but when i build and run on mobile it's messed up
Running unity 2022.1.23f1 on Windows I'm noticing some times my iOS target builds produce a Il2CppOutputProject in the Output folder, and some times they do not. Is this related to some option I have selected?
Probably il2cpp?
I've read up in il2cpp a bunch of times but don't see how/when/why it would apply to an iOS compilation.
It sounded like when you want JiT for a platform
The default is mono, but il2cpp is faster.
The new unity versions got incremental builds, which introduces the folder as a cache
How would I toggle that within Unity? I've seen very, very few iOS build options.
Go to project settings - Player settings - ios tab - Others
There the architecture can be il2cpp or mono
It's about how the game will be compiled
Let me take a look, I'd find it crazy if they randomly were changing on me.
Hmm, looks like IL2CPP is greyed out/unselectable. Perhaps tied to something different in there. That folder isn't appearing anymore which I found strange.
Screenshot?
Ahhh ios builds are locked to il2cpp because of apple requirements
Then I'm unsure why it only happens with some projects
Yeah, so strange.
When the folder is present I get a ton of IL2CPP build errors
The folders inside aren't named correctly.
Mac_x64 instead of Mac_x86_64 for example IIRC
Just really odd stuff.
I've done a full reinstall a few times working my way back until I'm on the version I'm on trying to get it stable for more than a few weeks. I should probably just bite the bullet and have Unity on my Mac but I prefer to develop on Windows and just move over the iOS Xcode project directly.
Ahh well, thanks for the chat though!
Some parts of my textures appear to be pink only in the build. What could be causing this?
Are you using urp or hdrp? @wispy bronze
If so, check the materials that appear pink
Android Resolver resolves dependencies.
My question is how I can add some constraints and exclude some dependencies
For example market specific dependencies (Native, GooglePlay, etc.).
For each market, it should only include that market dependencies and exclude others
I have added asmdef files with preprocessor for each market. It is OK for market folders but android resolver generates aar files in Plugins/Android folder
I am using URP. The shaders I use are the Baked Shader for static objects and Simple Lit for dynamic objects. The problem only occurs with the static objects. Please notice! Whole objects aren't pink, only parts of them, even though they are using one shader.
^^
Hmm weird. This doesn't happen if you don't tick the static box? (Light bakes still will be used)
And did you update unity and urp to the latest already?
Hi everyone, can someone tell me what the best and most common ways are to optimize my game (I am using URP) for a mobile device .. I have never done anyrthing like that before, so please give me topics/videos and anything else that you can think off.. thank you
These are the easiest wins: https://youtu.be/7S6QQKtvNo8
Other than that it really depends on the content you make. Check out guides on the profiler and profile with a development build on your phone
Unity has so many settings that it might be hard to know where to start. In this guide I will show you to improve your CPU performance a LOT, by just changing a few settings. No code or knowledge is required in order to follow this guide!
This guide applies in the Built-in Render Pipeline, Universal Render Pipeline (URP), High Dynamic Render Pip...
When you guys save player progress to the cloud, what do you use? Locally i save a binary file, but google play services does not allow binary files?
Hi, i can export my project but not even build but why? Im using imac
Hi! i'm building a game for Android. I installed the mediation package, but I had issues when building. Then I read this:
The Advertisement with Mediation package contains Unity’s own ad mediation solution, which is no longer being enhanced. You may still download and use until further notice, but we recommend using Unity LevelPlay for longer term support and improvements.```
What is the best way to implement ads right now and if it's not mediation, how can I remove mediation ?
The notice seems quite clear
Is there a way to get Unity's current focused View in android, for using as a reference in a .java plugin?
I'm trying to use ironSource and LevelPlay ads, but I can't manage to get it work. I get an "Unsupported platform" message in the editor, is it normal ? Also, should I enable the Ads in the services panel ?
do we have to use LevelPlay instead of the default packages that get generated when using Unity editor
Im finding that I can not build a aab, but when I remove "Advertisement Legacy", unity allows me to make an aab, which to me means that the issue is with that package
Is there anyone who have used IAP before in unity? If yes, then can anyone tell me how to begin with IAP? Right now i heard that to include IAP in my project i need my game to be published in any of the store(google playstore, app store etc) first. I haven't published my game yet so can i still use IAP or do i need to publish it first?
yes, typically ads only work on a device. I recommend you use an actual, physical device. Sometimes ad networks won't serve to emulators at all
I managed to get it work, thanks!
I'm not sure of the best way to load and show ads though
Is there a way to check if an ad is loaded ? I made an int that increases when onInterstitialAdReadyEvent is triggered
I also made this, but I don't want to have it load many ads in the background:
static void OnInterstitialAdLoadFailedEvent(IronSourceError ironSourceError)
{
instance.Invoke("LoadInterstitial", 30); // Load again in 30 seconds
}```
What are the best practices ?
I use a different mediator, but usually: start loading ads as soon as you can and use an exponential backoff in the case of an ad load failure
What's an exponential backoff ?
THANK YOU
guys, we are trying to make a game based on writing the letters on the screen on mobile. We decided to create our own keybord input and take the words over there. But we dont know how to do it. Is there any different ways to make this system? Or who can help us?
Is there some way to look at the code of this file?
at PlayerBuildProgramLibrary.PlayerBuildProgramBase.SetupCopyPlugins() in /Users/bokken/build/output/unity/unity/Editor/IncrementalBuildPipeline/PlayerBuildProgramLibrary/PlayerBuildProgramBase.cs:line 537
I assume not because it appears to be in some kind of virtual directory
Hello i want to change the name of my url folder on my imac. Do i will lose my projects? Every path starts with user/pascal/… and i want to change to user/pas/
This doesn't seem to have much to do with a mobile platform, but you can
- click the three dots to the right of the project
- Remove project from list
- Change your filesystem however you like
- In Unity Hub, click The down Arrow to the right of
Open - Add project from disk
Thank you. Ok. So, if i will change now the url it will change my project url to the new Name of it. So all my projects will not break?
Yep (didn't have success tho)
Just ask your questions
Make sure the android module + 2 submodules are installed in unity hub
In player settings - other enable il2cpp and enable 64 bit
Here you can see some of my settings
It's for quest 2, but that also runs android
i did all that and it just kinda broke my unity
Define broke
Hey it doenst work?
Then do you know the answer right here?
alot
has anyone used IronSource mediation package and sent IronSource an email with their bank info?
Hey I cant build a apk please help! I get many errors but I think the important one is this > Configure project :launcher WARNING: The option setting 'android.enableR8=false' is deprecated. It will be removed in version 5.0 of the Android Gradle plugin. You will no longer be able to disable R8
has anyone sent bank info to IronSource to get their account approved to use LevelPlay?
can anyone help me understand why my game is doing this, every time i click a button, such as menu or play it takes a second or two to go to the next scene, its for a mobile game.
when you change scenes it creates the stuff from the next scene and destroyed stuff from the scene you are no longer in
the bigger the second scene is, the longer the delay that you might get
Not sure why for you its 2 seconds exactly, but thats what happens when you change scenes
If you aren't specific I am not helping. If I tell you my project broke, how are you supposed to know what is going on
I've heard in a Unity profiling talk that mobile devices vsync is forced on by hardware. Is this still true?
Mobile hardware hasn't changed in 2 years in that regard, no
I still have doubts about that.
Yeah same. I can't find any info on the topic
Trouble Building on Xcode for IOS
Probably a common question, scene is laggy in remote 5 but not on my pc, is this just a remote 5 thing l
Remote is streaming, so not running on the actual device.
Don't think anyone can give more support then check your wifi or usb
The solution: build natively to test performance on mobile
Thanks, I’m fine with the low fps as long as it’s not the final product
Hii,
I'm mobile developer and my project has a 3d viewer made with unity. I'm interested in cross-platform.
Is there any multiplatform sdk/framework (Flutter, Xamarin, React Native, Ionic... ) that can integrate the viewer seamlessly ?
The app would have the viewer embedded on it, it's not just the viewer, also has other interfaces.
Uh React and Angular have plugins to embed Unity projects inside webgl builds
Hey i wanted to make my first android game switched to Android now my file is broken + my pc shutdown does anyone know why this happens?
Cant even open the game anymore :,((
For whatever reason when i start and chose windows as the current platform everything is normal
It bluescreens when you run emulated android?
its not a bluescrenn my pc instantly shutdown if u mean that
maybe its my hardware tho i had that a problem a few times in the past
but its happening everytime when i wanna swap to android in unity
These options are better than Flutter?
Maybe remove and reinstall Unity. But besides that, heavy tasks can cause faulty hardware to stop working, so maybe thats another none software issue
i recently upgraded my cpu but im still waiting for my cpu fan i had issues with that obvi cus of the cpu tempature but that shouldnt happen instanly when i click on switch platform to android right?
when you switch platform, unity recompiles everything and checks if it should reimport assets, create asset variants for the target platform and what not. So thats some load there, but it could also be a faulty harddrive or RAM or just a bugged out unity. try another version AFTER backing up somewhere.
ok thank you
hey guys, I am trying to port an iOS Project to TVOs. I just got the latest Apple TV but unfortunately it lacks an USB-C port. So how are we supposed to test our games without being able to connect it to our dev machines?
Unrelated to your question - did you get the one with the ethernet port?
Probably the only way now is to use Testflight
yes I have the ethernetport version.
Is there any alternatives to bloom in URP? The bloom in the volume profile so expensive for mobile
Only alternative is bake lightmaps after setting material to emission with high intensity
How would I check if the player is in Landscape or Portrait mode in my game I see the auto rotation in unity but it doesn't seem to scale correctly? (Yes I do anchor everything)
Hey guys, can you please give me your point of view on my game : https://youtube.com/shorts/DK73xFZ4FlM?feature=share
► Awesome Hyper Casual Course → https://www.udemy.com/course/unity-mobile-game/?couponCode=YTB-TEAM2
► Make your own Cricket Mobile Game → https://www.udemy.com/course/unity-cricket-mobile-game/?couponCode=YTB-TEAM2
► Word lover ? Make a Word Mobile Game → https://www.udemy.com/course/word-finder/?couponCode=YTB-TEAM2
Maybe some improvements ideas ?
I want to make it level based. Your goal is to control the rocket and take a package from Point A to Point B.
I thought about adding a timer for Speedrunners.
I'll surely add multiple Rocket Skins.
Also thiking about adding rockets / thrusters with different caracteristics (More Thrust, More stable, ...)
That's pretty much it 🙂
i want the user to select a profile photo. How can i have access to the device storage? i spent a few hours and found little to no helpfull information on how to achieve this 😦 Can someone give me a hint?
assuming you're talking android, it would probably be best to create an implicit intent filter that has the user choose a photo, and get that data back
You probably want to put that in #archived-works-in-progress or something therein
does anyone know how to put mobile keyboard input with field text
I looked in unity documentation and I still don't know
when you are on the mobile build, and you click the field, the keyboard should pop up
can anyone see why this would not be working
is there an updated way to do it with input actions or something?
Do you mean you use the new input system?
I have it set to both. But this code is not doing anything
Put a Debug.Log inside and outside every if block so that you know which part fails
I have to squueeze every fps possible out of a simple app just shows a single unlit texture on android, what do I turn off?
I can't see the console on mobile
any way to throttle the framerate depending on the soc temperature?
Check the adaptive performance package
A lot
Maybe this can already help: https://youtu.be/7S6QQKtvNo8
Unity has so many settings that it might be hard to know where to start. In this guide I will show you to improve your CPU performance a LOT, by just changing a few settings. No code or knowledge is required in order to follow this guide!
This guide applies in the Built-in Render Pipeline, Universal Render Pipeline (URP), High Dynamic Render Pip...
Other than that not many people can help you without project access or specific questions
Thank you that hopefully helps, I was using mono,
To be more specific I'm using an S21 FE to build a video player for AR Glasses. The SDK uses unity and there seems to be some thermal throttling behaviour going on with this samsung, where at around soc temp 39-40, all unity performance, in AR or not comes to a crawl, and this includes even a minimal scene with no objects, 1 camera, and no light source. I think the phone has a design issue, I'm not in the USA so the phone was provided with the exynos 2100 cpu instead of the more reliable cooler running snapdragon. So americans I'm asking for help have no Idea what I'm talking about mostly
IL2CPP helps a ton yeah, especially if you also enable arm64
Ok so just used the app for about 30 minutes, 20 minutes longer than ever before, happy to say that vide and its suggestion to use IL2CPP has solved my problem, a problem I've had for days making me feel sick and sad about how much I spent on the hardware to start this project. Thank you!
Hi there, do you know tosolve this problem?
I have no idea, sorry, I'm not familiar with Unity, just app development
Hello recently I have been faced with this error. But the cause is extremely unusual and I can't find anything online even openai.chat came up empty on this one
But for this error to appear all I have to do is rename my company in the settings. So basically when ever the packname is changed from com.defaultcompany.<appname>
First thoughts would ofc be bad format package name or an already used package name.
But nope I have tried over 20 combinations and not even one letter from defaultCompany can be changed without this error
I can make it build with custom packname but only when built in ic2? Instead of mono ( I may not have the right names but you should know what I mean) with arm64x
So this results in successful build but the apk can't be installed on a android as it gives error package name already in use. ( Doesn't matter what package name I use)
But simply renaming it back to com.defaultcompany.<game> it works fine.
I backedup my source file and then I took all my assets back to the last successful build. But same issue is present.
So I'm starting to believe it is a bug or a error in a installed/preinstalled package.
Even tried manually renaming all com.defaultcomany.<game>
I'm using 2021.3.15, and honestly I'm out of troubleshooting ideas.
And fyi if post the full logs but honestly the logs are even more useless and the build failure popup has most details. In the log
I also tried openai.chat to diagnosis didn't help.
( Although I will add I'd advise more people use openais new chat bot. It is actually extremely good at finding bugs from logs. And also for general information. I wouldn't trust it 100% but in the two days I used it it's actually helped me diagnosis alot of problems )
Oh I'll also add this issue is there even on new projects, even after a complete reinstall of engine and hub
omg. i've been working on my game for like 2 years and have never used this lol
so this works now but it's too fast
i want the back button to open the menu and then if its pushed again it will exit the game
i think it's staying down for a sec because the way i'm detecting if the 2nd time it's pushed is if the menu is active
oh do i just flip the If statements lol
have you also never used else if
Hey, guys
Does anyone know the best way to save data when Android app is closed?
I'm saving data to Google Play Games. OnDestroy and OnApplicationQuit don't workÏ and OnApplicationPause is not reliable
Those are the methods that can be used. If someone force closes the app then you can't do anything because the app isn't running anymore
Not force close, regular app close
The thing is the method that is in OnApplicationQuit has a callback method, maybe that's the problem?
You have a limited time to do anything in OnApplicationQuit
Then what's the most reliable way?
I doubt it's the best way, but how long do I have in OnApplicationQuit then?
I'll give it a try
Is anyone else having an issue with Unity finding their app-ads.txt file? I'm using a squarespace website so I can't put the file in the root directory meaning I have to use a redirect. This was working until sometime in the past month. Now unity says they don't allow redirects for the app-ads link.
OnApplicationFocus() works quite well
Can someone here help with build errors?
I have been asking the actual question else where with no response
Configure project :launcher
WARNING: The option setting 'android.enableR8=false' is deprecated.
It will be removed in version 5.0 of the Android Gradle plugin.
You will no longer be able to disable R8
Task :launcher:preBuild UP-TO-DATE
Task :unityLibrary:preBuild UP-TO-DATE
Task :launcher:preReleaseBuild UP-TO-DATE
Task :unityLibrary:preReleaseBuild UP-TO-DATE
Task :unityLibrary:packageReleaseRenderscript NO-SOURCE
Task :launcher:generateReleaseResValues UP-TO-DATE
Task :launcher:compileReleaseRenderscript NO-SOURCE
Task :launcher:generateReleaseResources UP-TO-DATE
Task :unityLibrary:generateReleaseResValues UP-TO-DATE
Task :launcher:createReleaseCompatibleScreenManifests UP-TO-DATE
Task :launcher:extractDeepLinksRelease UP-TO-DATE
Task :unityLibrary:extractDeepLinksRelease UP-TO-DATE
Task :unityLibrary:compileReleaseRenderscript NO-SOURCE
Task :unityLibrary:generateReleaseResources UP-TO-DATE
Task :unityLibrary:packageReleaseResources UP-TO-DATE
Task :unityLibrary:compileReleaseLibraryResources UP-TO-DATE
Task :unityLibrary:compileReleaseAidl NO-SOURCE
Task :launcher:mergeReleaseResources FAILED
Task :unityLibrary:generateReleaseBuildConfig
Task :unityLibrary:processReleaseManifest
10 actionable tasks: 3 executed, 7 up-to-date
UnityEditor.BuildPlayerWindow:BuildPlayerAndRun ()
This all started because banner ads would not show up on my phone, but they do in the editor
I updated the ad package and now it won't build
I also have a ton of "Mapping new ns" messages
Which unity version?
Do you use custom android manifest files or others?
Did you change any settings regarding android?
Does it happen in a blank project?
Unity 2020.3.42f1, and I have changed the SDK to 31
I have not tried it in a blank project
This was the error I was getting when the app would build and run on my phone
I have no idea what broke
I have every gradle file open and I do not see "android.useAndroidX"
I have resolved my build issue
Some how the "Use custom gradle template" was checked
But now I am back to the point of the ads not loading on my phone
https://answers.unity.com/questions/1915834/advertisementbannersetposition-throwing-exception.html Tried down grading the ad package as suggested here, but back to getting the gradle build error
Unity is the ultimate game development platform. Use Unity to build high-quality 3D and 2D games, deploy them across mobile, desktop, VR/AR, consoles or the Web, and connect with loyal and enthusiastic players and customers.
After noticing there was an update to 4.4.1, I tried that version and I got the same gradle build error
Seems that any time I change the package I get the gradle build error. I just tried changing it back to 4.3.0 and the error showed up again
"> Configure project :launcher
WARNING: The option setting 'android.enableR8=false' is deprecated.
It will be removed in version 5.0 of the Android Gradle plugin.
You will no longer be able to disable R8"
I have tried removing android.enableR8=false from the file, but it keeps adding back when I try building and running
So I deleted resolved dependencies and that has fixed my problem
Well now I get this error "Warn UnityAds com.unity3d.services.core.connectivity.ConnectivityMonitor.initConnectionStatus() (line:109) :: Unity Ads was not able to get current network type due to missing permission"
Tried following this, but I don't have a "build settings" in player options
I found the setting, but it's still not working
Found something that said to check the manifest. It appears that the proper permissions are in there. Yet it still says the proper permission don't exist
I cant figure out why DoRenderLoop_Internal() is taking up so much time
even on a very basic scene, i am getting subpar performance
You can expand it. Probably something graphics related or a GPU bottleneck @coral fable
HI,
I have one query. I build one APK from Unity and that size is more than 5.5 GB so I used OBB option. but OBB max size is 4 GB. so how can I Build for Quest 2?
look at the editor log after doing a build, see why it's so big.. remove/ optimise things
@limber ruin see above. I'd say try to get that size down.
If not possible, try splitting into multiple obb files maybe
Size reduce not possible. so how can i make multiple OBB? I used Split Binary option from project settings.
Im trying to build an android app bundle but keep getting these errors.
it always fails on the gradle build
Read/show the third error
i think this is the most important part
its just warnings after
Unity version is 2021.1.23f1 btw
Follow this video and see if you can get it working https://youtu.be/3Qay9h14swM
I've seen some people say that updating the SDK when prompted starts working if they run Unity as admin
hmm ran it as administrator and tried the left "Update Android SDK" option but still getting this
the errors i sent before came from the "use highest installed" option btw
Right so try following the video
thats a different error though but executing that command in cmd says it doesnt recognize the command
he's also not building an app bundle
Are you building for play store?
Then you're gonna need API 31 not just 29
I'm trying to find the link to what got it working fo rme yesterday
you had the same thing?
Yep haha
So save this as SDKD.cmd, insert your unity version, and run it
set JAVA_HOME=C:\Program Files\Unity\Hub\Editor\2020.3.16f1\Editor\Data\PlaybackEngines\AndroidPlayer\OpenJDK\
set ANDROID_HOME=C:\Program Files\Unity\Hub\Editor\2020.3.16f1\Editor\Data\PlaybackEngines\AndroidPlayer\SDK\
cd %ANDROID_HOME%SDK\tools\bin\
echo.> %USERPROFILE%\.android\repositories.cfg
cmd /C sdkmanager --update
cmd /C sdkmanager "platform-tools" "platforms;android-31"
cmd /C sdkmanager "platform-tools" "platforms;android-32"
cmd /C sdkmanager "platform-tools" "platforms;android-33"
ehh not the best with cmd stuff, how do you make/run the SDKD.cmd
I just double clicked it
but how'd you make the sdkd.cmd?
it doesnt run in cmd for me, just opens in notepad
Right click in explorer > New > Text file > Set the name to SDK.cmd
You can right click and run the file too
mm doesnt do it for me, just keeps opening in notepad. I cant choose cmd when saving, only .txt
You can also open command prompt as administrator and paste the code in
still getting this after running commands
Does anyone know where / and how to check performance memory guides on mobile?
for example this is my snapshot
is 112 mb too much?
I noticed, that when i look down on my terrain, i have 50 fps, and if i look just above it i get lots more even though the trees etc is in view. Seems that the terrrain itself consumes alot fps. I use Gaia Terrain with the low poly setting
To my knowledge terrains aren't usually used on mobile. You would use a mesh instead
does anybody have a background on using AdMob with mediation? I dont seem to see Mediation anywhere in my package manager...
Hmm okay
My problem is not the amount of tris im sure, its something else with the terrain
Microsplat has helped me before but it messed with my textures
Ill research it
Most likely heavy shaders and/or many draw calls. Both will be hard on mobile hardware due to the GPU being a tiled gpu
Not sure the exact details of terrain, but I know those are usually the issues on mobile and I know terrain on mobile sucks
What do you mean? If you don't have an issue it is fine. If you have issues, then explain the actual issue.
That memory usage seems fine to me, but there is a lot more than just memory usage
Yeah, ive optimized my drawcalls alot for my nature, using same material etc. But i just notice while testing on mobile now that i get like 80 fps looking at the trees. But 51 fps just looking down on the ground, like just under my player only
Not even looking at a horizon of terrain hehe
Maybe look for terrain to mesh tools online and LOD the meshes?
Can be a pain for the trees etc if you have them painted onto the terrain tho. Not sure if there are any tools for that yet
Terrain already has some sort of LOD system, but if you bake it into a mesh it won't since, well, it's a mesh. You can cut up the mesh and then LOD it to get some performance back of the increase in tris
My game runs okay at 55-60fps but i notice sometimes 50 etc and i think that terrain is whats stopping me from going 60+
Ah i see
Like a grid yeah
Yepyep
I'll see what i can do, i know that microsplat gives terrain better preformance
But again, thought i could use without
Since i have the Gaia terrain asset
Thanks for inputs mate
No problem! Good luck
After updating from 2022.1 to 2022.2, I can no longer archive my build for iOS. Any ideas?
Just to let you know, it's fixed. Just used a new Unity version and had to add 2 lines to gradle.properties
thanks for your help yesterday
Fair enough, I didn't have the option to upgrade so I needed to fix my existing version. Great that you got it working :)
@lime violet i see you have the same issue as me, do you know how to fix this?
Click on the last error I think it is and see what the 4 errors are in the body of the console
All that says is Gradle failed to build the project. You need to look at the log item to determine why.
Keep going through the errors, you'll find one with specifics
i've tried everything
doesn't work
i've tried reinstalling unity
upgrading gradle
changing build settings
nothing works
nothing
i get different errors
not always this one
We haven't found the error yet, it's in one of the logs
I don't think you understand what it is telling you. Unity is only showing that the building using Gradle failed. The reason it failed will be embedded in one of those error logs
how do i see the reason it failed then?
Unity doesn't really handle Gradle that well, and can't understand the errors from it very easily. So you need to look at the messages and find the one that shows you the error messages returned from Gradle
this one?
You need to go through each error to find the response from Gradle that says why it failed.
Yes
This helps - it shows some missing build tools in Gradle...
com.android.tools.build:gradle.6.1.1
You need to install those. If you have a vanilla unity / built in Gradle install, it should self resolve that issue. But if you messed with the Gradle install, now you'll need to go into android studio and install the missing sdk manually
can you please explain me how to do that in detail
I can't, it depends on how your Gradle is now configured. There are a few different ways to resolve this and it depends on how things are currently installed, one though is to open Android Studio and install the tool version listed in the error message.
i have gradle installed through unity
The good news is now that we have the error, we know why the builds are failing.
https://stackoverflow.com/questions/72922400/gradle-build-failed-in-unityv-2021-2-14-gradle-6-1-1
And other folks have the same error.
There are a handful of ways to solve it. Manually install the missing SDK version to Gradle. Use a custom Android studio build with the right Gradle installed. Or use a different version of unity that should have a fresh Gradle without the issue.