### robocode

# Class BulletHitBulletEvent

- `java.lang.Object`
- - `robocode.Event`
  - - `robocode.BulletHitBulletEvent`

Implemented Interfaces:
  Comparable, Serializable

`public final class BulletHitBulletEvent`
`extends Event`

This event is sent to `onBulletHitBullet` when one of your bullets has hit another bullet.

Author:
  Mathew A. Nelson (original)

  ## Constructor Summary

  `BulletHitBulletEvent(Bullet bullet, Bullet hitBullet)`
    Called by the game to create a new `BulletHitEvent`.

  ## Method Summary

  `Bullet`

  `getBullet()`
    Returns your bullet that hit another bullet.

  `Bullet`

  `getHitBullet()`
    Returns the bullet that was hit by your bullet.

  ### Methods inherited from class robocode.Event

  `compareTo`, `getPriority`, `getTime`

## Constructor Details

### BulletHitBulletEvent

    public BulletHitBulletEvent(Bullet bullet,
                                Bullet hitBullet)

> Called by the game to create a new `BulletHitEvent`.
> Parameters:
>   `bullet` - your bullet that hit another bullet
>   `hitBullet` - the bullet that was hit by your bullet

## Method Details

### getBullet

    public Bullet getBullet()

> Returns your bullet that hit another bullet.
> Returns:
>   your bullet

### getHitBullet

    public Bullet getHitBullet()

> Returns the bullet that was hit by your bullet.
> Returns:
>   the bullet that was hit