public static bool TryGet(Agent agent, out ExtendedPlayerAgent extendedPlayer)
        {
            if (agent == null)
            {
                extendedPlayer = null;
                return(false);
            }

            return(wrapped.TryGetValue(agent.GlobalID, out extendedPlayer));
        }
        public static bool TryGet(PlayerAgent player, out ExtendedPlayerAgent extendedPlayer)
        {
            if (player == null)
            {
                extendedPlayer = null;
                return(false);
            }

            return(wrapped.TryGetValue(player.GlobalID, out extendedPlayer));
        }
        public static bool TryGetOrCreate(PlayerAgent player, out ExtendedPlayerAgent extendedPlayer)
        {
            if (!TryGet(player, out extendedPlayer))
            {
                if (player == null)
                {
                    return(false);
                }

                extendedPlayer = new ExtendedPlayerAgent(player);
                wrapped.Add(player.GlobalID, extendedPlayer);
            }

            return(true);
        }
        public static bool TryGetOrCreate(Agent agent, out ExtendedPlayerAgent extendedPlayer)
        {
            if (!TryGet(agent, out extendedPlayer))
            {
                var player = agent?.TryCast <PlayerAgent>();
                if (player == null)
                {
                    return(false);
                }

                extendedPlayer = new ExtendedPlayerAgent(player);
                wrapped.Add(agent.GlobalID, extendedPlayer);
            }

            return(true);
        }