Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

SpaceShooter DynamicInvoke error while playing

Open
#68 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
25/100
Issue type
Bug
Clarity
Needs clarification
Activity status
Stale
Tech stack
csharp, unity
Domain
game-dev

Research direction

Reproduce the failure by opening the SpaceShooter sample in Unity 2021.2.5f1 and playing the bootstrap scene. Start with the stack trace locations in AssetDatabaseProvider.cs and DelayedActionManager.cs from Addressables 1.19.11, then compare the failing asset-load path with the sample setup. Done means the bootstrap scene plays without the repeated DynamicInvoke or NullReferenceException.

Written by the indexing model from the issue text.

Description

Hi, I am new to Addressables and wanted to try the samples in this repo,
When I tried to open SpaceShooter with unity version 2021.2.5f1 and played the bootstrap scene, after few frames I got the following exception in console:

Exception thrown in DynamicInvoke: System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.NullReferenceException: Object reference not set to an instance of an object
  at UnityEngine.ResourceManagement.ResourceProviders.AssetDatabaseProvider.LoadAssetAtPath (System.String assetPath, UnityEngine.ResourceManagement.ResourceProviders.ProvideHandle provideHandle) [0x00013] in C:\GitLab\Addressables-Sample\Basic\SpaceShooter\Library\PackageCache\com.unity.addressables@1.19.11\Runtime\ResourceManager\ResourceProviders\AssetDatabaseProvider.cs:46 
  at UnityEngine.ResourceManagement.ResourceProviders.AssetDatabaseProvider+InternalOp.LoadImmediate () [0x000c6] in C:\GitLab\Addressables-Sample\Basic\SpaceShooter\Library\PackageCache\com.unity.addressables@1.19.11\Runtime\ResourceManager\ResourceProviders\AssetDatabaseProvider.cs:112 
  at (wrapper managed-to-native) System.Reflection.RuntimeMethodInfo.InternalInvoke(System.Reflection.RuntimeMethodInfo,object,object[],System.Exception&)
  at System.Reflection.RuntimeMethodInfo.Invoke (System.Object obj, System.Reflection.BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) [0x0006a] in <00c558282d074245ab3496e2d108079b>:0 
   --- End of inner exception stack trace ---
  at System.Reflection.RuntimeMethodInfo.Invoke (System.Object obj, System.Reflection.BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) [0x00083] in <00c558282d074245ab3496e2d108079b>:0 
  at System.Reflection.MethodBase.Invoke (System.Object obj, System.Object[] parameters) [0x00000] in <00c558282d074245ab3496e2d108079b>:0 
  at System.Delegate.DynamicInvokeImpl (System.Object[] args) [0x000e7] in <00c558282d074245ab3496e2d108079b>:0 
  at System.MulticastDelegate.DynamicInvokeImpl (System.Object[] args) [0x00008] in <00c558282d074245ab3496e2d108079b>:0 
  at System.Delegate.DynamicInvoke (System.Object[] args) [0x00000] in <00c558282d074245ab3496e2d108079b>:0 
  at UnityEngine.ResourceManagement.Util.DelayedActionManager+DelegateInfo.Invoke () [0x00000] in C:\GitLab\Addressables-Sample\Basic\SpaceShooter\Library\PackageCache\com.unity.addressables@1.19.11\Runtime\ResourceManager\Util\DelayedActionManager.cs:46  5 (target=UnityEngine.ResourceManagement.ResourceProviders.AssetDatabaseProvider+InternalOp) InternalOp.LoadImmediate() @7.347976
UnityEngine.ResourceManagement.Util.DelayedActionManager:LateUpdate () (at Library/PackageCache/com.unity.addressables@1.19.11/Runtime/ResourceManager/Util/DelayedActionManager.cs:159)

any suggestions to why it would happen? when I click unpause it resume and then thrown again :(

Thanks!

Dominant language
C#
Stars
1.5k
Forks
303
PR merge metrics
No merged PRs in 30d

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from Unity-Technologies/Addressables-Sample

All issues in Unity-Technologies/Addressables-Sample

Similar issues

More C# issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.