Meteor Strike
This setup provides a comprehensive guide on setting up the Throw Weapon Ability on the Bull Boss entity using the Boss AI Toolkit. It also details the workflow for binding custom abilities to the AI system using custom scripts, handling weapon hierarchy setups, configuring trajectory arcs, and integrating custom animations.
1. Custom Ability Creation Workflow
The Boss AI Toolkit allows you to call functions from any custom script via the Create Your Own Ability option.
Steps
- Select the Bull Boss New GameObject in the scene hierarchy.
- Expand the Enemy Ability System component in the Inspector.
- Click Add Ability Entry to Group.
- Set Ability Type to Create Your Own Ability.
- Rename the ability name to
Throw Weapon. - Click Add Script and assign/drag the
Enemy Weapon Throw Abilitycomponent onto it. - Select the target method function:
Activate Throw. - Set Ability Lifetime to
5seconds (the ability will auto-complete after 5 seconds). - Adjust probabilities for isolated testing:
- Set Throw Weapon Probability to
100%. - Set all other ability probabilities to
0%.
NOTE: This workflow works for any custom script. Drag your script into the custom ability entry, select the function you want to execute, and the Boss AI system will invoke it during the combat cycle.
2. Animation Integration
Download or locate the throwing animation clip and bind it to the animator via the Animation Setup Tool.
Steps
- Expand the Animation Setup Tool on the Bull Boss.
- Locate the
Throwanimation clip inside your project's animation directory (Boss AI Toolkit -> Animations). - Click Add Animation and drag the
Throwclip into the slot. - Set the Parameter Name to
Throw. - Click Add to Animator.
- Return to the Enemy Weapon Throw Ability component and set Throw Animation to
Throw.
3. Weapon Hierarchy & References Setup
Ensure the weapon GameObject hierarchy is organized and assigned properly to the Enemy Weapon Throw Ability script.
Steps
- Locate the spiky weapon attached to the boss's hand in the Hierarchy.
- (Optional Alignment) Rename the root weapon container to
Weaponand the mesh child toWeapon Mesh. - Select Bull Boss and inspect the Enemy Weapon Throw Ability component:
- Drag the Weapon GameObject into the Weapon to Throw slot.
- Verify core parameters:
- Weapon Detach Delay:
0.75seconds (delay before the weapon leaves the boss's hand toward the target). - Idle Delay:
1second. - Set rotation axes during flight:
- Enable rotation on desired axes (X, Y, Z).
- Set the rotation speed values as needed (e.g., enable Y rotation for standard spinning motion).
- Return Rotation Duration:
0.2seconds.
4. Trajectory Arc Configurations
You can adjust the projectile flight path of the thrown weapon using horizontal and vertical arcs.
Arc Configurations & Behavior
| Trajectory Type | Horizontal Arc Checkbox | Horizontal Distance | Vertical Arc Checkbox | Vertical Height | Resulting Behavior |
|---|---|---|---|---|---|
| Direct / Straight Line | Unchecked | 0 |
Unchecked | 0 |
The weapon travels in a direct, straight line toward the target position. |
| Horizontal Curve | Checked | -8 (or -6) |
Unchecked | 0 |
The weapon curves sideways along a horizontal arc before hitting the target. |
| Vertical Arc | Unchecked | 0 |
Checked | 4 |
The weapon arcs upward into the air and drops down onto the target. |
| 3D Parabolic Arc | Checked | -6 |
Checked | 3 |
The weapon curves both sideways and vertically, creating a full 3D arc trajectory. |
5. Pre-Combat & Testing Setup
To efficiently isolate and test the Throw Weapon ability in Play Mode without delays:
Steps
- Select the Bull Boss GameObject.
- Set Pre-Combat Value to
4or5(this skips long pre-combat sequences). - Set Min Attack Delay and Max Attack Delay to
2seconds for rapid ability looping during testing. - Enter Play Mode to verify the throw trajectory, impact timing, and return animation.
6. Verification Checklist
Before finalizing the setup, verify the following configuration settings:
- [ ] Custom Ability Hook: Ability Type set to
Create Your Own AbilitytargetingEnemyWeaponThrowAbility.ActivateThrow. - [ ] Probabilities:
Throw Weapon=100%, all other abilities =0%. - [ ] Animator Binding:
Throwanimation parameter added via Animation Setup Tool and assigned in the script. - [ ] Detach Timing:
Weapon Detach Delayset to0.75s. - [ ] Arcs: Trajectory parameters configured according to the desired attack path.