NinjaSceneryThrower

NinjaSceneryThrower

A BasicNinja that also can pick up and throw SceneryObjects


Constructor

new NinjaSceneryThrower(x, y, width, height, map, ca, dontCloneMap, dt, tWidth, tHeight, mr, mc)

Parameters:
Name Type Description
x
y
width
height
map
ca
dontCloneMap
dt
tWidth
tHeight
mr
mc

Members

_canvasAnimation

_displayStorageClearRect

_holdingHelperRect

_outAltered

_removedFromStorage

constructor

health

holding

holdingOffsetX

holdingOffsetY

holdingRect

holdings

nameOfThrower

throwStrength

Methods

_readyNextThrow()

_throwHolding()

alteredPosition(xAlterAmount, yAlterAmount) → {MoverPoint}

Parameters:
Name Type Description
xAlterAmount
yAlterAmount
Returns:
Type
MoverPoint

displayStorage(img, cameraLayer, backgroundFromRect, bgx, bgy, tw, th, stx, sty, descriptions)

Parameters:
Name Type Description
img
cameraLayer
backgroundFromRect
bgx
bgy
tw
th
stx
sty
descriptions

holdingImageRect() → {Rectangle}

Returns:
Type
Rectangle

pickUp(obj, imageWidthAdjust, imageHeightAdjust) → {Boolean}

Parameters:
Name Type Description
obj
imageWidthAdjust
imageHeightAdjust
Returns:
Type
Boolean

pickUpAndStore(obj, imageWidthAdjust, imageHeightAdjust, dontReadyThrow) → {Boolean}

Parameters:
Name Type Description
obj
imageWidthAdjust
imageHeightAdjust
dontReadyThrow
Returns:
Type
Boolean

pickUpAndStoreTileData(obj, imageWidthAdjust, imageHeightAdjust, dontReadyThrow) → {Boolean}

Parameters:
Name Type Description
obj
imageWidthAdjust
imageHeightAdjust
dontReadyThrow
Returns:
Type
Boolean

pickUpTileData(td, imageWidthAdjust, imageHeightAdjust) → {Boolean}

Parameters:
Name Type Description
td
imageWidthAdjust
imageHeightAdjust
Returns:
Type
Boolean

rectFromHolding(holdin) → {Rectangle}

Parameters:
Name Type Description
holdin
Returns:
Type
Rectangle

removeFromDisplayedStorage(e)

Parameters:
Name Type Description
e

removeFromStorageByValue(tValue)

Parameters:
Name Type Description
tValue Array

removeLastFromStorage() → {Object}

Returns:
Type
Object

throwSceneryObject(w, h, jumps) → {SceneryObject}

Parameters:
Name Type Description
w
h
jumps
Returns:
Type
SceneryObject

throwSceneryObjectTraveler(w, h, jumps) → {SceneryObjectTraveler}

Parameters:
Name Type Description
w
h
jumps
Returns:
Type
SceneryObjectTraveler

valueFromHolding(holdin) → {Object}

Parameters:
Name Type Description
holdin
Returns:
Type
Object