Exemple #1
0
        public QuestObjective FindObjective(Type type)
        {
            for (int i = m_Objectives.Count - 1; i >= 0; --i)
            {
                QuestObjective obj = (QuestObjective)m_Objectives[i];

                if (obj.GetType() == type)
                {
                    return(obj);
                }
            }

            return(null);
        }
        public static void Serialize(Type[] referenceTable, QuestObjective obj, IGenericWriter writer)
        {
            if (obj == null)
            {
                writer.WriteEncodedInt(0x00);
            }
            else
            {
                writer.WriteEncodedInt(0x01);

                Write(obj.GetType(), referenceTable, writer);

                obj.BaseSerialize(writer);
            }
        }
        public static void Serialize( Type[] referenceTable, QuestObjective obj, GenericWriter writer )
        {
            if ( obj == null )
                writer.WriteEncodedInt( 0x00 );
            else
            {
                writer.WriteEncodedInt( 0x01 );

                Write( obj.GetType(), referenceTable, writer );

                obj.BaseSerialize( writer );
            }
        }