Package com.starpoints.game.item
Class ItemDoubleShields
- java.lang.Object
-
- com.starpoints.game.Thing
-
- com.starpoints.game.Item
-
- com.starpoints.game.item.ItemDoubleShields
-
- All Implemented Interfaces:
java.io.Serializable,java.lang.Cloneable
public class ItemDoubleShields extends Item
Permanent item, that doubles all the collectors shieldings.- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static booleanDEBUGDebug flag.-
Fields inherited from class com.starpoints.game.Item
affectsBlue, category, DEFAULT_ITEM_PAINTERCLASS, dieReason, isBomb, isWeapon, pickupClip, pickupText, pointBonus, useClip, user
-
Fields inherited from class com.starpoints.game.Thing
energy, energyFx, energyMaxSoundPlayed, energyModifications, explosionCounter, game, imageName, innerColor, invulnCount, isAffectedByBlack, isAffectedByGray, level, MAX_TEXTPAINT, maxEnergy, nextID, outerColor, p, shieldCount, status, text
-
-
Constructor Summary
Constructors Constructor Description ItemDoubleShields()Creates a new ItemDoubleShields
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voidaddStateProperties(ThingState state, AnimationInfo animation)Adds properties necessary for color bucket painting.protected intgetCount()Gets the shield factor (0 = 2x, 1 = 4x, 2 = 8x).java.lang.StringgetImageName(AnimationInfo animation)Returns image name.intgetItemRating()Returns an item value for ComputerFigures rating in the items category.booleanonBePickedUp(Figure picker, AnimationInfo animation)Increases all owners shielding.-
Methods inherited from class com.starpoints.game.Item
affectsBlue, bePickedUp, beUsed, bombPlaced, createState, die, doSpecialUpdate, entersColor, explodes, gainsEnergy, gainsPermanentItem, gainsSlots, getCategory, getDieReason, getDrawText, getItemRating, getMoveAnimationLength, getName, getPainterClassname, getPickUpClip, getPickupText, getPointBonus, getRamPower, getUseClip, getUser, heatChanges, is3DItem, isAffectedByColor, isAvailableInEditor, isBomb, isRammed, isRocketTarget, isStunned, isWeapon, killedEnemy, losesEnergy, losesItem, losesPermanentItem, lostPermanentItem, onBeforeDie, onBeHitByItem, onBeUsed, onDrop, onEnemyKilled, onHitItem, onLevelFinished, performFieldEffect, pickesUpBomb, pickesUpExplosive, pickesUpItem, pointsChange, pointSumChanges, removeAfterLevel, retrieveState, rocketStarted, setUser, startsHovering, staysOnColor, toString, updateExplodingStatus, updateThing, usesItem, visibilityChanges
-
Methods inherited from class com.starpoints.game.Thing
addEnergy, addShielding, clearTexts, displayText, displayText, entersColor, equals, getColor, getEnergy, getEnergyMaxCount, getExplosionCounter, getField, getGame, getID, getInnerColor, getInvulnerableRounds, getLevel, getMaxEnergy, getNextID, getOuterColor, getPoint, getShadowColor, getShield, getStateObject, getStatus, getText, getTextColor, getTextPaintCount, getX, getY, hashCode, invulnerable, isAffectedByBlack, isAffectedByGray, isDestroyed, isExploding, isInvulnerable, isOK, isShowingEnergyFx, onExplode, removeEnergy, retrieveState, setEnergy, setEnergyMaxCount, setGame, setMaxEnergy, setPoint, setStatus, staysOnColor, stepText, updateEnergy
-
-
-
-
Field Detail
-
DEBUG
public static final boolean DEBUG
Debug flag.- See Also:
- Constant Field Values
-
-
Method Detail
-
addStateProperties
protected void addStateProperties(ThingState state, AnimationInfo animation)
Adds properties necessary for color bucket painting.- Overrides:
addStatePropertiesin classThing- Parameters:
state- The state to add properties to.animation- The current AnimationInfo.
-
getItemRating
public int getItemRating()
Returns an item value for ComputerFigures rating in the items category.- Overrides:
getItemRatingin classItem- Returns:
- getCount() * 1000.
-
getImageName
public java.lang.String getImageName(AnimationInfo animation)
Returns image name.- Overrides:
getImageNamein classThing- Parameters:
animation- The AnimationInfo.- Returns:
- "item_doubleshields","item_doubleshields1" or "item_doubleshields2"
-
getCount
protected int getCount()
Gets the shield factor (0 = 2x, 1 = 4x, 2 = 8x).- Returns:
- The shield factor.
-
onBePickedUp
public boolean onBePickedUp(Figure picker, AnimationInfo animation)
Increases all owners shielding.- Overrides:
onBePickedUpin classItem- Parameters:
picker- The pickeranimation- The AnimationInfo.- Returns:
- false.
-
-