nl.tudelft.pogamut.ut2004.agent.module.shooting.weapon
Class RocketLauncherShooting
java.lang.Object
cz.cuni.amis.pogamut.base.agent.module.AgentModule<AGENT>
cz.cuni.amis.pogamut.base.agent.module.SensorModule<UT2004Bot>
nl.tudelft.pogamut.unreal.agent.module.shooting.AbstractWeaponShooting
nl.tudelft.pogamut.ut2004.agent.module.shooting.weapon.RocketLauncherShooting
- All Implemented Interfaces:
- cz.cuni.amis.pogamut.base.component.IComponent, nl.tudelft.pogamut.unreal.agent.module.shooting.WeaponShooting
public class RocketLauncherShooting
- extends nl.tudelft.pogamut.unreal.agent.module.shooting.AbstractWeaponShooting
Module to work efficiently with the rocket launcher.
The rocket launcher is fairly hard to use as it effectiveness lies in
predicting where the player will be. Something a little too complex. This
module only provides support for shooting players that are currently visible
or have recently hidden.
To avoid self damage, this module won't fire when the target is too close and
the bot survive the blast.
When a target hides the bot will shoot a little below its last known
location, trying to flush the target out.
- Author:
- mpkorstanje
| Fields inherited from class nl.tudelft.pogamut.unreal.agent.module.shooting.AbstractWeaponShooting |
ABOVE_PLAYER_OFFSET, active, BELOW_PLAYER_OFFSET, endMessageListener, FACING_ANGLE, focus, info, shoot, target, weaponPref, weaponry |
| Fields inherited from class cz.cuni.amis.pogamut.base.agent.module.SensorModule |
worldView |
| Fields inherited from class cz.cuni.amis.pogamut.base.agent.module.AgentModule |
agent, controller, eventBus, log |
|
Method Summary |
protected WeaponPref |
getDefaultWeaponPref()
|
protected boolean |
isSafeToShoot(cz.cuni.amis.pogamut.base3d.worldview.object.ILocated target)
Don't shoot unless we are far away enough to avoid damaging ourselves, or
healthy enough to survive the damage. |
protected void |
shoot()
|
| Methods inherited from class nl.tudelft.pogamut.unreal.agent.module.shooting.AbstractWeaponShooting |
getFocus, getWeaponType, hasTarget, isActive, isWeaponReady, setFocus, shoot, stopShoot |
| Methods inherited from class cz.cuni.amis.pogamut.base.agent.module.AgentModule |
cleanUp, getComponentId, getLog, getState, initComponentId, isRunning, kill, pause, reset, resume, start, stop, toString |
ROCKET_LAUNCHER_PRIMARY
protected static final WeaponPref ROCKET_LAUNCHER_PRIMARY
ROCKET_LAUNCHER_PROJECTILE_SPLASH_RADIUS
protected static final double ROCKET_LAUNCHER_PROJECTILE_SPLASH_RADIUS
- See Also:
- Constant Field Values
ROCKET_LAUNCHER_PROJECTILE_DAMAGE
protected static final int ROCKET_LAUNCHER_PROJECTILE_DAMAGE
- See Also:
- Constant Field Values
ROCKET_LAUNCHER_THREE_PROJECTILE_DAMAGE
protected static final int ROCKET_LAUNCHER_THREE_PROJECTILE_DAMAGE
- See Also:
- Constant Field Values
ROCKET_LAUNCHER_CHARGE_TIME_SECONDS
protected static final double ROCKET_LAUNCHER_CHARGE_TIME_SECONDS
- See Also:
- Constant Field Values
lastLocation
protected cz.cuni.amis.pogamut.base3d.worldview.object.Location lastLocation
RocketLauncherShooting
public RocketLauncherShooting(UT2004Bot<?,?,?> agent,
AgentInfo info,
ImprovedShooting shoot,
Weaponry weaponry)
shoot
protected void shoot()
- Specified by:
shoot in class nl.tudelft.pogamut.unreal.agent.module.shooting.AbstractWeaponShooting
isSafeToShoot
protected boolean isSafeToShoot(cz.cuni.amis.pogamut.base3d.worldview.object.ILocated target)
- Don't shoot unless we are far away enough to avoid damaging ourselves, or
healthy enough to survive the damage.
- Parameters:
target - to shoot
- Returns:
- true iff we won't kill ourselves.
getDefaultWeaponPref
protected WeaponPref getDefaultWeaponPref()
- Specified by:
getDefaultWeaponPref in class nl.tudelft.pogamut.unreal.agent.module.shooting.AbstractWeaponShooting
Copyright © 2014 AMIS research group, Faculty of Mathematics and Physics, Charles University in Prague, Czech Republic. All Rights Reserved.