コード例 #1
0
    /// <summary>
    /// Menages unit movement depending on destination objective.
    /// </summary>
    public void MoveManager(Vector3 destination, ToWho where, int resourceID)
    {
        if (where == ToWho.Resource)
        {
            gatheringSourceID = resourceID;
            wantToGather      = true;

            MoveObject(destination);
            ChangeLayerToGathering();
        }
        if (where == ToWho.FreeGround)
        {
            MoveObject(destination);
            wantToGather    = false;
            gathering       = false;
            goingBackToBase = false;

            //isColliding avoiding collision after we change layer
            if (isColliding == false)
            {
                TurnOnCollision();
            }
            if (isColliding == true)
            {
                turnOnCollider = true;
            }
        }
        if (where == ToWho.Building)
        {
            MoveObject(destination);
            goingBackToBase = true;
            ChangeLayerToGathering();
        }
    }
コード例 #2
0
        public override int GetHashCode()
        {
            var hashCode = -2145328967;

            hashCode = hashCode * -1521134295 + EqualityComparer <string> .Default.GetHashCode(PowerFullName);

            hashCode = hashCode * -1521134295 + UniqueId.GetHashCode();
            hashCode = hashCode * -1521134295 + EffectClass.GetHashCode();
            hashCode = hashCode * -1521134295 + EffectType.GetHashCode();
            hashCode = hashCode * -1521134295 + DamageType.GetHashCode();
            hashCode = hashCode * -1521134295 + MezmorizeType.GetHashCode();
            hashCode = hashCode * -1521134295 + EffectModifiers.GetHashCode();
            hashCode = hashCode * -1521134295 + EqualityComparer <string> .Default.GetHashCode(Summon);

            hashCode = hashCode * -1521134295 + DelayedTime.GetHashCode();
            hashCode = hashCode * -1521134295 + Ticks.GetHashCode();
            hashCode = hashCode * -1521134295 + Stacking.GetHashCode();
            hashCode = hashCode * -1521134295 + BaseProbability.GetHashCode();
            hashCode = hashCode * -1521134295 + Suppression.GetHashCode();
            hashCode = hashCode * -1521134295 + Buffable.GetHashCode();
            hashCode = hashCode * -1521134295 + Resistible.GetHashCode();
            hashCode = hashCode * -1521134295 + SpecialCase.GetHashCode();
            hashCode = hashCode * -1521134295 + VariableModifiedOverride.GetHashCode();
            hashCode = hashCode * -1521134295 + PlayerVersusMode.GetHashCode();
            hashCode = hashCode * -1521134295 + ToWho.GetHashCode();
            hashCode = hashCode * -1521134295 + DisplayPercentageOverride.GetHashCode();
            hashCode = hashCode * -1521134295 + Scale.GetHashCode();
            hashCode = hashCode * -1521134295 + Magnitude.GetHashCode();
            hashCode = hashCode * -1521134295 + Duration.GetHashCode();
            hashCode = hashCode * -1521134295 + AttribType.GetHashCode();
            hashCode = hashCode * -1521134295 + Aspect.GetHashCode();
            hashCode = hashCode * -1521134295 + EqualityComparer <string> .Default.GetHashCode(ModifierTable);

            hashCode = hashCode * -1521134295 + NearGround.GetHashCode();
            hashCode = hashCode * -1521134295 + CancelOnMiss.GetHashCode();
            hashCode = hashCode * -1521134295 + RequiresToHitCheck.GetHashCode();
            hashCode = hashCode * -1521134295 + EqualityComparer <string> .Default.GetHashCode(UidClassName);

            hashCode = hashCode * -1521134295 + IdClassName.GetHashCode();
            hashCode = hashCode * -1521134295 + EqualityComparer <string> .Default.GetHashCode(MagnitudeExpression);

            hashCode = hashCode * -1521134295 + EqualityComparer <string> .Default.GetHashCode(Reward);

            hashCode = hashCode * -1521134295 + EqualityComparer <string> .Default.GetHashCode(EffectId);

            hashCode = hashCode * -1521134295 + IgnoreEnhancementDiversification.GetHashCode();
            hashCode = hashCode * -1521134295 + EqualityComparer <string> .Default.GetHashCode(Override);

            hashCode = hashCode * -1521134295 + ProcsPerMinute.GetHashCode();
            return(hashCode);
        }