public class CarAvatar extends OrientedAvatar
Modifier and Type | Field and Description |
---|---|
double |
angle_diff |
double |
facing |
actions, actionsNIL, is_disqualified, lastMovementType, player
autotiling, bucket, bucketSharp, color, cooldown, currentFrame, draw_arrow, frameRate, frameRemaining, friction, gravity, healthPoints, hidden, hMult, image, images, img, invisible, is_avatar, is_from_avatar, is_npc, is_oriented, is_resource, is_static, is_stochastic, isFirstTick, itypes, jump_strength, lastmove, lastrect, limitHealthPoints, mass, max_speed, maxHealthPoints, name, on_ground, only_active, orientation, orientedImg, physics, physicstype, portal, randomtiling, rect, resources, rotateInPlace, rotation, shrinkfactor, singleton, size, solid, speed, spriteID, stationary, timeToLive, wMult
Constructor and Description |
---|
CarAvatar() |
CarAvatar(Vector2d position,
java.awt.Dimension size,
SpriteContent cnt) |
Modifier and Type | Method and Description |
---|---|
void |
aim() |
void |
applyMovement(Game game,
Direction action) |
VGDLSprite |
copy()
Creates a copy of this sprite.
|
void |
copyTo(VGDLSprite target)
Copies the attributes of this object to the one passed as parameter.
|
protected void |
loadDefaults()
Loads the default values for this sprite.
|
void |
move() |
void |
updateAvatar(Game game,
boolean requestInput,
boolean[] actionMask)
This update call is for the game tick() loop.
|
addScore, disqualify, getKeyHandler, getPlayerID, getScore, getWinState, is_disqualified, postProcess, requestPlayerInput, setKeyHandler, setPlayerID, setScore, setWinState, updateUse
_draw, _drawHealthBar, _drawImage, _drawOriented, _drawResources, _updateOrientation, _updatePos, _updateRotation, _velocity, draw, equiv, getAmountResource, getDependentSprites, getLastPosition, getPosition, getType, groundIntersects, init, intersects, is_disabled, lastDirection, loadImage, modifyResource, parseParameters, preMovement, removeResource, setDisabled, setFromAvatar, setRect, setRect, subtractResource, toString, update, updateBucket, updatePassive
public CarAvatar()
public CarAvatar(Vector2d position, java.awt.Dimension size, SpriteContent cnt)
protected void loadDefaults()
VGDLSprite
loadDefaults
in class OrientedAvatar
public void updateAvatar(Game game, boolean requestInput, boolean[] actionMask)
updateAvatar
in class OrientedAvatar
game
- current state of the game.public void applyMovement(Game game, Direction action)
applyMovement
in class MovingAvatar
public void aim()
public void move()
public VGDLSprite copy()
VGDLSprite
copy
in class OrientedAvatar
public void copyTo(VGDLSprite target)
VGDLSprite
copyTo
in class OrientedAvatar
target
- the sprite to copy to.