#📱┃mobile

1 messages · Page 4 of 1

brazen birch
#

The last option is the lazy / easier way. But may not fix the issue if the problem is with something else in your project throwing the Gradle version off

lilac herald
#

pls dont ignore

#

please let me know if you're still here trying to help me

brazen birch
# lilac herald pls dont ignore

Sorry, busy day over here. Stack overflow is the best place. The error is the same, for some reason Gradle isn't installing the SDK tools you need. It's not an easy one to explain over discord

#

Gradle errors are always fun and cryptic at times. To make it worse, some versions of unity ship with broken Gradle installs. So it can be quite frustrating until you get an abnormal amount of experience with gradle

lilac herald
brazen birch
lilac herald
#

btw, do u think i can delete this folder

brazen birch
#

It's one of those things that takes a few seconds in person but a lot of text online

lilac herald
brazen birch
lilac herald
lilac herald
lilac herald
sly lark
#

Hey everyone, getting this weird error when I try to build:
(21,70): error CS0234: The type or namespace name 'AndroidExactSchedulingOption' does not exist in the namespace 'Unity.Notifications' (are you missing an assembly reference?)
(21,9): error CS0103: The name 'NotificationSettings' does not exist in the current context

But I am not sure why:

#

I am building for android using this API:

lilac herald
#

if you have time ofc

tired lily
sly lark
#

I think its solved, just need to test now and see 🤞

hallow hawk
#

I'm trying to debug a crash stack trace from google play console using
[path omitted]\android-ndk-r25b-windows\android-ndk-r25b>ndk-stack -sym "C:\Program Files\Unity\Hub\Editor\2020.3.33f1\Editor\Data\PlaybackEngines\AndroidPlayer\Variations\mono\Release\Symbols\armeabi-v7a\libunity.sym.so" -dump [pathtocrashstackfromgoogleplaytextfile]
the input text file starts with

pid: 0, tid: 0 >>> [appname] <<<

backtrace:
  #00  pc 0x00000000000f74da  /vendor/lib/egl/libRBGLESv2_adreno.so (rb_vbo_getptr+38)
  #01  pc 0x00000000000b5fb3  /vendor/lib/egl/libRBGLESv2_adreno.so (stream_buffer_object+46)
  #02  pc 0x00000000000b64f3  /vendor/lib/egl/libRBGLESv2_adreno.so (core_glFlushMappedBufferRange+518)
  #03  pc 0x00000000004a0d1c  /data/app/[appinstallpath]/lib/arm/libunity.so
    ...

and I'm getting an output of
********** Crash dump: **********
(and no further output). Any idea what I'm doing wrong?

timber crown
#

Got a real weird one here: I own a Google Pixel 3 and Pixel 6a. I have a tiny project that runs at 240fps on my PC and 60fps on the Pixel 3 but when I put it on the Pixel 6a, it runs at 15fps. I've tried setting Application.targetFrameRate to 240 and 60, didn't fix it.

Two oddities I've noticed in profiling: 1 - The game actually runs faster when I'm tapping the screen and interacting. Once I stop, it slows down again. 2 - When I hit the multitask button to change active application, it begins running at 60fps.

I can provide profiler information if anyone thinks it'll help them diagnose it.

crystal coral
#

I have no clue what's causing this

#

any help?

#

im trying to add ads to my game using mediation but it doesnt seem to load

heavy wraith
#

Hey folks. I am developing in Unity 2022.2 in Windows for an iOS target, move over the folder to my Mac, and compile in XCode and deploy. But this workflow only works about 70% of the time. For reasons I cannot explain, sometimes the Windows build process adds an IL2CppOutputProject in the folder, and then XCode barfs in its build process with unhelpful error codes. The builds that succeed are when Unity does not make this folder. I cannot determine why, as the build options are rather straight forward. Figured I'd ask and see if anyone had ideas?

wild spruce
crystal coral
wild spruce
#

can u send ss , that might help

crystal coral
#

which part exactly do you need ss at? project settings?

wild spruce
#

yea

crystal coral
#

alright am loading the project

wild spruce
#

oki

wild spruce
#

i had similar issue with my game when adding ads , that helped me out , idk much more than that though , but with the ss provided , i am sure others can probably help u out

crystal coral
wild spruce
#

okioki

crystal coral
#

@wild spruce this is the ads section and the error am getting

wild spruce
jagged mesa
#

You have to hit the install button...

crystal coral
crystal coral
jagged mesa
#

I may have to look at it tomorrow after I get up...

crystal coral
#

@wild spruce @jagged mesa

wild spruce
wild spruce
crystal coral
#

these are my settings from the dashboard

#

eh ill just get rid of mediation

#

doesnt seem to work with me

wild spruce
#

okioki , sorry i couldnt help much , a noob myself

crystal coral
#

its alright i think my project is cursed haha

#

but hey AdMob works fine now

#

aside from mediation

uncut oak
#

Hi maybe this is the right place to ask. Does anyone here know how to go about creating something like prisma 3d app?

brazen birch
#

We've built a few modelers and sculpters for VR. It's mostly just time consuming getting good UX the first few times around.

wild spruce
#

How do u guys save your level progress , like i wanna save which levels are unlocked , which are completed so on .
Should i use multiple dictionaries<string,bool> or something else , really need help figuring this out

brazen birch
#

@wild spruce I usually have 4 classes. A master data class for loading/saving serialized files

It has 3 sub classes, User Settings and Session data.

Session data resets automaticslly every launch (it tracks how many enemies you killed this session for example)

Settings data is for all users and levels, contains things like volume. It auto loads and saves on launch.

User data is what stores all the individual achievements and level things for that specific save game. It is manually loaded when they select a game save slot.

In your case, I'd probably store a list of Levels and their Success stats in the UserData. That way you can create multiple save games and users. I personally wouldn't use a dictionary, I'd use a custom class as a LevelDescriptor, with the LevelName as probably an enumerator. This way you can track more such as coins collected, and other metadata

eternal notch
#

Can anyone tell me what to do i am getting this error while uploading the abb file on playstore

Anomalous Permission Usage
Your app is requesting permissions which are used by less than 1% of functionally similar apps:

android.permission.GET_TASKS
Users prefer apps that request fewer permissions, and requesting unnecessary permissions can affect your app's visibility on the Play Store. If these permissions aren't necessary, you may be able to use alternative methods in your app and request fewer permissions. If they are, we recommend providing an explanation to users of why you need the permissions.

Note: This guidance is based on a comparison with functionally similar apps, which change over time as new apps get published and existing apps change behaviour. Therefore the warning may change even if you don't change your permission usage.

analog plover
#

It's a warning, not an error

tired lily
#

why are you requesting that permission? remove it from your manifest

eternal notch
#

i cant find the permission in my manifest

#

i searched entire solution there is nothing like android.permission.GET_TASKS

tired lily
#

do you have any third party package that might be adding it? export to an android project and see what the merged manifest looks like

eternal notch
#

yeah in android studio i was able to see the permission

#

but i think i can edit from there

#

cant*

tired lily
#

you can't, but now you have confirmation that it's being added. Are you sure you don't have a postprocessing script somewhere? and it's not in a custom android manifest?

eternal notch
#

let me check

#

cant find anything

#

i checked all the manifest file present in the project and there is nothing

tired lily
#

then there is a postprocessing script somewhere editing it when you build

eternal notch
#

what is postprocessing script?

eternal notch
#

so i found the scripts tried to comment out the code written on in and still the same case

tired lily
#

did you do a clean build to the new folder? Maybe it is being added in more than one place

#

Why do you have scripts adding this permission in the first place, though?

eternal notch
#

Not sure i am just updating the existing project

eternal notch
analog plover
#

The warning tells you what the consequences are

eternal notch
#

So i have a static scene (like the level is made and the camera is static on the scene) as i see that the different android phone have different resolution so how i can i make that scene dynamic?

obsidian marlin
#

Suffering from a bug in 2022.2.0f1 for compiling Android IL2CPP, seems like it throws clang: no input files on Linux, any solutions?

#

ok it seems providing a local installation of the same NDK fixes the issue

opaque anvil
#

hey everyone, is samsung store supported with unity IAP ? I updated my Unity IAP and in the doc I find no documentation for samsung

#

whereas in version 3 it had a dedicated section

opaque anvil
#

apparently it works out of the box if I understand the documentation correctly

lime violet
#

sorry for the late reply, i fixed it by upgrading to the latest LTS Unity version

inner arch
#

Hey Unity Game Devs! Gameboard (https://lastgameboard.com) is giving away Gameboard Dev Kits to indie devs who are interested in developing multi-user, tabletop games! We have a robust Unity Pre-fab to take advantage of Gameboards functionality (Dev Guide :https://lastgameboard.atlassian.net/wiki/spaces/DC/pages/757530631/Gameboard+Developers+Guide), and can provide example code to help you take advantage of our multi-user interface, object identification and companion device networking. Please email tim@lastgameboard.com if you are interested in applying to the program!

The Last Gameboard

We are the world's first tabletop gaming platform that blends physical objects with digital gameplay to enhance social interactions and build community.

quartz kernel
#

This isn't really a space for ads or self promotion

tender summit
#

so when i play my game in the editor the camera is correctly displayng but when i export it to my phone, its like shrinks the view horizontally so to keep the resolution to the correct aspect ratio

#

basicly how do i make it respect the width and change only the height

#

it respects theheight and changes the width

fallen compass
#

Use the device simulator instead of the game view

tender summit
#

i want it to simply respect the horizontal and change only the vertical

#

people with all kind of aspect ratios will play it

#

so im asking just to make it flexible on one axis

fallen compass
#

What's actually the issue... the UI?

tender summit
#

no

#

the view

fallen compass
#

You should be using the device simulator for mobile regardless

#

Maybe, and bear with me here... you should share screenshots of the issue 🤔

tender summit
#

i dont want to show the game, so let me put it simple

#

imagine a sphere, on PC the sphere perfectly fits in the view,

fallen compass
#

I'm out then

tender summit
#

on my phone the sides of the sphere are cut from the view

#

i think thats very simple explanation

#

you have to understand that i dont want to share the idea

fallen compass
#

no one is going to care enough to steel your idea

tender summit
#

well sure but still

waxen blaze
#

is it possible for variables to be tampered when it is installed on android ?

brazen birch
#

You probably want
Screen.width and transform.position.

#

And simply push the camera back on the Z axis, multiplied by the screen width/height ratio (to counteract the Unity view scaling) and multiplied by the perfect test screen width divided by the actual screen width (device difference)

tender summit
#

thanks i think this might be it

rotund dome
#

Does anyone know how to get touch input without generating garbage collections?

#

I get this spikes when tapping the screen, with also the GC Allocs

#

The way I currently get touch input is: if (Input.touchCount > 0 && Input.GetTouch(0).phase == TouchPhase.Began) { Some Code... }

#

(I've also tried using a panel covering the screen as a button)

polar leaf
#

I'm getting an odd crash on some Android devices, anyone has an idea what the cause might be?

sleek eagle
# polar leaf

Usually a graphics issue
Which unity version?
Which render pipeline?
OpenGL or Vulkan?

sleek eagle
wise lily
#

Hi, my game is lagging alot on the android platform because of the high resolution, what can be done to get all the resolutions suitable for the device so the player can choose from it? I tried (Resolution[] resolutions;) but it's getting the current resolution only, thanks.

sleek eagle
fallen compass
#

Have you profiled it to be sure that it's the resolution?

sleek eagle
#

And that yeah

#

Probably better ways to look then just resolution

wise lily
wise lily
fallen compass
#

ok.. and _what did the profiler show _??

wise lily
#

Maybe I'm missing something, I'm new to the profiler and optimization

fallen compass
#

I don't yet understand the timeline view very well.. if you click this you can change it to the raw something, which IMO is clearer to understand

#

Also, if you click on the rendering section, that will give some details down below that might be useful to you

wise lily
#

That's the scene it has nothing in the Update only buttons which execute simple functions, It's running on a Samsung Galaxy s8 with 1440 x 2960

sleek eagle
#

Then it's not a resolution issue. Do you use urp?
If so, is maybe bloom and ssao are on?

#

@wise lily

wise lily
sleek eagle
#

Check the urp asset and urp renderer

#

Probably SSAO is on

wise lily
#

It's like 20 times faster!

sleek eagle
#

Yepp

sleek eagle
#

I complained already but it won't be exclused in balanced sadly

wise lily
#

Yes I'm using it for imported 3d models on runtime it definitely makes things better.

wise lily
polar leaf
glossy sluice
#

I cant solve this problem #desperated

solid quest
#

can you help me. I will build a apk fore android but thies are the errors

#

@terse reef

neon thicket
echo beacon
#

Hello, I have a problem, I want to put a video in a scene as a splash screen and the video plays in the editor but when I do the build for android it doesn't play, does anyone know what it could be? I get this error in logcat:

nova imp
#

For native list with temp allocator, is it better to create it again or clear it?
For example for a list with 100,000 members

#

and at least for private methods, I want to pass value type arguments as ref type. I would like to use ref instead of in although arguments are just inputs because I will be sure there is no defensive copy at all, any suggestion?

ashen sonnet
#

can Unity build on any older android version or is it limited? I would for example want to build on Android 6 with unity 2021

sleek eagle
#

Less then 0.5% is on android 6 iirc

sleek eagle
echo beacon
#

omg yes it this hahaha, anyways thanks

ashen sonnet
magic agate
#

Hi all, does anyone in here have experience in writing plugins, or java code into the plugins folder for starting activities etc?

tired lily
#

better to just ask your question

magic agate
#

Hi all, im somewhat confused by how we setup activities in Unity. I am using the direct java code in the plugin folder. My understanding is

  • extend UnityPlayerActivity (eg myActivity extends UnityPlayerActivity) , setup your main activity in the manifest to point to this newly extended activity.
  • In this java class you can add your own methods and it allow you to invoke startActivityForResult and be able to deal with those results.
  • Allows me to be a little smarter and call out to other activities.

With multiple activities I want to invoke, I am am confused with the steps on having this work and then get me back to Unity.

  • Ideally I would like each activity in it's own java file.
  • When it's like this, I suspect I can then launch each one from the main extended activity (launch from myActivity) eg:
public static void NewActivityLauncher(Activity activity)
{      
    Intent myIntent = new Intent(activity, NewActivity.class);
    activity.startActivity(myIntent);
}

So now, from that additional activity I am say popping up a dialog and hopefully getting the results and going back to Unity.

  • Is this the right way to do multiple activities in Unity?
  • Once I launch the extra activity, how could I get myActivity to be fed the results and go back into untiy? Is the process more like activity.startActivityForResult(myIntent) , override onActivityResult in myActivity and then return back to Unity (or call Unity to run some method and pass back the results) ?
  • Also, if I passed in additional arguement to NewActivityLauncher, how would I pass them to the NewActivity class when starting the activity?
tender summit
#

wuld you guys say that pooling is essential for mobile games

#

like i destroy and create alot of objects

#

imagine 100 machine guns

#

shooting 10 projectiles/sec

#

with spawn effect, projectile and hit effect

neon thicket
#

Pooling is essential for any game

solid quest
#

pleas help me

tired lily
# magic agate Hi all, im somewhat confused by how we setup activities in Unity. I am using the...

this all sounds fine to me. You can put your java files directly into Unity and they'll be included in your android studio project (ex: Plugins/Android/[reverse-com]/YourActivity.java). Interop with Unity can be done with https://docs.unity3d.com/ScriptReference/AndroidJavaObject.html and https://docs.unity3d.com/ScriptReference/AndroidJavaProxy.html. You may need to put any resources you need (layout etc) into a .androidlib under Plugins for your new activities

tired lily
polar nymph
#

hey, Im super new . looking to learn about creating a mobile card game. any examples that i could play around with anyone knows of? Thank you in advance ^^

hexed gate
#

does anyone know how to fix this?

analog plover
#

Expand the middle error and show the full message

civic smelt
#

Guys, I tried to send live notifications from using "Firebase" to my Unity App. ı dont have any console error or Firebase errors, but I cant send notifications to my android device. Who has an experience about this situation ?

hexed gate
plucky skiff
hexed gate
#

so can i update the current version of unity and still keep the progres?

#

and hpw can i export gradle project

#

how*?

plucky skiff
hexed gate
#

that might be too mutch for me to comprehend

somber orchid
#

I can't install apks built with target api 31 -33 in android devices, it works fine in versions below., i tried some solutions but doesn't work, i going to install unity 2022.2.1, in this new version is the problem solved?

fallen compass
#

Set the 'Target API' as "Automatic (highest installed)"

terse quarry
#

Hi! How to make button movement top down 2D smooth when ponter enter?

glossy sluice
#

How can i solve?

rustic ermine
#

Do you absolutely NEED the latest xcode (14) in order to publish an IOS app to the app store? Or will xcode 13 be enough, and be able to build apps for the latest IOS versions?

tired lily
#

13's enough (for now)

hallow hawk
#

does anyone know if GfxDeviceGLES::InsertPluginTextureUpdateCallback(void (*)(int, void*), UnityRenderingExtTextureUpdateParamsInternal&) is ever invoked for non-plugin (internal unity) uses? I'm trying to track down a set of crashes and I've noticed some of them seem to have this in their stack trace and am wondering if perhaps it could be some kind of plugin? that said, I only see libunity.so and gles calls above it

proud urchin
#

hey do i have to show the local currency icon near the price tag for in app purchases?

#

or can i just show the price amount without currency?

#

like this:

sleek eagle
#

Gotta look for localization packages I guess @proud urchin

old shoal
#

UI is not activating in android initially , it only activates after the player collides with something

#

how to fix it , it works fine in pc build and editor , but this issue happens in android build

sleek eagle
old shoal
fathom seal
#

Imagine me, I have an Issue that has taken me 20+ hours and made no progress at all

#

If anyone wants to help here it is (Is a 2d platformer), any single movement in my android build has a stutter each 3 - 4 seconds but it can be without it for ~15 seconds it happens in a even a new project, It is not exclusive to physics. I have an fps counter and it seems pretty stable 58-60 fps. A square moving by translate using deltaTime, and you can see the "micro jumps". With the player moving using physics same, it is even more visible because of the camera.

#

Is the kind of thing "You just have to check this box'' solution but I'm pretty sure it is not that simple, I've tried almost everything inside my comprehension and people's internet comments

#

so if anyone has had this issue and solved it please, pleaseeee help

#

Thanks love to everyone

#

I've tested it on PC and some android devices it has only happened on those

tired lily
#

What does the profiler show you?

#

At first glance it sounds like GC to me

fathom seal
#

You have no idea what just happened

fathom seal
tired lily
#

garbage collection

fathom seal
#

I also thought that

#

but

#

God came to me and told me

#

almost but thats not true

#

set the target frame rate to 61

#

solved

wild spruce
#

i am getting these errors , please help

wild spruce
#

none of them worked

#

any help would be greatly appreciated

tired lily
#

did you read any of the errors?

wild spruce
#

if i dont check the release option , it doesnt give the txt and zip files for play store and if i do check it , it gives errors on build again

#

if i uncheck release , it builds without errors

coral rain
#

hello , i did share a build of my android game , however , it shows as harmful file

#

is there any reason to stop that , i'm not gonna publish is in playstore but i'm gonna publish it in TapTap and Itch.io (i litteraly dont have the money for google play console)

neon thicket
#

Side loading an APK outside of an official store will show that warning.

coral rain
forest tide
#

My game fps is so low on mobile, like 25~40 frames with drops . what to do ? 😦

sleek eagle
#

Run the profiler @forest tide

forest tide
#

How i would know what makes fps low when the game is on mobile

#

It does run good in editor

sleek eagle
#

PCs are faster than phones generally and phones have tiled GPUs

#

Run the profiler to get more insight and apply optimization techniques and get the settings right

#

Without a lot of info or access to the project it's almost impossible to help with performance for an outsider of the project

forest tide
#

I'm making an infinite runner game like , so i don't think that i can use occlusion culling or baking light so i'm left with realtime lighting and using LOD alongside with combine meshes

sleek eagle
forest tide
sleek eagle
#

Woah no, turn off static if something moves

#

That's for static (stationary) objects

forest tide
sleek eagle
#

Huh?

#

Read up on static batching and dynamic batching

#

If something moves, use dynamic

tired lily
#

your description sounds like a proguard issue

sacred creek
wild spruce
#

so i built it without checking the release option , it built fine then

#

thanks a lot still

rain leaf
# forest tide I'm making an infinite runner game like , so i don't think that i can use occlus...

yes, you can bake light even on prefab and use it on non stationary (moving) objects.
someone even has made a package for it (while, I need to manually bake and script it in the past..)
https://github.com/nukadelic/unity-lightmap-prefab-baker

GitHub

Unity Light Map Prefab Baker. Contribute to nukadelic/Unity-Lightmap-Prefab-Baker development by creating an account on GitHub.

tribal ember
#

hi, im trying to make a player move by a joystick but also jump if it touches the screen. But when the joystick is being moved by itself the player should just be moving but unity reads it as a touch input and makes the player jump constantly. is there any way to write a simple if statement to make the joystick exclusive from screen touches?

#

nevermind i fixed it

cosmic prawn
#

Anyone with experience in working with the Playfab SDK here?

lime vessel
nova imp
#

why doesn't it work?

PlayerSettings.SetIl2CppCompilerConfiguration(BuildTargetGroup.Android, Il2CppCompilerConfiguration.Release);

Change Mono to IL2CPP
It is still Mono

hexed gate
#

hi how do i adapt the resolution of a game to fit any screen and look normal?

sleek eagle
hexed gate
#

?

hexed gate
#

ty

sleek eagle
#

Just google unity scale canvas with screen size

#

Also many videos

hexed gate
#

yoooo it actually dosnt look like shit now :))

#

you re cool man

fallen compass
#

Always use the device simulator too, not the game view, when working with mobile

rapid sun
#

Hi All, I hope this is the right place to ask this but I'm having some problems with my FPS when building and running my game on android. Everything works fine on my PC, so I decided to run the profiler while running the game on mobile and everything is running around 1000FPS which is great, except the VSync under CPU Usage is causing my game to drop to like 15 FPS. And when checking what parts of the game are using the most CPU time I get TimeUpdate.WaitForLastPresentationAndUpdateTime. I don't understand why VSync is causing this issue because I turned it off in Settings>Quality. I'd really appreciate it if anyone knows what's going on

sleek eagle
rapid sun
#

That's a shame. It's a really simple 2D pixel game that I'm running with no shaders, lighting or any fancy so I don't see why that would cause any issues for the GPU. I've also tried lowering the compression quality of my images but that doesn't improve anything

sleek eagle
#

Correct, compression is just how much storage and/or ram it uses.
Without more info I cannot help much, but maybe look into texture atlassing if it's a 2d game. That way you could decrease the amount of draw calls

rapid sun
#

By that do you mean store all my sprites in 1 image? Because that's pretty much what I'm doing. All the assets are in a single sprite atlas for each level and I just tell unity where each individual sprite is in the atlas

sleek eagle
#

Then check the frame debugger. To see how many draw calls you got

#

Should be a small amount for mobile games

#

And check stuff like post processing

rapid sun
#

Thanks for the link man. I'll check that and the frame debugger out

sacred creek
rapid sun
#

It's from my mobile device

sacred creek
#

Are you setting the app to a framerate target at some point?

sacred creek
rapid sun
#

Where could I find the "GPU part"?

sacred creek
#

at the same spot as your CPU part you screenshot

#

Rendering its called

rapid sun
#

On the overview part I get GPU:--ms and under rendering I get this

sacred creek
rapid sun
#

Yeah which is why I'm confused that it seems to be a GPU issue

sacred creek
#

Does your game feel as laggy as the profiler shows?

rapid sun
#

Yeah, but most of the game is static. It's only when a scrolling animation happens when changing levels, and when clicking on an object that opens a UI dialogue that things start to feel lagy

#

For my moving animation I'm using Vector3.MoveTowards and I'm multiplying my speed by Time.deltaTime. As for the UI most of it is already instantiated but disabled and if I ever need to allocate some new resources I use an Object Pool design pattern. So going from PC to mobile shouldn't really cause any lags

sacred creek
rapid sun
#

Yeah I set it to 0.016667 or something like that, basically 60fps

sacred creek
#

Well, try to remove that line and test again. Maybe your device just cant handle it?

rapid sun
#

I tried setting it to 1/120 and 1/30 as well but that made no difference

sacred creek
#

Hm okay

#

What renderpipeline are you using in your project?

rapid sun
#

I haven't done anything with rendering pipelines. This is pretty much just a new unity game built of the default 2D template

sacred creek
#

What device are you testing on?

rapid sun
#

One Plus Nord with a snapdragon processer and 90Hz refresh rate

sacred creek
#

That should be fast enough. Maybe try another version of unity, backup your project first. But such a simple project does not sound like the actual issue.

rapid sun
#

Thanks. There is a new update for the Unity editor that's just released so I'll update to that. And I'll check out the link when I get back to work tomorrow 👍

sacred creek
chrome flax
#

Did you try the snapdragon profiler to measure gpu work loads

lucid lintel
#

What are the best practices for collecting gameplay data in real-time?

Some options I'm considering:

  • PlayerRefs to batch then send chunks over the wire as .json
  • Send over HTTP and retry failed sends
  • Maintain a TCP connection during gameplay to live-feed data
rain leaf
#

analytics?

iron hatch
#

does anyone know why Application.targetFrameRate = 120;
Locks the fps at 90 when my mobile has 120hz display with 18gb ram? (I am doing in a empty scene no way there is bottleneck for cpu or gpu) Is this a unity issue or is there another setting I need to change?

neon thicket
#

@tawdry scaffold Don't crosspost in the future. This isn't a coding question either, but seeing as it's already been discussed, leave it in #💻┃code-beginner.

neon thicket
#

Yet it's continued in #💻┃code-beginner. The point is, you discuss your issue in one channel. If you move, then actually move the conversation.

sleek eagle
arctic marlin
#

I still search for a possibility to build my Unity 2D Game for the Rasperry Pi (Linux ARM)

#

Is there any addon or mod for Unity to get a build option for that?

sleek eagle
arctic marlin
sleek eagle
#

Yep same

#

You can post on the forums and maybe it gets seen and reconcidered.
Also add a comment on the platform support roadmap

arctic marlin
#

how hard is it? many peoples mean it would not be that hard to change the backend export

echo beacon
#

Hello, one question, how can I open a map app to see a route? For example, if I have a label with a route that when pressed opens it, if I can open it with Maps, Google Maps or Wise, this is for IOS.

tired lily
#

url scheme or universal links

echo beacon
#

Oh, do you have an example of this? I've been looking all week and I haven't found something that does the same for me. A selector appeared to see which app I open the route with.

ocean niche
#

Has anyone here managed to get Cloud Save working with Google or iOS authentication?

#

Any time I import the google play plugin I'm getting build errors for android.

tired lily
# echo beacon Oh, do you have an example of this? I've been looking all week and I haven't fou...

there is some documentation: https://developer.apple.com/library/archive/featuredarticles/iPhoneURLScheme_Reference/MapLinks/MapLinks.html#//apple_ref/doc/uid/TP40007899-CH5-SW1 https://developers.google.com/maps/documentation/urls/get-started https://developers.google.com/maps/documentation/ios-sdk/urlscheme
You might not be able to do anything about the selector if there are multiple apps that can handle the scheme. I thought on iOS, it was always the first installed app but my memory on that is a bit fuzzy

echo beacon
#

oh okay I will prove this links ,thanks for anything

stark quartz
#

Hey guys, I've been trying to have IAP on iOS for hours (got it working on Android, it's also working in editor with iOS target).

I get this in Xcode:
AP Exception catched: Unity.Services.Core.ServicesInitializationException: You are attempting to access UnityServices.State from a non-Unity Thread. UnityServices.State can only be accessed from Unity Thread

I suspect it is because I'm using an async void to initialize IAP (it's called by the Awake function):

async void Initialize(Action onSuccess, Action<string> onError)
    {
        Debug.Log("Initializing Unity Gaming Services");
        try
        {
            var options = new InitializationOptions().SetEnvironmentName(environment);

            await UnityServices.InitializeAsync(options).ContinueWith(task => onSuccess());
            onUGSInitializedDelegate();
        }
        catch (Exception exception)
        {
            onError(exception.Message);
        }
    }

This initializes UGS, then calls a delegate that initializes IAP. I've been trying many ways, but I can't find another way to init IAP after UGS (and if I don't wait for UGS to be initialized, I get an error too).

#

I've also tried initializing IAP in the onSuccess callback, but I get this error:

UnityEngine.UnityException: get_persistentDataPath can only be called from the main thread.
Constructors and field initializers will be executed from the loading thread when loading a scene.
Don't use this function in the constructor or field initializers, instead move initialization code to the Awake or Start function.
  at (wrapper managed-to-native) UnityEngine.Application.get_persistentDataPath()
  at UnityEngine.Purchasing.UnityPurchasing.Initialize (UnityEngine.Purchasing.IStoreListener listener, UnityEngine.Purchasing.ConfigurationBuilder builder) [0x0001d] in /Users/user/Documents/Unity/Projects/Kurv/Library/PackageCache/com.unity.purchasing@4.5.2/Runtime/Purchasing/UnityPurchasing.cs:24 
  at IAPManager.InitializeUnityPurchasing () [0x00027] in /Users/user/Documents/Unity/Projects/Kurv/Assets/Scripts/Services/IAPManager.cs:35 
UnityEngine.Debug:Log (object)
IAPManager:InitializeUnityPurchasing () (at Assets/Scripts/Services/IAPManager.cs:38)
InitializeServices:OnSuccess () (at Assets/Scripts/Services/InitializeServices.cs:64)
InitializeServices/<>c__DisplayClass5_0:<Initialize>b__0 (System.Threading.Tasks.T
#

Im sure there is a simple way, but I can't find it

stark quartz
#

Alright so I initialize UGS in awake, and IAP in Start, it seems to work. However, on my iOS device, I get: UnityIAP: Received 0 products
I have a sandbox setup but it doesn't work

foggy pier
#

anyone been having loads of crashes from there GP console with this error
JNI ERROR (app bug): global reference table overflow (max=51200)global reference table dump:
the stack trace always ends in libc.so but also a lot of libart.so in it

rotund dome
#

Any idea why I get these random spikes? Happens like every 15-30 seconds, cant' figure out the reason (Deep Profile on Android)

foggy pier
#

if i had to make a guess its the garbage collector

rotund dome
#

Gfx.WaitForPresent --> The main thread is ready to start rendering the next frame, but the render thread has not finished waiting on the GPU to Present the frame. That's what it indicates, but why does it happen once in a while, and it's not actually happening every frame?

rotund dome
#

Then the garbage collector graph should show something, am I wrong?

foggy pier
#

i was just guessing that from the spikes of GC allocated every few frames

#

though would put the cursor right on the spike and see what is going on in the player loop

rotund dome
#

Yes, yes, I also have when into that, and reduced a lot, jump is still creates garbage though

rotund dome
#

In terms of garbage, I'm using a pool and caching everything reasonable, so garbage as I have profiled is like 0.6kb every jump, everything else is garbage free, idk if it's a lot

#

The jump is triggered often, like once every 1-2 seconds

#

So, the garbage collection happens 3 frames before the big spike

#

I'm not sure if it might be the reason, like I'm aiming for 16ms, so 0.39ms shouldn't be much, compared to that other spike in rendering produced by gfx.waitforpresent

arctic marlin
#

I took my Raspberry Pi and installed Windows 11 ARM on it, then I compiled my 2D Unity Game for Windows ARM, but I always get a "Failed to load Mono" Error Meassage, if I try to run the .exe

tender summit
#

hey guys

#

build completed but installation failed

#

any ideas?

tender summit
#

apperantly is the build tools

#

so

#

i see

#

i have a bunch of them

#

do i need them all?

#

can i delete anything under 30?

#

i dont think ill be using them

lapis badge
#

I downloaded androidNDK file externally from browser and idk where should I move it into the file..its showing missing in the external tool

brazen birch
# tender summit apperantly is the build tools

You didn't show the full error message.

But my guess is that it is either missing build tools or can't find them. Unity and Android can struggle with things in non-english folder paths.

Anyway, so it sounds like Unity can't find files - and your fix is to delete more? Those SDKs are installed via the Android SDK installer and we're added by projects that had a different min SDK setting.

Delete them if you like but I'd expect that to break things.

stark quartz
#

Hi 👋 My IAP localization keeps being rejected in App Store Connect, I don’t know why (I have no details from Apple). Did anyone have the same issue ?

tribal ledge
#

I am wanting to use my app in popup/split screen view, but when put into popup view and minimized (into the little circle tab) it keeps crashing. Any idea why? And am I able to prevent that?

rain leaf
pulsar isle
#

should my canvas scaler be set to match width on locked portrait ?

rain leaf
#

depends on your UI design

woven marlin
#

Hi hi
I just successfully build my apk through my unity editor on laptop
Then i uploaded it to google drive
But once my smart phone downloads it. It doesn't installed automatically

#

And i can't find it on my directory

#

Once this done just nothing happen and there are no trace for my apk

sleek eagle
#

Maybe download from the gdrive app instead of link @woven marlin

woven marlin
#

Oh i just split 64 and 32

sleek eagle
#

???

wispy bronze
#

My built APK won't launch and just crashes immediately instead. I got this issue only after I installed the Google Play Games Services plugin in to my project. Does anyone know what to do about this?

sleek eagle
#

Check the logs @wispy bronze

wispy bronze
#

The logs? Like in Android Studio or something?@sleek eagle

sleek eagle
#

I don't use android studio.
If you use build and run and enable autoconnect profiler you can see logs etc in unity (even without debug build you can see the logs with logcat)

wispy bronze
#

Thanks for the advice! It seems it's an gradle issue. Hmm...

sleek eagle
wispy bronze
#

Ughhh, tbh honest I didn't pay attention too much lol

#

I deleted my plugin, I want to know the difference without it

#

And then I will download it back

rapid sun
# rapid sun Hi All, I hope this is the right place to ask this but I'm having some problems ...

I know that this was quite a few days ago but I finally found a fix to my problem and thought I'd share it here just in case anyone is dealing with the same issue. After trying different frame rate values in edit>project settings>Time nothing worked, but once I set the framerate to 60 using Application.targetFrameRate and replaced Time.deltaTime with Time.fixedDeltaTime everywhere it fixed my issue and everything now runs supper smooth

heady bluff
#

How do i only get one value out of the gyroscope?

glossy sluice
#

Hello friends, i build an apk as a bundle of google it‘s just white file on my imac. So what do i have to do to upload on google store?

wispy bronze
#

@glossy sluice Thanks, I fixed this about a day ago😁

tranquil scarab
#

So with the Unity Starter Assets FPS Controller I got the FPS Controller in my game, and on my smartphone.
But the Move sprite to move around forward and back, stays in place where it is, and so does the look pad sprite.
I noticed from Playing Call of Duty Mobile that the move sprite, and the look pad sprite appear anywhere on the screen depending where you place your finger on the screen, on your smartphone.

Can you adjust the settings on the FPS Controller in the Inspector panel to make the sprites appear when you place your finger on the screen instead of the move and look sprites being fixed in one place on the screen, like a joystick float
If not is this something that has to be coded in C# for the sprites to appear on the screen when the player presses their finger on the touchscreen on their smartphones?

https://youtu.be/dAdYlDvEHUY found this

https://youtu.be/TPzOgMfoCGY in this YouTube video a guy called Hoosan talks about what I am trying to do at 3:55 in the YouTube video, he talks about Add Event to make the sprites move to a specific area on the screen when
the player presses the touchscreen.

I have been on this problem a loooong time and I am worried that I cannot do it, can anyone help me?

I want to explain to you how to make a fixed and floating joystick
.
.
ACCESS PROJECT FILES & SUPPORT THE CHANNEL:
https://www.patreon.com/unitycity
.
.

Please Subscribe for more videos:-https://www.youtube.com/channel/UCvOVDwdcBwioZn8km2DXd6g?sub_confirmation=1

Twitter:- https://twitter.com/city_unity
Facebook:- https://www.facebook.com/UntyC...

▶ Play video

In this unity tutorial, you'll learn how to make a joystick touch control for our player movement in a 2d top-down game.

Touch control is an important component for mobile games. We will first add our joystick UI into the game and add a C# script to it. The script allows the joystick to move to the position of the user touch and return back to...

▶ Play video
tranquil scarab
#

hi

austere summit
#

Does anyone knows whats causing this? Im using the unity generated manifest file.

novel hill
#

How can I drag the screen on mobile?

#

I have a top down game that I control the camera with wasd on pc, how can i drag the screen on mobile with touch controls

#

also pinch to zoom in and out

vague pilot
#

Also another question why is my small game so big when I bulid it and my project like 10GB

glossy sluice
#

Hello friends, i build an apk as a bundle of google it‘s just white file on my imac. So what do i have to do to upload on google store? Please help

neon thicket
#

Upload it to Google Play like normal?

sleek eagle
#

Depends on your project. Some script is turning it off

sleek eagle
stark quartz
vague pilot
ivory turtle
#

Trying to get my game running on an iphone with unity remote 5 (I'm using unity on windows). Unity does find the phone and I have Itunes open which also finds it. I already managed to get the game run on my phone once, but ever since then it did not work again for some reasons. I am getting this message that I don't understand and it might be the reason but idk. Any help would be appriciated.

vague pilot
ivory turtle
#

are you refering to that box that pops up asking me wether or not I trust the pc?

glossy sluice
#

Hi, how to fix this problem?

ivory turtle
# vague pilot yea

Well whenevr it did pop up I said trust but recently it has not popped up again

vague pilot
vague pilot
ivory turtle
floral light
#

Hi, trying to finish my 1st commercial game and I can't pass the build point so I can upload it to google play for the testing phase.

If I lower the targeting API level from minimal 24 to target level 30 the build completes with no issue, but google play does not allow any app below target level 31.
Build fails when targeting API level 31
I'm using Unity 2020.3.2f1 and installed android SDK build tools 30.0.3 with Android Studio SDK manager.
In publishing, settings:
enabled AndroidManifest.xml and added: "android:exported="true" in the activity section.
enabled LauncherTemplate.gradle and specify "buildToolsVersion '30.0.3'"
enabled MainTemplate.gradle and specify same "buildToolsVersion '30.0.3'"

I also tried opening my project with a newer unity version 2020.3.25f1 but then I get over 650+ compiler errors. So this is a dead end.

I am stuck here I need help 🥺

glossy sluice
#

Hi, trying to respawn my player after he dies. It works fine and the player respawned but isn’t visible again why?

sleek eagle
sleek eagle
vague pilot
glossy sluice
glossy sluice
glossy sluice
#

Hi again, so I need to upload my game on google play store but first I have to upload url with my data. I don’t have this. Any advice?

bronze aurora
#

Hello there
I've been getting this error for the last 2 days now, I'm trying to build .aab file for my game to be uploaded to the Google Play Store. I've checked on YouTube and have corrected the key passwords, but I'm still getting this error. Please help me, I'm pulling out my hair!

split dew
#

guys what is this? I mean, of course everyone would want their game to be of high quality then why is this meter/checkbox?

I am making an android game (it's just a small 50mb board game satisfying) so should I make the android quality as ultra?

sleek eagle
sleek eagle
# split dew *guys what is this? I mean, of course everyone would want their game to be of hi...

You can remove the ones you don't need. For me with VR I have 1 preset for quest 2, 1 for pcvr medium and 1 for pcvr ultra.

Higher quality presets are heavier to run and certainly not all devices can run on ultra. A game shouldn't run at 15 fps on ultra if it looks the same at low but at 60fps. Make sure that if you pick one for android you still disable all the features you don't need (like realtime reflections etc)

split dew
sleek eagle
#

Just go though what's there and see if you need it and run the profiler when you build to your device

split dew
#

whats profiler?

#

got it

bronze aurora
#

I'm guessing it has to do with the Advertisement Legacy Package?

sleek eagle
#

I think so yeah. At least something ad related @bronze aurora

glossy sluice
#

Hi again, so I need to upload my game on google play store but first I have to upload url with my data. I don’t have this. Any advice?

#

Where can I get it?

glossy sluice
#

Hi, i have a question, why after implement AdMob my app build start crash

tired lily
#

look at logs, could be a lot of things

bronze aurora
#

I just had to delete everything relating to Unity Ads and the Ads package

#

I guess I'm going to have to monetize my game using Unity Ads with Mediation, so if anyone has any videos on that that'd helpful lol

bronze aurora
glossy sluice
#

Hi again, so I need to upload my game on google play store but first I have to upload url with my data. I don’t have this. Any advice?

tired lily
pine moon
#

Hoping for someone to help a bit on my question: So I have a touch screen computer. Does Unity's Game Testing Window just not recognize touch screen commands for testing out touch screen coding when making a mobile game?

tired lily
#

they might be interpreted as clicks. Unity remote is normally how I test device controls/sensors in the editor

pine moon
#

Actually, is there any way I can bother you with clarification on the encoding to using a touch screen to "tap" an object in Unity? Since you seem to have experience in that.

tired lily
pine moon
#

I read that touch screen controls are no longer synonymous with mouse clicks as of 2019. Before 2019 you could just click "get mouse down" and a tap on a touch screen would also be read as the same thing

#

now apparently I need to encode "touch screen controls" to get a simple screen tap

#

and I won't lie I've been struggling.

#

I tried doing this to one of my objects, but either it didn't work or Unity's testing window doesn't detect taps. If this is correct code pls let me know:

void Update()
  {
  if (Input.touchCount > 0)
  {
  //do something here.
  }

}
#

if that syntax is correct then I guess I only thought it wasn't because I wasn't testing it properly. As I said above I don't know anything about Unity Remote

tired lily
#

are you using Unity remote to test now?

pine moon
#

nope, I actually need to learn more about unity remote

#

is that syntax correct if so then YAY I just need to use unity remote

#

OH so I download Unity Remote on my phone?

tired lily
#

if you're testing touch controls specifically, yes. Otherwise use Input.GetMouseDown and make sure Input.simulateMouseWithTouches is true

pine moon
#

Oh

#

Input.simulateMouseWithTouches is something that is new to me. Ok so where do I make sure that is true?

#

ok so then I am probably doing ok with my game - and the touch control probably works then is what I'm gathering, I just apparently didn't realize the regular unity interface doesn't allow for my touch screen monitor to test touches

tired lily
#

if you didn't disable it, it should already be true. But that would be one reason you wouldn't be able to use mouse down, if you were reading some kind of guide that had you shut it off

pine moon
#

No, I just read a news report with a Unity Website that said "Unity is disabling all touch screen inputs with the Mouse as of 2019. When you program mouse clicks they will no longer be the same as touch inputs afterward. You will have to encode touch inputs to make them work with the game from here on out."

tired lily
#

maybe the editor just doesn't like touch screens. I'm surprised it doesn't work if you switched to OnMouseDown and see nothing though

pine moon
#

I'm using this code: if (Input.GetMouseButtonDown(0))

#

should it be Input.OnMouseDown then?

tired lily
#

your website is probably wrong then, as I'm using OnMouseDown and similar in a number of games on 2021.3.11f1 and it works fine on mobile

pine moon
#

oh thank god

#

so I don't have to worry about extra encoding

#

but wait is GetMouseButtonDown not the same as OnMouseDown?

#

if it is the same then I won't worry

#

if it isn't then I have to fix that code

tired lily
#

they should be similar. Why not make a local build and test it?

pine moon
#

I will just I can't right now, I have a blazing migraine and I spent 3 hours last night worrying over that website talking about something in 2019. Apparently a few youtubers believed the same thing. but if it still works as it used to then they must be on crack or something.

#

that worry is taken off my shoulders, tyso much man!

#

or woman

lime violet
#

Trying to use the unity mediation (ive used it before and worked fine) but now on the code generator im getting this

#

on the unity dashboard, ads are enabled

#

also shows the ad units under the ad units tab but for some reason the code generator says there are no ad units

floral light
#

First of all, Happy New Year to you all!
My original post: #📱┃mobile message
So this is how I solved it:
Jumped from 2020.3.2ff1 to 2020.3.43.f1 and opened the project and found 797 errors.
almost all of them were conflict files for plasticSCM.
Since I use version control I roll back to the 2020.3.2ff1 version and delete all plasticSCM from the project, I didn't use it. I used GitLab with LFS. switched back to 2020.3.43.f1 dropped down from 797 to 54 errors.
Did the same thing again with the IAP-purchases package. Commented on all scripts that used their libs I plan to import it back but for the new 2020.3.43.f1.
After the IAP-purchases package was removed opened it again on 2020.3.43.f1 with 0 errors.

Build settings selected a minimum lvl24-API to target lvl31 and the build pass was clean with no errors(this step was impossible in 2020.3.2f1).

Uploaded the app bundle to google play with no errors and now I'm in my closed-testing cycle.
Problem solved.

Thank you @sleek eagle You were right! When you said "The compiler errors might be an easier fix then you think".
Thank you @vague pilot upgrading the project to latest 2020 LTS was the solution for me after all.
Thank you @glossy sluice the steps you provided did solve the issue but I also needed to use a different Unity version.

heady bluff
#

using a gyroscope, is there a way to get the rotations of it before the game starts? i have to prop it up at a perfectly 90 degree angle as the project is loading for it to display the correct measurements

sleek eagle
heady bluff
# sleek eagle Awake runs before showing anything on screen. Start is before the first screen i...

i understand how the start method works. Looking back at my first message, i worded it horribly. I intended ask how i would get the values in the gyroscope to display in the start/awake method. Unity seems to set the rotations on the gyroscope as 0,0,0(on start or first frame of the update) no matter what rotation the gyro actually is. due to this i need to prop the phone at a perfect 0 degree angle to correctly display the values. i no longer want to do that because there is lots of possibilty for error

sleek eagle
#

Otherwise im not sure, maybe make a forum post if no one here knows

brisk maple
#

I'm trying to test my game on my device using unity remote, but it does not show up under the devices tab, anybody know how I could fix this?

#

anybody can ping me if they know what to do

glossy sluice
floral light
# glossy sluice My friend i have a question too. If you want to upload an aab to google you have...

Yes, I did provide a privacy policy. I did exactly as @tired lily replied to your question earlier.
"1. create a privacy policy
2. upload the privacy policy to a website
3. paste the url to your privacy policy into that box"

My app is in "in review" status and I still don't know are my steps correct.
Google provides all users with feature "sites" there I created my privacy policy. When you write your privacy policy you publish it on google sites and you get url for your new public privacy policy page. Copy url and paste it in the "der datenschutzerklarung"

If my game becomes approved only then I can be sure that this step solves the privacy policy request.

I first wanted to run the closed testing for my game so I can find early bugs before I launch the game.
When you create a close testing cycle you need to provide the list of testers. The list of the tester is an e-mail list of people who will get this e-mail notification when your game is approved. So they can see and download the game from the google play store. Nobody else can see it or download it.

serene osprey
#

I don't really know if this belongs here but I can't find a channel that really fits my problem, I'm working on a map for a vr mobile (oculus quest) scene and I need to optimize my scene as it has too many polys for the quest1. I found an addon called "mesh optimizer" and decided to use it. I have about 70 pine trees that need optimizing and the script that came with the addon has an optimize button that I need to click so that the polys get reduced. Multi object editing is not supported by this addon and that would mean that I need to press the button for every pine tree in the inspector. Is there any faster way to do this?

glossy sluice
floral light
fair stream
#

Hello there

#

I'm trying to set Unity ads

#

But sounds like my Unity ads are not displaying

#

How can i fix this problem?

#

(I'm trying to put Unity ads in Gamemaker anyways)

glossy sluice
fair stream
#

Any help/attempt is appreciated

tired lily
haughty mantle
#

Hello, I try to implement deeplinking on android, I follow the tutorial https://docs.unity3d.com/Manual/deep-linking.html, the deeplinking works if the app is not already launched, but if the app is in background, the deeplink launch the app and the app froze on the main scene.

tired lily
#

sounds like you have an infinite loop somewhere

#

do you open the url you receive at any point?

fringe sparrow
#

has anyone used ironsource service for mobile ads? I got sent an email from "mobile-support-is@ironsrc.com" requesting that I send them bank info "Account number and Routing Number" to their email. But I am scared since I have never done this. Is this how its normally done?

fringe sparrow
#

thank you

haughty mantle
sharp smelt
#

Guys, I'm trying to upload a android build to Google Play. All is fine but I get an error saying that the included Play Billing library version is unsupported. We dont have IAP in the app at all so I'm wondering why is unity building it into the aab at all. We havent even enabled the iap package or anything.

haughty mantle
sharp smelt
#

I'm suspecting that the In App purchasing package that is installed by default is putting things in the build by default

sharp smelt
#

Can confirm, the IAp package was doing it. Even when IAP was turned off in project settings

tribal ember
#

hi, im trying to build into ios through xcode, but i keep getting this error. Anybody know what to do?

floral light
# glossy sluice Hi, does Google answer yet?

I got App rejected, reason is data safety section in Google Play User Data policy: Invalid Data safety form...I need to fix this but I'm not sure where to start. I only store players' game progression and purchase items on users' devices. And the user can take a screenshot from his game(no personal information in the image) and share it on any social network.
Anyone have any ideas on how to solve this?

tired lily
#

did you fill out the data safety form?

floral light
# tired lily did you fill out the data safety form?

Yeah but I guess somewhere in all this process I made a mistake and I trying to figure it out. The thing is I'm seeing this and doing this for the first time so it's kind of normal to make so many mistakes, I just want to make it right 😄

tired lily
#

you might have made some claim that you don't know isn't true, for example saying you don't collect gaid but actually due to IAP you do. Something like that can get you rejected

floral light
bronze aurora
#

I DONT KNOW HOW TO FIX THIS AND I WORKED SO HARD ON THIS GAME TOO

#

Please help me 🙏

glossy sluice
tired lily
#

what is there to solve? provide a valid data safety form. Probably an automatic rejection based on app behavior not matching claims

mortal cove
bronze aurora
#

I think I figured out your problem.

#

I had a similar one

#

But basically

#

Once I edited that, I sent the app to be re-applied and they accepted.

hard blaze
#

greetings. Trying to upload an aab to google play store. It gives me a message that my target API needs to be at least android sdk 31. But, when I choose that in Unity, it says its not installed.

I tried downloading android studio, and redirecting Unity to the installation. But gradle now fails on all builds.

So, I tried upgrading project from 2020 to 2021 (hoping the build in Android SDK allows for targeting 31), but google play still rejecting, saying sdk needs to be at least 31

Edit: Solved by having android studio targeting the android install in Unity and installing api 30 and 33 (i skipped 31, because heard there were issues with it)

narrow ice
#

Hey, Im having an issue with unity ads and im not for sure how to fix it

#

Anyone have any idea how to fix it?

#

Its nothing in the code that isnt working. I added this package to unity and its saying it can find ANDRIOD_SDK and JAVA_SDK

lost rose
#

Hello, In android build, TMP input field do not show the blinking cursor on being selected/checked why is that and how can I enable blinking cursor on select

rustic prism
#

How can I fix this blocky light to be smoother ?

small sierra
#

im trying to make a mobile app for the first time for a school project and im wondering if i would be able to use unity to make the app?

#

i know it would be possible but im mostly wondering about any issues i could face in the in the future if i did

sleek eagle
sleek eagle
rustic prism
sleek eagle
rustic prism
sleek eagle
rustic prism
#

@sleek eagle Other example of the lighting being blocky. The more detailed one is on the editor the other one on the phone.

sleek eagle
sleek eagle
#

Can you also show the matrix at the top with the checkmarks?

sleek eagle
#

Yep, android has a lower preset as I said

#

It's at balanced (green check)

rustic prism
#

oh alright, how can I change that green check?

sleek eagle
#

Arrow at the bottom

#

Or remove the unused levels altogether. Will also save build size maybe?

rustic prism
#

that was the fix..I'm cracking my head on it for hours

rustic prism
sleek eagle
#

Glad to help :p

rustic prism
# sleek eagle Glad to help :p

Just want to ask is there a way for me to achieve the same level of details in the lighting without it effecting the performance so much?

sleek eagle
#

Probably other places you can optimize more. Even on quest 2 I got 4k res shadows working

#

If possible baking it will do wonders tho, but idk your game

#

Optimization is hard to help with without the project

#

Will make a video on URP settings as well

rustic prism
#

Thanks I will look at that now

rustic prism
#

A fix for people who encounter the same problem and the performance is still an Issue, If you want to get better shadows just change it in the pipeline that is in charge of the level you want.

sleek eagle
#

Or optimize the high performance one (;

#

Also disable SSAO if it's on. That and bloom is massive

#

In the URP renderer for that asset

glossy sluice
#

Is there a way to open the Itunes library and import MP3 files during runtime?

split dew
#

Guys my game hangs a bit or fully glitches when kept not playing (or touching the screen) for a minute. sometimes freezes. It's just 25mb size. Why? What to do?

fallen compass
#

... profile it to find out why

amber matrix
#

Hello All. Im added google play services plugin in my game and unity resolving self. And resolving stays like this. Not continue resolve. Please anybody help me that how can solve this problem ?

tired lily
#

if no obvious issues in console, enable verbose logging in EDM4U and try again. Uncheck use gradle daemon in EDM settings

amber matrix
tired lily
#

how old are the instructions? the literal top hit on google for PlayGamesClientConfiguration is that it's not used any more

tired lily
#

yes what? If you are following the instructions, where does your code come from?

amber matrix
#

And what should i use instead PlayGamesClientConfiguration ?

tired lily
#

you should follow their code example linked in that same page instead of wherever you are getting this old deprecated stuff from

marble sinew
#

Hey People.

Just to make it short:
We got this project that includes a level editor within it, and we wanted to allow players to share and export their own levels, I know we can include an import/export system to open the levels within the game itself but (with the project manager's suggestion/insistence) I wanted to know the possibility of building an APK from an already built app; so we can export the player-made levels as a separate build/APK and share it that way.
This might not be possible due to the compiler being on the engine and such, but is it possible via native android libraries or other options ? searching doesn't bring good enough results for me.

Thanks in advance.

tired lily
#

go with option 1, option 2 is insane and has no practical chance of success

marble sinew
glossy sluice
# bronze aurora Hey

So if I use google sites to create a website for my app and data legitimation. So, next to my main job as a normal worker I need to build a side business for paying taxes later, right? I’m case I earn an amount of income monthly I have to pay taxes rift? But just in case of money come in right?

floral light
#

I have a localization issue.
I'm using TMPro and I have downloaded the "NotoSerifAllContinent" font for my translations of French, Spanish, Russian, German, and Croatian and this works fine.
But the issue comes when I switch to Japan, Korea, or Chinese.
Some of the symbols cant be found in my fallback assets list ("NotoSerifJP", "NotoSerifKR", "NotoSerifCJK")settings.
I used google translate to create the translations.
How to solve these missing symbols?

arctic marlin
#

Hello, Is it normal right now, that Windows ARM Builds doesen't work on Windows ARM?

#

I can find nothing about that in google, this discord and even the Unity Forum.

sleek eagle
#

Oh do you mean as export target or for the editor?

#

2023 has it as export

arctic marlin
sleek eagle
#

And maybe try il2cpp

#

Iirc mono had issues and il2cpp did work

arctic marlin
#

il2cpp made a Compiler error I think

sleek eagle
#

Then fix that :p

arctic marlin
#

but I can try again

arctic marlin
sleek eagle
#

Tell me the error haha

#

Also you can ask for help on the forums. There is a thread about windows arm support, and they probably monitor it

arctic marlin
#

should I use Framework or Standard?

#

for the Api Compatiblity Level AND the Editor Assembies Compatiblity Level

sleek eagle
#

Standard

arctic marlin
#

both

#

?

sleek eagle
#

Probably

#

I haven't tried it myself but standard generally has better support

arctic marlin
# sleek eagle Tell me the error haha
FileNotFoundException: Could not load file or assembly 'System.Security.Permissions, Version=6.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51' or one of its dependencies.
Unity.Services.Core.Configuration.Editor.ProjectConfigurationBuildInjectorWithPlayerProcessor.PrepareForBuild (UnityEditor.Build.BuildPlayerContext buildPlayerContext) (at ./Library/PackageCache/com.unity.services.core@1.7.0/Editor/Core/Configuration/ProjectConfigurationBuildInjectorWithPlayerProcessor.cs:26)
UnityEditor.Build.BuildPipelineInterfaces.PreparePlayerBuild (UnityEditor.Build.BuildPlayerContext context) (at <caacb60871c74ec7b7ea8204d9f7b0c1>:0)
UnityEditor.BuildPipeline.PreparePlayerBuild (UnityEditor.BuildPlayerOptions buildPlayerOptions) (at <caacb60871c74ec7b7ea8204d9f7b0c1>:0)
UnityEngine.GUIUtility:ProcessEvent(Int32, IntPtr, Boolean&)
Error building Player: FileNotFoundException: Could not load file or assembly 'System.Security.Permissions, Version=6.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51' or one of its dependencies.```

Build completed with a result of 'Failed' in 0 seconds (0 ms)

UnityEngine.GUIUtility:ProcessEvent (int,intptr,bool&)

#

The Mono works in compiling but made a Windows Error if I try to run the game later on ARM and il2cpp is have a Unity Error on compiling

sleek eagle
#

Do you have the latest visual studio 2022 version? @arctic marlin

#

If not, get that

sleek eagle
#

Maybe tag that developer

arctic marlin
sleek eagle
#

As said in the post I linked, mono definitely doesn't work

#

So edit your post and post about il2cpp

glossy sluice
#

So if I use google sites to create a website for my app and data legitimation. So, next to my main job as a normal worker I need to build a side business for paying taxes later, right? I’m case I earn an amount of income monthly I have to pay taxes rift? But just in case of money come in right?

arctic marlin
sleek eagle
#

In visual studio you need to add the c++ for windows arm modules @arctic marlin

sleek eagle
arctic marlin
#

because its Windows ARM

#

or Gamedevelopment with C++?

#

The Monitor, the Phone or the Controller Icon?
@Dev Dunk

sleek eagle
#

In the seperate modules maybe. You need c++ support for windows arm @arctic marlin

#

Not sure if there is a overarching set for this

arctic marlin
#

I'M not sure should I install: "Desktop Development C++" Or: "Game Development C++" ?

sleek eagle
#

Neither

#

You need to look in the other tab

#

I'll get my laptop

#

Guessing this one

#

And maybe the win 11 sdk

indigo condor
#

anybody using apple cloudkit? I'd like to make sort of a group with people using it to share knowledge

arctic marlin
sleek eagle
#

Sweet! If there are any bugs in the builds please make a bug report for it @arctic marlin

arctic marlin
arctic marlin
#

what logs?

sleek eagle
#

Then you can see why it crashes

arctic marlin
#

dont get it.

#

there was no crash screen after it

#

the game was just closed

sleek eagle
#

Yes

#

So check the logs xD

arctic marlin
#

what logs?

sleek eagle
#

At least you see what happened before it closes

#

The logs your game generates

#

Check the location in the link I sent

arctic marlin
#

I dont get it

#

it that a asset I need to install in the game

#

the button just change the scene and the option button just enable a UI panel.

#

its a simple game not a dribble A game with high quality loading screen with logs included.

sleek eagle
#

What?

#

You said it crashes (or closes unexpectedly) right?

arctic marlin
#

only what you see in the video. and after this "!" meassage with the game icon. it closed with NO Crashlog in the background

sleek eagle
#

There always will be logs generated when you play a unity game iirc

#

%USERPROFILE%\AppData\LocalLow\CompanyName\ProductName\Player.log

Or

%USERPROFILE%\AppData\Local\Packages<productname>\TempState\UnityPlayer.log

As said in the link

cold sable
#

Yo, I'm making my first game which is an offline single-player one but has ads and in-app purchases and such.
But i've never worked with saving and stuff before and playerprefs are not safe or secure but i found an asset on the unity asset store which is a free one and people seem to recommend it , it's called "Save Game Free - Gold Update" and i plan to use it but it also gives you the option to save to Cloud, but what Cloud is it saving to? sorry if its a stupid question, i hope someone here could help guide me on what's the best way to do this :)

tired lily
#

whatever your server is

#

you'll need some kind of backend if you want cloud saving

cold sable
#

Could i cloud save on android services?

cold sable
#

I meant is it free for everyone who owns a developer account?

#

And if i choose to save locally for now, could i move to cloud later without the players losing any progress after i update it?

glossy sluice
#

I have a small game that looks like 100mb, so I created an installer and installed it as a test, and it was 1,10gb. Does someone know why this happend?

elder wren
#

I'm trying to add leaderboards to my game but after importing the google play services package, I get this error when trying to build, does anyone know what reason this could be happening? (API 31):

#

I've seen people online say it has to do with the keystore password being incorrect but this is not the case for me

tired lily
#

did you See the Console for details.?

elder wren
#

there's more but these seem to be the most important errors

tired lily
#

are you building an example project? why does com.google.example.games.mainlibproj.BuildConfig exist?

elder wren
#

no idea why thats there 🤔

#

how do i change it? I could go to the directory listed and change it manually but I'm not sure if that's advised lol

tired lily
#

how did you install it, exactly? Did you follow the Plugin Installation directions?

elder wren
#

I just got the .zip from the github page

#

I took the unity package file from the current-build folder

#

I'm using version 10.14 because apparently there's a known bug with the latest version

tired lily
#

and the project builds okay without it installed?

elder wren
tired lily
#

try a blank project next, eliminate any other possibilities. The presence of some example code makes me think something is installed incorrectly

elder wren
#

I just did a clean build tho and now I have a new error

#

is there any solution for this that doesnt require editing xml files?

#

I have edited them to solve this problem before but I'm not sure if that's how I should be going about fixing this

tired lily
#

hmm does admob already have a dependency on play services? that error looks like you have com.google.android.gms.games.APP_ID defined in multiple manifests

elder wren
#

this is google play:

#

this is play services:

tired lily
#

are you viewing these before or after processing? export to android studio and look there, they probably have some postprocessing scripts because otherwise these are too bare

elder wren
#

mb I've never exported before

#

along with the 2 other manifests from before, now I see this one

#

mb theres that 1 too

#

howcome there's no prefix of u003 on the APP_ID?

#

theres 5 in total

tired lily
#

they all get merged together, that's why you're seeing that previous error

elder wren
#

so just delete one of the APP_ID's?

tired lily
#

are you sure you configured your project correctly? You did all the steps? Exported resources from play console and into the project?

tired lily
#

maybe time to dive into the source generating those manifests then, it's getting that example package from somewhere

elder wren
#

well there's 1 thing that I didn't mention

#

I'm implementing ads and play services with a unity store asset

#

Mobile Tools from Gley Games

#

I'd assume it would be as easy as following the documentation and it works but that's not the case unfortunately

#

atleast in my case... I'll try the blank project later and see because maybe there's just something that I'm overlooking here

hybrid ginkgo
tired lily
#

look for any errors in logcat

hybrid ginkgo
#

errors like this?

#

i have no idea how to fix it

tired lily
#

proguard probably ripped out that class. Build the player in dev mode, if that fixes it add a custom proguard file so those classes don't get removed

hybrid ginkgo
#

im still fairly new to this, so i have no idea what are you saying, sry..

#

i dont think i can build in dev mode, cuz the game already in play store..

#

though i am just using internal testing for now..

tired lily
#

you don't do any testing with a local build?

hybrid ginkgo
#

well, i usually just build it and upload in internal testing, where only i can test it..
again, im still new in game development.. x'd

tired lily
#

regardless, now that you have the error you can find a solution pretty easily

#

internal testing is for distributing to other testers, and rarely debugging certain issues that requires your app to be signed the same way an actual production release would be

hybrid ginkgo
#

i see

#

can you help me with this problem please? xd

hybrid ginkgo
#

It works.. now the callback is working, thank you!

#

But.. sign in status always "canceled" xd

brazen hazel
#

How to add permissions in unity

tired lily
#

custom android manifest + add permission there

amber matrix
#

Hello All. While try to upgrade my game in the play store , im taking an error. And this error message this : "Your App Bundle has the following configurations that exceed the maximum initial upload size of 150MB: arm64-v8a,armeabi-v7a" How can solve this problem ?

tired lily
lost rose
#

I have updated from unity 2021.3.15f to 2022.2.1, but now I am not able to build android apk, I have this error

CommandInvokationFailure: Gradle build failed.
C:\Program Files\Unity\Hub\Editor\2022.2.1f1\Editor\Data\PlaybackEngines\AndroidPlayer\OpenJDK\bin\java.exe -classpath "C:\Program Files\Unity\Hub\Editor\2022.2.1f1\Editor\Data\PlaybackEngines\AndroidPlayer\Tools\gradle\lib\gradle-launcher-7.2.jar" org.gradle.launcher.GradleMain "-Dorg.gradle.jvmargs=-Xmx4096m" "assembleRelease"
How can I fix it

fallen compass
#

oh, so you just ignored the important part of my msg..

lost rose
#

what is stack trace and where I can find it?

fallen compass
#

the obvious place to look, because it's to do with the error you posted, is in the console

lost rose
#

That is a console only, isn't it

fallen compass
#

there are two sections when you click on an error.. the error and then more info in the section below

lost rose
fallen compass
#

is the error you have selected, the first one spat out from a failed build?

lost rose
#

there are two more after this one

#

and then the build is failed error

fallen compass
#

read each one

#

find something that's actually useful

lost rose
#

no idea

fair stream
#

This is the error

tired lily
#

are you initializing with the right ad units? And you're testing on an actual device?

fair stream
#

Yes

tired lily
#

hiding info isn't going to help solve your problem. How are you initializing the sdk? What configuration settings do you have? What are the exact ad units you're using?

fair stream
#

I'm not hiding tbh

fair stream
#

Tbh I used to always click on my own ads as a tester

tired lily
#

I don't recognize the code you're using to initialize with, and all of your screenshots are clipped for some reason

fair stream
#

Oh

tired lily
#

show more of your initialization code

fair stream
fair stream
tired lily
#

where is UnitAds_Init defined? is this a gamemaker thing?

fair stream
#

it's a Java extension

#

maybe i'll upload the java file here

#

@tired lily have u got a unity game id for testing?

#

NVm i guess i found one

tired lily
#

are you sure your initialization logic is right? the error code you are getting back is for an ad load error, and the initialize method you're using seems to take a different listener than what you're giving it

fair stream
#

There is a problem in my code not my game id then i guess

#

I have two different unity extensions

#

My id worked with another extension

#

But in an oter project

tired lily
#

I'm going to guess that the sdk is initializing correctly, but since you never request any ads or use the ad units you're getting an ad load error

fair stream
#

Hmm

tired lily
#

you should be calling UnityAds.load at some point, so unless there's code missing that's definitely going to cause failures when you try to show ads

fair stream
#

Nevermind

#

Things worked fine

#

ty for your help

hollow viper
#

I don’t know what type of model phone this is I know it’s a Samsung

odd arrow
#

@hollow viper Don't post off-topic here

hollow viper
odd arrow
#

@hollow viper If you need to identify your phone, lookup how to. Don't spam the channel here.

hollow viper
odd arrow
#

!mute 531503900340125706 3d Ignoring warnings.

grand windBOT
#

dynoSuccess snoot#5002 was muted

amber matrix
#

@tired lily Hello. Im installed google play plugin in the my project and i did build and then its done . I could upload my game on the play store but when try to open my game on the phone then its game always stopping

tired lily
#

does it work locally? does logcat show any issues?

amber matrix
#

@tired lily im tried on the editor and worked game correctly but when i bundle and upload play store than game is always stopping. And i didnt check logcat logs

tired lily
#

the editor is no substitute for a device, ideally physical

#

build locally and look at the logs, seems like 80% of the time somebody comes here with an android crash on launch it has something to do with proguard and missing classes

#

the logs will tell you exactly what's happened and it's easy to fix if so

amber matrix
#

@tired lily But im building with Google Play App Bunle and you know its bundle not apk . So how can i try on the phone ?

tired lily
#

uncheck build as bundle

glossy sluice
#

Hello Labs, what do you think about using google sites for websites?

teal pilot
#

Hi everyone, does anyone have any suggestions for a cloud platform to store user accounts for an online mobile game - this is mainly to store the user’s progress

amber matrix
#

@tired lily Thank you 🙂 But now i have another problem im opened new project and tried to build and im taking gradle error. ,

#

Why did it so like this ?

amber matrix
#

Im taking this errors

lime ice
#

A failure occurred while executing com.android.build.gradle.internal.tasks.Workers$ActionFacade

More than one file was found with OS independent path 'META-INF/kotlinx_coroutines_core.version'.

#

Anyone any idea how to fix this?

tired lily
amber matrix
tired lily
#

you didn't post what the errors are

#

how did you get a bundle if you can't build an apk?

glossy sluice
#

Hello Labs, what do you think about using google sites for websites?

proper depot
#

General (and maybe stupid question here) Android question here... but if I wanted to read and write to a folder what directory would be good to use on the Android filesystem?

feral sapphire
#

Is there a way to add custom Dynamic Island activities on the iPhone 14 pro series from a unity app?

tired lily
eternal notch
#

i have a question suppose i download the asset bundle from the server in android and now i want to load that locally do anyone know where it stored?

#

Cause currently i am downloading the bundles in resources forlder and its not loading in android but fine loading in editor

tired lily
#

did you make the Resources folder in a writable location? the way you phrased that makes me think you believe the folder structure under Assets exists in a build. That all gets mashed into various .res files and packaged into the apk (with some specific exceptions). Look at Application.persistentDataPath and https://docs.unity3d.com/ScriptReference/Caching.html

amber matrix
tired lily
#

I don't understand what you mean. The popup is telling you to click on each of those errors in the console to read what they are since there is more info there

amber matrix
#

@tired lily Probably u didnt see this image

#

@split dew First disable button interactable and create a timer and timer finished then enable button interactable

tired lily
amber matrix
#

Sorry then just create timer like this ;

#

@split dew int timer = 5;
if(timer<=0) { //ads show code
//restart code}
else{//restart code}

#

@split dew in update timer-=Time.deltaTime;

sacred birch
#

Hi. I'm getting all these Adaptive Performance messages popping up in a brand new project. Should I be worried?

amber matrix
#

@tired lily Now im understood my problem im deleted project and same project old then i tried to build and i can now. When i delete googlemobileads and installed unityads that time im taking these errors. Why its so ?

tired lily
copper sleet
#

Would i come here to get help with joysticks for mobile?

tired lily
#

look in your device settings, usually there is an ads menu or something similar under privacy. Google it for your specific device if you can't find it

tired lily
#

you can change those settings afterwards in the play console, don't worry about that

#

your advertising id is unique to your device. On my phone it's Settings > Privacy > Ads menu, where you can view, delete, or reset your ad id

#

are you seeing test ads? Some advertisers won't start serving ads until your app is live in the store

tired lily
#

what ad network(s) are you using?

#

you need to test on a physical device. Everything in the editor is faked

halcyon moss
#

HI! How I can get good real time shadows on mobile?
I'm using Standard render pipeline, currently my shadows look like this. I saw other games with way better shadows.

tired lily
#

try tweaking the quality settings you're using

sleek eagle
#

Do a lot of tweaking and performance testing as said. If the light will always be from 1 direction, you can also fake the shadow with a sprite/quad with a shadow texture you make

#

Will also allow you to disable any realtime shadows which is a huge performance win

halcyon moss
#

I'm using day/night cycle so that's i need to be realtime

tired lily
#

do you have an upload signing key? you should sign your bundle with it

halcyon moss
#

@split dew add there some number, try 1

#

I use 8k shadows rez but the performance is not good :))

sonic otter
#

My experience with signing has been in Android studio, they make it pretty straightforward

#

Just link your account with google and they give you a signing key for your projects

slender grotto
#

Hey i'm trying so simulate my game on my iPhone via unity remote 5 the issue is that when i press play it doesn't work.
I also saw at the bottom of my sreen that every time i plug and unplug my phone a message is show android extension scan for adb devices is this normal knowing that i'm connecting an ios device.
My platform is currently switched on ios mode.
Anyone knows why this is happening ?

sonic otter
#

Development build enables the Debug.Log (which for performance probably don't want to do for production). Can't remember what else

#

Best for production to not do development build

#

testing is fine though

glossy sluice
#

Hello Labs, what do you think about using google sites for websites?

sonic otter
#

You've asked that question a few times, what are you trying to do with it?

undone radish
#

how can i fix this error its my first time adding ads

halcyon moss
#

I'm doing something wrong here, my game took more than 20 seconds to save, everything is working good but not the save it takes too long to save, I have rly good network connection and the file is like 10kb

rain leaf
tired lily
tired lily
#

1: finish relevant section in play store for your listing under policy and programs -> app content
2: add testers under testing -> internal testing
3: haven't seen that one, sounds like something went wrong with proguard and the mapping file wasn't found. Dev build?
4: when building, make sure the create symbols option is enabled to also get a zip. Upload this zip with your bundle
5: bundle codes must be unique and ascending. Edit Bundle Version Code and rebuild

glossy sluice
#

how do i export the google iap csv to google play console? they removed the option

#

NVM

trail wing
#

Helllo everyone, I tried to implement the google play services leaderboard.
All works, but leaderboard UI doesn’t show up nor does it give any error

#

The screen is just blank 🥹

silent canopy
tired lily
#
  1. you tested it on an actual device, right?
  2. is it published?
  3. are there any ad load errors? If everything is configured correctly, you may still not see ads due to limited ad serving or no fill
  4. I assume you went through all the steps to set up your app for admob, right?
silent canopy
#
  1. I tested test ad on unity which it worked then I switched to real ID and from my phone it doesn't come
  2. yes I published on playstore
  3. I didntnt got any error how do I see that there is no fill or limited serving
  4. yes
#

Also thx for helping

tired lily
#

define "test ad on unity". You tested in the editor, or you tested on your device and saw test ads?

silent canopy
#

I tested test ad in editor

tired lily
#

so you didn't really test ads yet. Deploy to your device and test there. The editor simulates ad watches

silent canopy
#

Ohhhh okay

#

Thx

tired lily
#

also make sure you've either enabled test ads in the sdk (I assume there's an option) or have added your advertising id as a test device so you don't get flagged for invalid traffic

silent canopy
#

Okay

#

So basically I set my mobile as test device and test ads right

tired lily
#

did you get test ads working with the default demo ad units? once you've verified that works, configure a test device and test it using your own ad units

silent canopy
#

By no difference I mean ads not coming

brazen birch
silent canopy
#

It has been months

brazen birch
#

I didn't read carefully if that was your issue

#

Gotcha

tired lily
#

it takes time for the test device info to propagate too, so give it some time. In the meantime, look for any errors in logcat. You're logging ad load failures right?

silent canopy
tired lily
#

also as a sanity check, what is your admob app status? I assume you already submitted it, or did that link thing that automatically submits it

tired lily
silent canopy
silent canopy
#

2023-01-15 21:28:56.166 12606 13666 Error Unity AndroidJavaException: java.lang.ClassNotFoundException: com.google.android.gms.ads.AdRequest$Builder
2023-01-15 21:28:56.166 12606 13666 Error Unity java.lang.ClassNotFoundException: com.google.android.gms.ads.AdRequest$Builder
2023-01-15 21:28:56.166 12606 13666 Error Unity at java.lang.Class.classForName(Native Method)
2023-01-15 21:28:56.166 12606 13666 Error Unity at java.lang.Class.forName(Class.java:454)
2023-01-15 21:28:56.166 12606 13666 Error Unity at com.unity3d.player.UnityPlayer.nativeRender(Native Method)
2023-01-15 21:28:56.166 12606 13666 Error Unity at com.unity3d.player.UnityPlayer.access$300(Unknown Source:0)
2023-01-15 21:28:56.166 12606 13666 Error Unity at com.unity3d.player.UnityPlayer$e$1.handleMessage(Unknown Source:83)
2023-01-15 21:28:56.166 12606 13666 Error Unity at android.os.Handler.dispatchMessage(Handler.java:102)
2023-01-15 21:28:56.166 12606 13666 Error Unity at android.os.Looper.loop(Looper.java:246)
2023-01-15 21:28:56.166 12606 13666 Error Unity at com.unity3d.player.UnityPlayer$e.run(Unknown Source:20)
2023-01-15 21:28:56.166 12606 13666 Error Unity Caused by: java.lang.ClassNotFoundException: com.google.android.gms.ads.AdRequest$Builder
2023-01-15 21:28:56.166 12606 13666 Error Unity ... 8 more
2023-01-15 21:28:56.166 12606 13666 Error Unity at UnityEngine.AndroidJNISafe.CheckException () [0x00000] in <00000000000000000000000000000000>:0
2023-01-15 21:28:56.166 12606 13666 Error Unity at UnityEngine.AndroidJNISafe.FindClass (System.String name) [0x00000] in <00000000000000000000000000000000>:0
2023-01-15 21:28:56.166 12606 13666 Error Unity at UnityEngine.AndroidJavaObject._AndroidJavaObject (System.String class

#

That's what my log cat says

#

When I try to click reward ad button

tired lily
#

add a custom proguard file and make sure that class doesn't get removed

silent canopy
#

Okay

tired lily
#

this looks right

#

didn't you say you had test ads from the example working on your device? was that a dev build?

silent canopy
#

What's dev build? I put test ads just to check in editor then I switched to real ad and uploaded on playstore

tired lily
#

so you skipped the parts where I told you to:

  1. use example ads on an actual device
  2. use your actual ad units on an actual device that's configured to be in test mode
    Again, the editor means absolutely nothing. The admob sdk doesn't run in the editor, it's all fake
#

you can see running the actual sdk barfs immediately, from your stack trace above

silent canopy
#

Wait so I add test ad ID on my actual device?

tired lily
#

the example ad units as part of step 1, yes. Because the editor is not real, so you didn't test whether the sdk was working

silent canopy
tired lily
#

yes. Build settings -> custom proguard file. Paste (or combine) contents

#

then you should see test ads on your device. When that works, make sure your device is in test mode in your admob sdk and test again with real ad units. You'll see production ads that won't get you flagged

silent canopy
#

Tysm

brazen hazel
#

After building the apk when i open the app it doesn’t run

#

An error pops up says (app keeps Stopping )

#

Please help

tired lily
#

logcat

glossy sluice
#

Hello Labs, what do you think about using google sites for websites? Please help?

#

Another question comes up in mind How can I Test my game on my android on iMac in unity? Is Therme anything ? And what do i need to do to make up a Good Quality of my game, so the graphics should bei Good tho

vale perch
#

Hello, does anyone know how to reload my game where i left it at on startup? It keeps starting from level - 0 every time i close the app, I want it to start from the time i left the game at.

tired lily
#

serialize any info (scene index?) you need to disk, and load it on startup. If your data is simple, PlayerPrefs will do the job

pure apex
#

hi does using addresables locally increase build size of the apk

#

can some one explain

glossy sluice
#

Another question comes up in mind How can I Test my game on my android on iMac in unity? Is Therme anything ? And what do i need to do to make up a Good Quality of my game, so the graphics should bei Good tho

tired lily
fallen compass
#

Adressables aren't in the apk

#

You build them separetly

tired lily
#

he said locally, which I took to mean distributed without downloading

glossy sluice
#

Another question comes up in mind How can I Test my game on my android on iMac in unity? Is Therme anything ? And what do i need to do to make up a Good Quality of my game, so the graphics should bei Good tho

fallen compass
#

build and istall it on your phone?

pure apex
#

thanks for the answer but i am trying to load level from the resources folder it has increase the build size it works like this there are 80 level prefabs with different modes(challenge , campaign) with gameobjects in it i am instantiating it whenever level is selected. It works good on memory. I have also tried to with scriptable object(build size is less when using scriptable and not resources) but whenever i go from one mode to another when using scriptable objects the memory usage increases. That's why i am using resources. My question is that is there another approach where I can keep my build size low and without memory leaks.

tired lily
#

anything you put in the build is going to increase its size. There is a build report that is produced that will help you find the worst offenders. As for memory usage: if you're using asynchronous scene loading, you might want to periodically call Resources.UnloadUsedAssets. Otherwise use the memory profiler and find out where you're getting leaks

pure apex
#

thanks very much for the answer

#

If a scriptable object is referenced in the scene if Ishift from one scene to another will that scriptable object data will still be in memory?

#

for example if I load the level from scriptable object play the level but when I shift the from this scene to another and set reference scriptable object to null will the data it contains still be in the memory?

tired lily
#

if you didn't destroy it? Yes. That's why I suggest the Resources call; it'll walk the object graph, find those orphaned objects that should have been destroyed, and unload them

#

if you're loading scenes synchronously, this should already be happening. It's pretty common to use async scene loads instead though, where it wouldn't

amber matrix
#

Friends, I'm trying to set the admob interstitial in unity. There is a reload button in the game, after pressing the button, the ad will appear first, then the stage will open. I tried to do it but without closing the interstitial the scene opens immediately. The code I wrote is as follows:

admobManager.Showads();
SceneManager.LoadScene(SceneManager.GetActiveScene().buildIndex, LoadSceneMode.Single);
PlayerController.isDeath = false;

tired lily
#

is this on editor or an actual device?

amber matrix
#

@tired lily in editor

tired lily
#

on an actual device, the admob sdk probably pauses the unity player (I use a different mediator but this would be the behavior I'd expect). In the editor nothing is real, that's why it's important to use an actual device to test your integration

amber matrix
#

@tired lily So should i try on device ?

tired lily
#

yes

amber matrix
#

@tired lily Ok thank you i will now

proper depot
tired lily
#

if you don't want to write any java, use AndroidJavaClass and AndroidJavaObject. Your entry point would be the Unity player class, com.unity3d.player.UnityPlayer and specifically its static field currentActivity

proper depot
#

ok, I just did a quick google search, this should work, right?

     string path;
     using (AndroidJavaClass jc = new AndroidJavaClass("com.unity3d.player.UnityPlayer"))
     {
         using (AndroidJavaObject currentActivity = jc.GetStatic<AndroidJavaObject>("currentActivity"))
         {
             path = currentActivity.Call<AndroidJavaObject>("getFilesDir").Call<string>("getCanonicalPath");
         }
     }
tired lily
#

looks good to me

proper depot
#

I get this error... I don't really understand it. Sorry I have dumb questions, my programming background is not Mobile/Game development, I've been working the Embedded development space for years with C and ASM.... C# is somewhat new to me

        private void SetCallbacks()
        {
            _wrapper.EnvironmentHandler.SetCoreCallback(_retro_set_environment);
            _wrapper.GraphicsHandler.SetCoreCallback(_retro_set_video_refresh);
            _wrapper.AudioHandler.SetCoreCallbacks(_retro_set_audio_sample, _retro_set_audio_sample_batch);
            _wrapper.InputHandler.SetCoreCallbacks(_retro_set_input_poll, _retro_set_input_state);
        }
        public void SetCoreCallback(retro_set_environment_t setEnvironment) => setEnvironment(_callback);

        private bool EnvironmentCallback(RETRO_ENVIRONMENT cmd, IntPtr data) => cmd switch
        {
            /************************************************************************************************
             * Frontend to core
             */
            RETRO_ENVIRONMENT.GET_OVERSCAN                                => _wrapper.GraphicsHandler.GetOverscan(data),
            RETRO_ENVIRONMENT.GET_CAN_DUPE                                => _wrapper.GraphicsHandler.GetCanDupe(data),
            .........
        }
System.NotSupportedException: IL2CPP does not support marshaling delegates that point to instance methods to native code. The method we're attempting to marshal is: SK.Libretro.EnvironmentHandler::EnvironmentCallback
#

googling around says I need to make SetCoreCallback static, but then that just gives more errors such as

Library\PackageCache\com.sk.libretro@cf14f8392a\Scripts\Core.cs(311,13): error CS0176: Member 'EnvironmentHandler.SetCoreCallback(retro_set_environment_t)' cannot be accessed with an instance reference; qualify it with a type name instead
#

this works on windows/linux, but this error only comes with Android