internal WeaponTriggerAutofireStructBlockBase(BinaryReader binaryReader)
 {
     this.autofireTime    = binaryReader.ReadSingle();
     this.autofireThrow   = binaryReader.ReadSingle();
     this.secondaryAction = (SecondaryAction)binaryReader.ReadInt16();
     this.primaryAction   = (PrimaryAction)binaryReader.ReadInt16();
 }
Example #2
0
    void Start()
    {
        MeterManager.instance.OnActorChanged.AddListener(() => {
            var nextActionIdx = Random.Range(0, 2);

            currentSecondaryAction = secondaryActions[nextActionIdx];
        });
    }
 public ActionDefinition(
     DirectionalAction dirAction,
     PrimaryAction primaryAction,
     SecondaryAction secondAction
     )
 {
     this.DirectionalAction = dirAction;
     this.PrimaryAction = primaryAction;
     this.SecondaryAction = secondAction;
 }
Example #4
0
 public ActionComponent(
     DirectionalAction direction, 
     SecondaryAction SecondaryAct, 
     PrimaryAction primaryAct, 
     Drift drifting = Drift.None)
 {
     this.curDirection = direction;
     this.secondaryAction = SecondaryAct;
     this.primaryAction = primaryAct;
     this.drift = drifting;
 }
        /// <summary>
        /// Snaps the follow on the primary and secondary action if they are <see cref="GrabInteractableFollowAction"/> type.
        /// </summary>
        public virtual void SnapFollowOrientation()
        {
            if (PrimaryAction != null && PrimaryAction.GetType() == typeof(GrabInteractableFollowAction))
            {
                GrabInteractableFollowAction action = (GrabInteractableFollowAction)PrimaryAction;
                action.ForceSnapOrientation();
            }

            if (SecondaryAction != null && SecondaryAction.GetType() == typeof(GrabInteractableFollowAction))
            {
                GrabInteractableFollowAction action = (GrabInteractableFollowAction)SecondaryAction;
                action.ForceSnapOrientation();
            }
        }
Example #6
0
        public Object UpdateSecondaryAction(SecondaryAction secondaryAction)
        {
            bool result = data.UpdateSecondaryAction(secondaryAction);

            return(new { result });
        }
Example #7
0
        public Object AddSecondaryAction(SecondaryAction action)
        {
            bool result = data.AddSecondaryAction(action);

            return(new { result });
        }