partiusfabaa / cs2-MiniAdmin

Adds basic administrator functions
44 stars 5 forks source link

Error after !admin command #31

Open SaulGoodman1337 opened 6 months ago

SaulGoodman1337 commented 6 months ago

Has anyone here ever seen this before? I'm a little confused because I can't do anything with this stacktrace

Plugins:

[All Chat][Saul Goodman (10579754)]: !admin
18:57:52 [EROR] (cssharp:Core) Error invoking callback
System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation.
 ---> CounterStrikeSharp.API.Core.NativeException: Invoked on a non-main thread
   at CounterStrikeSharp.API.Core.ScriptContext.CheckErrors() in /home/runner/work/CounterStrikeSharp/CounterStrikeSharp/managed/CounterStrikeSharp.API/Core/ScriptContext.cs:line 176
   at CounterStrikeSharp.API.Core.NativeAPI.GetConcreteEntityListPointer() in /home/runner/work/CounterStrikeSharp/CounterStrikeSharp/managed/CounterStrikeSharp.API/Core/API.cs:line 598
   at System.Lazy`1.ViaFactory(LazyThreadSafetyMode mode)
--- End of stack trace from previous location ---
   at System.LazyHelper.ThrowException()
   at System.Lazy`1.CreateValue()
   at System.Lazy`1.get_Value()
   at CounterStrikeSharp.API.Modules.Entities.EntitySystem.get_IdentityChunks() in /home/runner/work/CounterStrikeSharp/CounterStrikeSharp/managed/CounterStrikeSharp.API/Modules/Entities/EntitySystem.cs:line 19
   at CounterStrikeSharp.API.Modules.Entities.EntitySystem.GetEntityByHandle[T](CHandle`1 handle) in /home/runner/work/CounterStrikeSharp/CounterStrikeSharp/managed/CounterStrikeSharp.API/Modules/Entities/EntitySystem.cs:line 32
   at CounterStrikeSharp.API.NativeEntity.get_Handle() in /home/runner/work/CounterStrikeSharp/CounterStrikeSharp/managed/CounterStrikeSharp.API/NativeEntity.cs:line 9
   at CounterStrikeSharp.API.Core.CEntityInstance.get_IsValid() in /home/runner/work/CounterStrikeSharp/CounterStrikeSharp/managed/CounterStrikeSharp.API/Core/Model/CEntityInstance.cs:line 26
   at CounterStrikeSharp.API.Core.Translations.PlayerLanguageExtensions.GetLanguage(CCSPlayerController player) in /home/runner/work/CounterStrikeSharp/CounterStrikeSharp/managed/CounterStrikeSharp.API/Core/Translations/PlayerLanguageExtensions.cs:line 13
   at CounterStrikeSharp.API.Core.BasePlugin.<>c__DisplayClass41_0.<AddCommand>b__0(Int32 i, IntPtr ptr) in /home/runner/work/CounterStrikeSharp/CounterStrikeSharp/managed/CounterStrikeSharp.API/Core/BasePlugin.cs:line 178
   at System.RuntimeMethodHandle.InvokeMethod(Object target, Void** arguments, Signature sig, Boolean isConstructor)
   at System.Reflection.MethodInvoker.Invoke(Object obj, IntPtr* args, BindingFlags invokeAttr)
   --- End of inner exception stack trace ---
   at System.Reflection.MethodInvoker.Invoke(Object obj, IntPtr* args, BindingFlags invokeAttr)
   at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
   at System.Delegate.DynamicInvokeImpl(Object[] args)
   at CounterStrikeSharp.API.Core.FunctionReference.<>c__DisplayClass3_0.<.ctor>b__0(fxScriptContext* context) in /home/runner/work/CounterStrikeSharp/CounterStrikeSharp/managed/CounterStrikeSharp.API/Core/FunctionReference.cs:line 71