Class Index | File Index

Classes


Class ZocCalculator

ZocCalculator
Defined in: zocCalculator.js.

Class Summary
Constructor Attributes Constructor Name and Description
 
ZocCalculator(wargame, force, terrain, map)
ZocCalculator
Method Summary
Method Attributes Method Name and Description
 
hexagonIsZOC(force, hexagonPoint)
method to calculate if hexagon is ZOC
 
setMapType(mapType)
method to set map type
 
method to calculate if unit can be attacked
 
unitIsZOC(unit)
method to calculate if unit is ZOC
 
method to calculate if unit is ZOC using unit id
Class Detail
ZocCalculator(wargame, force, terrain, map)
ZocCalculator
Parameters:
wargame
{object}
force
{object}
terrain
{object}
map
{object}
Method Detail
{boolean} hexagonIsZOC(force, hexagonPoint)
method to calculate if hexagon is ZOC
Parameters:
{integer} force
index
{point} hexagonPoint
Returns:
{boolean} isZOC

setMapType(mapType)
method to set map type
Parameters:
{string} mapType

{boolean} unitCanBeAttacked(unit)
method to calculate if unit can be attacked
Parameters:
{string} unit
id
Returns:
{boolean} canBeAttacked

{boolean} unitIsZOC(unit)
method to calculate if unit is ZOC
Parameters:
{integer} unit
index
Returns:
{boolean} isZOC

{boolean} unitIsZOCbyId(unit)
method to calculate if unit is ZOC using unit id
Parameters:
{string} unit
id
Returns:
{boolean} isZOC

Documentation generated by JsDoc Toolkit 2.4.0 on Mon Oct 22 2018 10:52:11 GMT-0700 (PDT)