Exemplo n.º 1
0
        public virtual object Clone()
        {
            var context = this.MemberwiseClone() as Context;

            context.conditions = (conditions != null ? (Conditions)conditions.Clone() : null);
            return(context);
        }
Exemplo n.º 2
0
        public virtual object Clone()
        {
            var absEf = (AbstractEffect)this.MemberwiseClone();

            absEf.conditions = (Conditions)conditions.Clone();
            return(absEf);
        }
        public object Clone()
        {
            ConversationReference cr = (ConversationReference)this.MemberwiseClone();

            cr.conditions    = (conditions != null ? (Conditions)conditions.Clone() : null);
            cr.documentation = (documentation != null ? documentation : null);
            cr.idTarget      = (idTarget != null ? idTarget : null);
            return(cr);
        }
Exemplo n.º 4
0
        public object Clone()
        {
            ConversationLine cl = (ConversationLine)this.MemberwiseClone();

            cl.name        = (name != null ? name : null);
            cl.text        = (text != null ? text : null);
            cl.conditions  = (conditions != null ? (Conditions)conditions.Clone() : null);
            cl.keepShowing = keepShowing;
            cl.resources   = resources.ConvertAll(r => r.Clone() as ResourcesUni);
            return(cl);
        }
Exemplo n.º 5
0
        /*
         * @Override
         * public Object clone() throws CloneNotSupportedException
         * {
         *
         *  Barrier b = (Barrier) super.clone( );
         *  b.conditions = ( conditions != null ? (Conditions) conditions.clone( ) : null );
         *  b.height = height;
         *  b.width = width;
         *  b.x = x;
         *  b.y = y;
         *  return b;
         * }*/

        public override object Clone()
        {
            Barrier b = (Barrier)base.Clone();

            b.conditions = (conditions != null ? (Conditions)conditions.Clone() : null);
            b.height     = height;
            b.width      = width;
            b.x          = x;
            b.y          = y;
            return(b);
        }
Exemplo n.º 6
0
        public object Clone()
        {
            ConversationLine cl = (ConversationLine)this.MemberwiseClone();

            cl.audioPath        = (audioPath != null ? audioPath : null);
            cl.name             = (name != null ? name : null);
            cl.synthesizerVoice = synthesizerVoice;
            cl.text             = (text != null ? text : null);
            cl.conditions       = (conditions != null ? (Conditions)conditions.Clone() : null);
            cl.keepShowing      = keepShowing;
            return(cl);
        }
Exemplo n.º 7
0
        public object Clone()
        {
            NextScene ns = (NextScene)this.MemberwiseClone();

            ns.conditions  = (conditions != null ? (Conditions)conditions.Clone() : null);
            ns.destinyX    = destinyX;
            ns.destinyY    = destinyY;
            ns.effects     = (effects != null ? (Effects)effects.Clone() : null);
            ns.look        = (look != null ? (ExitLook)look.Clone() : null);
            ns.nextSceneId = (nextSceneId != null ? nextSceneId : null);
            ns.postEffects = (postEffects != null ? (Effects)postEffects.Clone() : null);
            return(ns);
        }
Exemplo n.º 8
0
        public object Clone()
        {
            ElementReference er = (ElementReference)this.MemberwiseClone();

            er.conditions    = (conditions != null ? (Conditions)conditions.Clone() : null);
            er.documentation = (documentation != null ? documentation : null);
            er.idTarget      = (idTarget != null ? idTarget : null);
            er.influenceArea = (influenceArea != null ? (InfluenceArea)influenceArea.Clone() : null);
            er.layer         = layer;
            er.scale         = scale;
            er.x             = x;
            er.y             = y;
            return(er);
        }
Exemplo n.º 9
0
        public object Clone()
        {
            Description d = (Description)this.MemberwiseClone();

            d.conditions                   = (conditions != null ? (Conditions)conditions.Clone() : null);
            d.name                         = (name != null ? name : null);
            d.nameSoundPath                = (nameSoundPath != null ? nameSoundPath : null);
            d.description                  = (description != null ? description : null);
            d.descriptionSoundPath         = (descriptionSoundPath != null ? descriptionSoundPath : null);
            d.detailedDescription          = (detailedDescription != null ? detailedDescription : null);
            d.detailedDescriptionSoundPath = (detailedDescriptionSoundPath != null ? detailedDescriptionSoundPath : null);

            return(d);
        }
        public object Clone()
        {
            Timer t = (Timer)this.MemberwiseClone();

            t.documentation    = (documentation != null ? documentation : null);
            t.effect           = (effect != null ? (Effects)effect.Clone() : null);
            t.endCond          = (endCond != null ? (Conditions)endCond.Clone() : null);
            t.initCond         = (initCond != null ? (Conditions)initCond.Clone() : null);
            t.postEffect       = (postEffect != null ? (Effects)postEffect.Clone() : null);
            t.seconds          = seconds;
            t.runsInLoop       = runsInLoop;
            t.multipleStarts   = multipleStarts;
            t.usesEndCondition = usesEndCondition;
            return(t);
        }
Exemplo n.º 11
0
        internal override object Clone()
        {
            var ocn = (OptionConversationNode)base.Clone();

            ocn.optionNodes = new List <ConversationNode>();
            ocn.options     = options != null?options.ConvertAll(o => o.Clone() as ConversationLine) : null;

            ocn.random            = random;
            ocn.keepShowing       = keepShowing;
            ocn.showUserOption    = showUserOption;
            ocn.timeout           = timeout;
            ocn.timeoutConditions = timeoutConditions.Clone() as Conditions;
            ocn.timerChild        = null;

            return(ocn);
        }
        public object Clone()
        {
            ResourcesUni r = (ResourcesUni)this.MemberwiseClone();

            if (assets != null)
            {
                r.assets = new Dictionary <string, string>();
                foreach (string s in assets.Keys)
                {
                    string s2 = (assets[s] != null ? assets[s] : null);
                    r.assets.Add(s, s2);
                }
            }
            r.name       = (name != null ? name : null);
            r.conditions = (conditions != null ? (Conditions)conditions.Clone() : null);
            return(r);
        }
Exemplo n.º 13
0
        public virtual object Clone()
        {
            Action a = (Action)this.MemberwiseClone();

            a.conditions            = (conditions != null ? (Conditions)conditions.Clone() : null);
            a.documentation         = (documentation != null ? documentation : null);
            a.effects               = (effects != null ? (Effects)effects.Clone() : null);
            a.idTarget              = (idTarget != null ? idTarget : null);
            a.keepDistance          = keepDistance;
            a.needsGoTo             = needsGoTo;
            a.type                  = type;
            a.notEffects            = (notEffects != null ? (Effects)notEffects.Clone() : null);
            a.activatedNotEffects   = activatedNotEffects;
            a.activatedClickEffects = activatedClickEffects;
            a.clickEffects          = (clickEffects != null ? (Effects)clickEffects.Clone() : null);
            a.conditionsAreMeet     = conditionsAreMeet;
            return(a);
        }
        public virtual object Clone()
        {
            AssessmentRule ar = (AssessmentRule)this.MemberwiseClone();

            ar.concept = (concept != null ? concept : null);
            if (conditions != null)
            {
                ar.conditions = (Conditions)conditions.Clone();
            }
            if (effect != null)
            {
                ar.effect = (AssessmentEffect)effect.Clone();
            }
            ar.id         = (id != null ? id : null);
            ar.importance = importance;
            ar.repeatRule = repeatRule;
            return(ar);
        }
Exemplo n.º 15
0
        /*
         * @Override
         * public Object clone() throws CloneNotSupportedException
         * {
         *
         *  TimedAssessmentRule tar = (TimedAssessmentRule) super.clone( );
         *  tar.effectIndex = effectIndex;
         *  if( effects != null ) {
         *      tar.effects = new List<TimedAssessmentEffect>();
         *      for (TimedAssessmentEffect tae : effects)
         *          tar.effects.add((TimedAssessmentEffect)tae.clone());
         *  }
         *  tar.startTime = startTime;
         *  tar.elapsedTime = elapsedTime;
         *  tar.endConditions = ( endConditions != null ? (Conditions) endConditions.clone( ) : null );
         *  tar.isDone = isDone;
         *  tar.usesEndConditions = usesEndConditions;
         *  return tar;
         * }*/

        public override object Clone()
        {
            TimedAssessmentRule tar = (TimedAssessmentRule)base.Clone();

            tar.effectIndex = effectIndex;
            if (effects != null)
            {
                tar.effects = new List <TimedAssessmentEffect>();
                foreach (TimedAssessmentEffect tae in effects)
                {
                    tar.effects.Add((TimedAssessmentEffect)tae.Clone());
                }
            }
            tar.startTime         = startTime;
            tar.elapsedTime       = elapsedTime;
            tar.endConditions     = (endConditions != null ? (Conditions)endConditions.Clone() : null);
            tar.isDone            = isDone;
            tar.usesEndConditions = usesEndConditions;
            return(tar);
        }
Exemplo n.º 16
0
        public override object Clone()
        {
            ActiveArea aa = (ActiveArea)base.Clone();
            //can not be two identical id
            string id = aa.getId() + "-" + (new System.Random().Next(1000).ToString());

            aa.setId(id);
            aa.conditions    = (conditions != null ? (Conditions)conditions.Clone() : null);
            aa.height        = height;
            aa.width         = width;
            aa.x             = x;
            aa.y             = y;
            aa.influenceArea = (influenceArea != null ? (InfluenceArea)influenceArea.Clone() : null);
            aa.rectangular   = rectangular;
            aa.Vector2s      = (Vector2s != null ? new List <Vector2>() : null);
            foreach (Vector2 p in Vector2s)
            {
                aa.Vector2s.Add(new Vector2(p.x, p.y));
            }
            return(aa);
        }
Exemplo n.º 17
0
        public object Clone()
        {
            Exit e = (Exit)this.MemberwiseClone();

            e.defaultExitLook = (defaultExitLook != null ? (ExitLook)defaultExitLook.Clone() : null);
            e.documentation   = (documentation != null ? documentation : null);
            e.height          = height;
            if (nextScenes != null)
            {
                e.nextScenes = new List <NextScene>();
                foreach (NextScene ns in nextScenes)
                {
                    e.nextScenes.Add((NextScene)ns.Clone());
                }
            }
            e.influenceArea = (influenceArea != null ? (InfluenceArea)influenceArea.Clone() : null);
            e.width         = width;
            e.x             = x;
            e.y             = y;
            e.rectangular   = rectangular;
            if (points != null)
            {
                e.points = new List <Vector2>();
                foreach (Vector2 p in points)
                {
                    e.points.Add(new Vector2(p.x, p.y));
                }
            }
            e.conditions     = (conditions != null ? (Conditions)conditions.Clone() : null);
            e.effects        = (effects != null ? (Effects)effects.Clone() : null);
            e.postEffects    = (postEffects != null ? (Effects)postEffects.Clone() : null);
            e.notEffects     = (notEffects != null ? (Effects)notEffects.Clone() : null);
            e.destinyX       = destinyX;
            e.destinyY       = destinyY;
            e.hasNotEffects  = hasNotEffects;
            e.nextSceneId    = (nextSceneId != null ? nextSceneId : null);
            e.transitionTime = transitionTime;
            e.transitionType = transitionType;
            return(e);
        }