All pastes #925297 Raw Edit

Someone

public text v1 · immutable
·published 2008-03-02 06:57 UTC
rendered paste body
        public void AddToDictionary<T>(T Value)
        {
            //Should iterate through and automagically add the value to the end of the dictionary
            EVECharacter tempEve;
            WoWCharacter tempWoW;
            int Which = 0;
            if (Value.GetType() == EVECharacter)
            {
                tempEve = (EVECharacter)Value;
                if (!_myCharDict.ContainsKey(tempEve.HandshakeString))
                    _myCharDict.Add(tempEve.HandshakeString, tempEve);
            }
            else if (Value.GetType().Equals(WoWCharacter).GetType())
            {
                tempWoW = (WoWCharacter)Value;
                if (!_myCharDict.ContainsKey(tempWoW.HandshakeString))
                    _myCharDict.Add(tempWoW.HandshakeString, tempWoW);
            }
        }