1. Code:
    Unable to load the AI: Animal.Think. Additional details: Could not load type 'System.Runtime.Versioning.TargetFrameworkAttribute' from assembly 'GameWer'.
    Unable to load AI, no AI with the specified ID exists.
    Unable to load the AI: Animal.Action. Additional details: Could not load type 'System.Runtime.Versioning.TargetFrameworkAttribute' from assembly 'GameWer'.
    Unable to load AI, no AI with the specified ID exists.
    https://image.prntscr.com/image/D3IbL5AlTM6NpT35KfFKNA.png
    this message has flooding to my game server =( this message dont have to oxide soruce code =(
    My plugin code:
    Code:
    // Reference: GameWer
    #define STEAM_IS_NOTHAVE_GAMEWERusing System.Collections.Generic;
    using System;
    using Newtonsoft.Json;
    using UnityEngine;namespace Oxide.Plugins
    {
        [Info("Game Wer - AntiCheat", "TheRyuzaki", "2.0.1")]
        public class TheRyuzakiGameWer : RustPlugin
        {
            public const string CONST_COMMAND_SESSION_NOT_FOUND = "kick {STEAMID} \"GameWer: Session not found!\"";
            public const string CONST_COMMAND_PLAYER_BANNED = "ban {STEAMID} \"GameWer: Player banned!\"";
            public const string CONST_ADDRES_GAMEWER_SERVER = "******";
           
            private HashSet<ulong> ListIgnorePlayersPlayers = new HashSet<ulong>();#if STEAM_IS_NOTHAVE_GAMEWER
            void OnPlayerInit(BasePlayer player)
            {
                var token = GameWer.SerializationExtension.Deserialize<GameWer.STEAM_TICKET>(player.net.connection.token);
                if (token.Token.AppID == 252490)
                    ListIgnorePlayersPlayers.Add(player.userID);
            }
    #endif        void OnServerInitialized()
            {
                for (int i = 0; i < BasePlayer.activePlayerList.Count; ++i)
                    this.OnPlayerInit(BasePlayer.activePlayerList[i]);            timer.Repeat(10f, 0, () =>
                {
                    string line_steamid = "";
                    for (int i = 0; i < BasePlayer.activePlayerList.Count; ++i)
                        if (!ListIgnorePlayersPlayers.Contains(BasePlayer.activePlayerList[i].userID))
                            line_steamid += BasePlayer.activePlayerList[i].UserIDString + ",";                webrequest.EnqueueGet("http://" + CONST_ADDRES_GAMEWER_SERVER + ":8085/?query=getsteamid&steamid=" + line_steamid, (code, response) => {
                        if (code == 200)
                        {
                            var json = JsonConvert.DeserializeObject<Dictionary<string, string>>(response);
                            var json_response_line = json["response"];
                            var players_lines = json_response_line.Split(new char[] { ';' }, StringSplitOptions.RemoveEmptyEntries);
                            for (int i = 0; i < players_lines.Length; ++i)
                            {
                                var player_line = players_lines[i].Split(new char[] { ':' }, StringSplitOptions.RemoveEmptyEntries);
                                if (player_line.Length >= 2)
                                {
                                    switch (player_line[1])
                                    {
                                        case "player_banned":
                                            ConsoleSystem.Run(ConsoleSystem.Option.Server, CONST_COMMAND_PLAYER_BANNED.Replace("{STEAMID}", player_line[0], StringComparison.Ordinal));
                                            break;
                                        case "session_not_found":
                                            ConsoleSystem.Run(ConsoleSystem.Option.Server, CONST_COMMAND_SESSION_NOT_FOUND.Replace("{STEAMID}", player_line[0], StringComparison.Ordinal));
                                            break;
                                    }
                                }
                            }
                        }
                    }, this);
                });
            }    }
    }
    

    DLL Code:
    Code:
    using System;
    using System.Collections.Generic;
    using System.Linq;
    using System.Runtime.InteropServices;
    using System.Text;namespace GameWer
    {
        public static class SerializationExtension
        {
            // Methods
            public static T Deserialize<T>(this byte[] bytes) where T : struct
            {
                try
                {
                    GCHandle handle = GCHandle.Alloc(bytes, GCHandleType.Pinned);
                    T local = (T)Marshal.PtrToStructure(handle.AddrOfPinnedObject(), typeof(T));
                    handle.Free();
                    return local;
                }
                catch
                {
                }
                return default(T);
            }        public static byte[] Serialize<T>(this T structure) where T : struct
            {
                byte[] destination = new byte[Marshal.SizeOf(typeof(T))];
                IntPtr ptr = Marshal.AllocHGlobal(destination.Length);
                Marshal.StructureToPtr(structure, ptr, true);
                Marshal.Copy(ptr, destination, 0, destination.Length);
                Marshal.FreeHGlobal(ptr);
                return destination;
            }
        }[StructLayout(LayoutKind.Sequential, Size = 0xea, Pack = 1)]
        public struct STEAM_TICKET
        {
            public uint Length;
            public ulong ID;
            public ulong SteamID;
            public uint ConnectionTime;
            public STEAM_SESSION Session;
            public STEAM_TOKENDATA Token;
        }
    [StructLayout(LayoutKind.Sequential, Pack = 1)]
        public struct STEAM_SESSION
        {
            public uint Length;
            public uint Unknown0x1C;
            public uint Unknown0x20;
            public uint Unknown0x24;
            public uint Unknown0x28;
            public uint SessionID;
            public uint ConnectNumber;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 1)]
        public struct STEAM_TOKENDATA
        {
            public int Length;
            public int Unknown0x38;
            public int Unknown0x3C;
            public ulong UserID;
            public int AppID;
            public int Unknown0x4C;
            public byte Unknown0x50;
            public byte Unknown0x51;
            public byte Unknown0x52;
            public byte Unknown0x53;
            public uint Unknown0x54;
            public uint StartTime;
            public uint EndedTime;
            public byte Unknown0x60;
            public byte Unknown0x61;
            public byte Unknown0x62;
            public byte Unknown0x63;
            public short Unknown0x64;
            public short Unknown0x66;
            public short Unknown0x68;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 0x80)]
            public byte[] SHA128;
        }}
    
     
  2. It seems like there is a conflicting dependency. Make sure that the extension/dll is targetting the .net 3.5 framework.
     
  3. I seem to be having some major issues with animals on my server. They just dont move and dont respond to anything. Not really sure what has caused it.

    My console is outputting a very large amount of errors. heres a snippet.

    Code:
    (13:54:24) | Unable to load AI, no AI with the specified ID exists.(13:54:24) | Unable to load the AI: Animal.Think. Additional details: Could not load type 'System.Runtime.Versioning.TargetFrameworkAttribute' from assembly 'Oxide.Ext.Hive'.(13:54:24) | Unable to load AI, no AI with the specified ID exists.(13:54:24) | Unable to load the AI: Animal.Action. Additional details: Could not load type 'System.Runtime.Versioning.TargetFrameworkAttribute' from assembly 'Oxide.Ext.Hive'.(13:54:24) | Unable to load AI, no AI with the specified ID exists.(13:54:24) | Unable to load the AI: Animal.Think. Additional details: Could not load type 'System.Runtime.Versioning.TargetFrameworkAttribute' from assembly 'Oxide.Ext.Hive'.(13:54:24) | Unable to load AI, no AI with the specified ID exists.(13:54:24) | Unable to load the AI: Animal.Action. Additional details: Could not load type 'System.Runtime.Versioning.TargetFrameworkAttribute' from assembly 'Oxide.Ext.Hive'.(13:54:24) | Unable to load AI, no AI with the specified ID exists.(13:54:24) | Unable to load the AI: Animal.Think. Additional details: Could not load type 'System.Runtime.Versioning.TargetFrameworkAttribute' from assembly 'Oxide.Ext.Hive'.
    
    I've tried removing almost every addon from the server, toggling ai and ensuring values are correct and set to true. I tried +nav_disable "false" but with no luck still

    Any help would be appreciated, I have been trying to figure this out for several hours now and had no luck.
     
  4. Wulf

    Wulf Community Admin

    That appears to be an issue with the extension you are using, not Rust itself. See the "Oxide.Ext.Hive" in the error.
     
  5. I'm not sure how to work with Oxide.Ext.Hive

    I was actually finally able to have some success however, I installed Custom AI, and Radtown Animals for Rust.

    Animals now seem to behaving correctly again,

    However my console does still spit out a load of the same errors every now and then.

    I'm not really sure why its working again, but I'm quite relieved.