XBombFlag
xBombFlag is the ball (or bomb) in Bombing Run. It handles seeking a pass target, giving players the ball launcher, and switching them back to another weapon when the ball is launched.
Properties
- BombLauncherClass
- Defaults to BallLauncher.
- PrevWeaponClass
- Class of weapon the holder was using when the ball was picked up.
- PassTarget
- ThrowSpeed
- Speed of the ball when launched.
- Elasticity
- How much momentum to retain on a bounce. Zero actually causes the ball to stick.
- ImpactSound
- ThrowerTouchDelay
- ThrowerTime
- InitialDir
- SeekInterval
- SeekAccum
- TeamShader
- TeamHue
- bThrownBomb
Methods
Inherited from Actor
- HitWall
- Bounce as appropriate using Elasticity value, play the ball hit sound and if the velocity is too slow, consider ourselves Landed.
- Landed
- Stop any movement and start rotating.
- TakeDamage
- Increases ball velocity when shot and not held (boost shot), a common BR technique.
- Timer
- Tick
- Home in on the pass target. Only enabled during a pass attempt.
Inherited from GameObject
- ClearHolder
- Put the bomb launcher away.
- SetHolder
- Give the holder a bomb launcher.
- ValidHolder
- Allow players to deflect the ball with the shield gun.
- LogDropped
- LogReturned
- LogTaken
- SendHomeDisabled
Other Methods
- SetThrow
- Throw
- RandSpin
States
- Home
- Ball is sitting at ball spawn and is active. GameReplicationInfo flag states are set as such.
- HomeDisabled
- Ball is sitting at ball spawn and is disabled. This is the state used in the interval between the time a goal is scored and the beginning of the next round.
- Held
- Sets up flag states in GameReplicationInfo and swaps the mesh used for the ball skin. This is what turns the ball into the orbiting lines that surround the player when the player picks up the ball.
- Dropped
- Undoes the skin swap that the Held state does, and unsets the flag states in GameReplicationInfo. Also starts the ball reset timer. If the ball is not picked up in a certain amount of time, it goes to the Home state and is returned to the ball spawn.
Related Topics
Discussion
Uncommon: I just thought I'd throw in a few comments about the implementation of [Bombing Spree]. There were a few things I was able to take advantage of in this class to get the behavior I wanted. First, having the ball launcher class stored in a variable made it easy to substitute my own version (one that doesn't lock on to other ball carriers). Second, the Elasticity turned out to be fun to play with, so I added a control for that. And then there was the usual overriding of functions to add the reset explosions and keep ball carriers from picking up additional balls. I even fixed a problem with [HealthBot]s picking up balls, which AFAIK remains a problem in regular Bombing Run.