public AvatarBase()
        {
            foreach (System.Reflection.Assembly ass in AppDomain.CurrentDomain.GetAssemblies())
            {
                Type entityComponentScript = ass.GetType("KBEngine.Operation");
                if (entityComponentScript != null)
                {
                    component1       = (OperationBase)Activator.CreateInstance(entityComponentScript);
                    component1.owner = this;
                    component1.entityComponentPropertyID = 5;
                }
            }

            if (component1 == null)
            {
                throw new Exception("Please inherit and implement, such as: \"class Operation : OperationBase\"");
            }
        }
Exemple #2
0
        public AvatarBase()
        {
            foreach (System.Reflection.Assembly ass in AppDomain.CurrentDomain.GetAssemblies())
            {
                Type entityComponentScript = ass.GetType("KBEngine.MatchAvatar");
                if (entityComponentScript != null)
                {
                    compMatchAvatar       = (MatchAvatarBase)Activator.CreateInstance(entityComponentScript);
                    compMatchAvatar.owner = this;
                    compMatchAvatar.entityComponentPropertyID = 17;
                }
            }

            if (compMatchAvatar == null)
            {
                throw new Exception("Please inherit and implement, such as: \"class MatchAvatar : MatchAvatarBase\"");
            }

            foreach (System.Reflection.Assembly ass in AppDomain.CurrentDomain.GetAssemblies())
            {
                Type entityComponentScript = ass.GetType("KBEngine.FrameSyncReport");
                if (entityComponentScript != null)
                {
                    component1       = (FrameSyncReportBase)Activator.CreateInstance(entityComponentScript);
                    component1.owner = this;
                    component1.entityComponentPropertyID = 8;
                }
            }

            if (component1 == null)
            {
                throw new Exception("Please inherit and implement, such as: \"class FrameSyncReport : FrameSyncReportBase\"");
            }

            foreach (System.Reflection.Assembly ass in AppDomain.CurrentDomain.GetAssemblies())
            {
                Type entityComponentScript = ass.GetType("KBEngine.Operation");
                if (entityComponentScript != null)
                {
                    component2       = (OperationBase)Activator.CreateInstance(entityComponentScript);
                    component2.owner = this;
                    component2.entityComponentPropertyID = 11;
                }
            }

            if (component2 == null)
            {
                throw new Exception("Please inherit and implement, such as: \"class Operation : OperationBase\"");
            }

            foreach (System.Reflection.Assembly ass in AppDomain.CurrentDomain.GetAssemblies())
            {
                Type entityComponentScript = ass.GetType("KBEngine.Chat");
                if (entityComponentScript != null)
                {
                    component3       = (ChatBase)Activator.CreateInstance(entityComponentScript);
                    component3.owner = this;
                    component3.entityComponentPropertyID = 15;
                }
            }

            if (component3 == null)
            {
                throw new Exception("Please inherit and implement, such as: \"class Chat : ChatBase\"");
            }
        }