ABILITY 04
RangePower
Fire pooled projectiles toward the mouse with configurable shot count, speed and aim angle.
Activation
RangePowerButtonExample use
Explore the setup guide below to configure this ability.
Ability documentationCHARACTER ABILITY
SETUP GUIDE
Set up this ability
Component dependencies
| Component | Where to add or assign it | Purpose / setup |
|---|---|---|
| MMObjectPooler / MMSimpleObjectPooler | Ability GameObject, or explicitly assigned through ObjectPooler | Required for firing. Add MM Simple Object Pooler, assign a projectile prefab to its pool, then assign the pooler to ObjectPooler or let the ability find it on the same GameObject. The projectile prefab needs the Corgi Projectile component for the configured direction and speed behavior. |
| Camera tagged MainCamera | Scene | Required for converting the mouse position into the world aim point. |
Visual component dependencies
These components support the associated effect. A missing optional visual does not by itself imply that the gameplay mechanic cannot run.
| Component | Where to add or assign it | Purpose / setup |
|---|---|---|
| ReticlePrefab | Assigned prefab field | Optional aiming marker. Missing it removes visual feedback but does not prevent firing. |
- Add CharacterRangePower and an MMObjectPooler, such as MMSimpleObjectPooler, on the ability GameObject. Configure the pool with your projectile prefab.
- Assign ObjectPooler or let the component find it on the same GameObject. The helper CharacterProjectileHandler is added at runtime.
- Optionally assign RecticlePrefab 1 to ReticlePrefab. A MainCamera-tagged camera is needed for mouse aiming.
- Set ProjectilesPerShot, ProjectileSpeed and ValidAngleThreshold. ProjectileSpeed = 0 preserves the projectile prefab speed.
- Press RangePowerButton while aiming inside the allowed angle. ProjectileSpam = true stops the ability after firing; cooldown still applies.
Inspector reference
These are C# field declaration defaults. Existing prefab and scene values can override them. Shared fields are documented under Ability Configuration.
| Field | Type | Declared default |
|---|---|---|
OffsetPosition | Vector3 | Vector3.zero |
OffsetFlippedPosition | Vector3 | Vector3.zero |
ProjectilesPerShot | int | 1 |
ProjectileSpam | bool | true |
ProjectileSpeed | float | 0f |
Spread | Vector3 | Vector3.zero |
RandomSpread | bool | true |
ObjectPooler | MMObjectPooler | Not assigned in declaration |
ReticlePrefab | GameObject | Not assigned in declaration |
ValidAngleThreshold | float | 90f |
ReticleResetTime | float | 3f |
Usage notes
- This is a mouse-aimed projectile ability, not simply a range multiplier. It bypasses the normal weapon slot workflow.
- Projectiles are directed toward the mouse aim point after spawning.
- No MMObjectPooler prevents initialization. A missing reticle only removes visual aiming feedback.
