Esempio n. 1
0
 public ProjectileInfo(string prefabName, ProjectileSpreadType spreadType, int projectileCount, float error, float burstDelay,
                       bool addInitialForce, AddForceInfo?initialForce = null)
 {
     this.prefabName      = prefabName;
     this.spreadType      = spreadType;
     this.projectileCount = projectileCount;
     this.error           = error;
     this.burstDelay      = burstDelay;
     this.addInitialForce = addInitialForce;
     this.initialForce    = initialForce ?? new AddForceInfo();
 }
Esempio n. 2
0
    private AddForceInfo DrawAddForceInfo(AddForceInfo entry)
    {
        entry.amount        = EditorHelper.FloatField("Amount", entry.amount);
        entry.directionType = EditorHelper.EnumPopup("Direction", entry.directionType);

        if (entry.directionType == AddForceInfo.DirectionType.CustomAngle)
        {
            entry.angle = EditorHelper.FloatField("Angle", entry.angle);
            entry.error = EditorHelper.FloatField("Error", entry.error);
        }
        entry.resetCurrentVelocity = EditorGUILayout.Toggle("Reset Current Velocity?", entry.resetCurrentVelocity);

        return(entry);
    }
 public StatusMovementAffecting(StatusInfo info, AddForceInfo forceInfo) : base(info)
 {
     SetupMovement(forceInfo);
 }
 private void SetupMovement(AddForceInfo forceInfo)
 {
     this.baseForceAmount = forceInfo.amount;
     this.forceInfo       = forceInfo;
 }
Esempio n. 5
0
 public EffectAddForce(Ability parentAbility, AddForceInfo forceInfo) : base(parentAbility)
 {
     this.forceInfo = forceInfo;
 }