1
0
mirror of https://github.com/tobspr/shapez.io.git synced 2025-06-13 13:04:03 +00:00
tobspr_shapez.io/docs/ast/source/game/components/storage.js.json
2021-02-26 15:20:37 +01:00

11520 lines
287 KiB
JSON

{
"type": "File",
"start": 0,
"end": 2431,
"loc": {
"start": {
"line": 1,
"column": 0
},
"end": {
"line": 93,
"column": 0
}
},
"program": {
"type": "Program",
"start": 0,
"end": 2431,
"loc": {
"start": {
"line": 1,
"column": 0
},
"end": {
"line": 93,
"column": 0
}
},
"sourceType": "module",
"body": [
{
"type": "ImportDeclaration",
"start": 0,
"end": 53,
"loc": {
"start": {
"line": 1,
"column": 0
},
"end": {
"line": 1,
"column": 53
}
},
"specifiers": [
{
"type": "ImportSpecifier",
"start": 9,
"end": 14,
"loc": {
"start": {
"line": 1,
"column": 9
},
"end": {
"line": 1,
"column": 14
}
},
"imported": {
"type": "Identifier",
"start": 9,
"end": 14,
"loc": {
"start": {
"line": 1,
"column": 9
},
"end": {
"line": 1,
"column": 14
},
"identifierName": "types"
},
"name": "types"
},
"local": {
"type": "Identifier",
"start": 9,
"end": 14,
"loc": {
"start": {
"line": 1,
"column": 9
},
"end": {
"line": 1,
"column": 14
},
"identifierName": "types"
},
"name": "types"
}
}
],
"source": {
"type": "StringLiteral",
"start": 22,
"end": 52,
"loc": {
"start": {
"line": 1,
"column": 22
},
"end": {
"line": 1,
"column": 52
}
},
"extra": {
"rawValue": "../../savegame/serialization",
"raw": "\"../../savegame/serialization\""
},
"value": "../../savegame/serialization"
}
},
{
"type": "ImportDeclaration",
"start": 55,
"end": 95,
"loc": {
"start": {
"line": 2,
"column": 0
},
"end": {
"line": 2,
"column": 40
}
},
"specifiers": [
{
"type": "ImportSpecifier",
"start": 64,
"end": 72,
"loc": {
"start": {
"line": 2,
"column": 9
},
"end": {
"line": 2,
"column": 17
}
},
"imported": {
"type": "Identifier",
"start": 64,
"end": 72,
"loc": {
"start": {
"line": 2,
"column": 9
},
"end": {
"line": 2,
"column": 17
},
"identifierName": "BaseItem"
},
"name": "BaseItem"
},
"local": {
"type": "Identifier",
"start": 64,
"end": 72,
"loc": {
"start": {
"line": 2,
"column": 9
},
"end": {
"line": 2,
"column": 17
},
"identifierName": "BaseItem"
},
"name": "BaseItem"
}
}
],
"source": {
"type": "StringLiteral",
"start": 80,
"end": 94,
"loc": {
"start": {
"line": 2,
"column": 25
},
"end": {
"line": 2,
"column": 39
}
},
"extra": {
"rawValue": "../base_item",
"raw": "\"../base_item\""
},
"value": "../base_item"
}
},
{
"type": "ImportDeclaration",
"start": 97,
"end": 138,
"loc": {
"start": {
"line": 3,
"column": 0
},
"end": {
"line": 3,
"column": 41
}
},
"specifiers": [
{
"type": "ImportSpecifier",
"start": 106,
"end": 115,
"loc": {
"start": {
"line": 3,
"column": 9
},
"end": {
"line": 3,
"column": 18
}
},
"imported": {
"type": "Identifier",
"start": 106,
"end": 115,
"loc": {
"start": {
"line": 3,
"column": 9
},
"end": {
"line": 3,
"column": 18
},
"identifierName": "Component"
},
"name": "Component"
},
"local": {
"type": "Identifier",
"start": 106,
"end": 115,
"loc": {
"start": {
"line": 3,
"column": 9
},
"end": {
"line": 3,
"column": 18
},
"identifierName": "Component"
},
"name": "Component"
}
}
],
"source": {
"type": "StringLiteral",
"start": 123,
"end": 137,
"loc": {
"start": {
"line": 3,
"column": 26
},
"end": {
"line": 3,
"column": 40
}
},
"extra": {
"rawValue": "../component",
"raw": "\"../component\""
},
"value": "../component"
}
},
{
"type": "ImportDeclaration",
"start": 140,
"end": 193,
"loc": {
"start": {
"line": 4,
"column": 0
},
"end": {
"line": 4,
"column": 53
}
},
"specifiers": [
{
"type": "ImportSpecifier",
"start": 149,
"end": 166,
"loc": {
"start": {
"line": 4,
"column": 9
},
"end": {
"line": 4,
"column": 26
}
},
"imported": {
"type": "Identifier",
"start": 149,
"end": 166,
"loc": {
"start": {
"line": 4,
"column": 9
},
"end": {
"line": 4,
"column": 26
},
"identifierName": "typeItemSingleton"
},
"name": "typeItemSingleton"
},
"local": {
"type": "Identifier",
"start": 149,
"end": 166,
"loc": {
"start": {
"line": 4,
"column": 9
},
"end": {
"line": 4,
"column": 26
},
"identifierName": "typeItemSingleton"
},
"name": "typeItemSingleton"
}
}
],
"source": {
"type": "StringLiteral",
"start": 174,
"end": 192,
"loc": {
"start": {
"line": 4,
"column": 34
},
"end": {
"line": 4,
"column": 52
}
},
"extra": {
"rawValue": "../item_resolver",
"raw": "\"../item_resolver\""
},
"value": "../item_resolver"
}
},
{
"type": "ImportDeclaration",
"start": 195,
"end": 243,
"loc": {
"start": {
"line": 5,
"column": 0
},
"end": {
"line": 5,
"column": 48
}
},
"specifiers": [
{
"type": "ImportSpecifier",
"start": 204,
"end": 213,
"loc": {
"start": {
"line": 5,
"column": 9
},
"end": {
"line": 5,
"column": 18
}
},
"imported": {
"type": "Identifier",
"start": 204,
"end": 213,
"loc": {
"start": {
"line": 5,
"column": 9
},
"end": {
"line": 5,
"column": 18
},
"identifierName": "ColorItem"
},
"name": "ColorItem"
},
"local": {
"type": "Identifier",
"start": 204,
"end": 213,
"loc": {
"start": {
"line": 5,
"column": 9
},
"end": {
"line": 5,
"column": 18
},
"identifierName": "ColorItem"
},
"name": "ColorItem"
}
}
],
"source": {
"type": "StringLiteral",
"start": 221,
"end": 242,
"loc": {
"start": {
"line": 5,
"column": 26
},
"end": {
"line": 5,
"column": 47
}
},
"extra": {
"rawValue": "../items/color_item",
"raw": "\"../items/color_item\""
},
"value": "../items/color_item"
}
},
{
"type": "ImportDeclaration",
"start": 245,
"end": 293,
"loc": {
"start": {
"line": 6,
"column": 0
},
"end": {
"line": 6,
"column": 48
}
},
"specifiers": [
{
"type": "ImportSpecifier",
"start": 254,
"end": 263,
"loc": {
"start": {
"line": 6,
"column": 9
},
"end": {
"line": 6,
"column": 18
}
},
"imported": {
"type": "Identifier",
"start": 254,
"end": 263,
"loc": {
"start": {
"line": 6,
"column": 9
},
"end": {
"line": 6,
"column": 18
},
"identifierName": "ShapeItem"
},
"name": "ShapeItem"
},
"local": {
"type": "Identifier",
"start": 254,
"end": 263,
"loc": {
"start": {
"line": 6,
"column": 9
},
"end": {
"line": 6,
"column": 18
},
"identifierName": "ShapeItem"
},
"name": "ShapeItem"
}
}
],
"source": {
"type": "StringLiteral",
"start": 271,
"end": 292,
"loc": {
"start": {
"line": 6,
"column": 26
},
"end": {
"line": 6,
"column": 47
}
},
"extra": {
"rawValue": "../items/shape_item",
"raw": "\"../items/shape_item\""
},
"value": "../items/shape_item"
}
},
{
"type": "ExportNamedDeclaration",
"start": 297,
"end": 2429,
"loc": {
"start": {
"line": 8,
"column": 0
},
"end": {
"line": 92,
"column": 1
}
},
"specifiers": [],
"source": null,
"declaration": {
"type": "ClassDeclaration",
"start": 304,
"end": 2429,
"loc": {
"start": {
"line": 8,
"column": 7
},
"end": {
"line": 92,
"column": 1
}
},
"id": {
"type": "Identifier",
"start": 310,
"end": 326,
"loc": {
"start": {
"line": 8,
"column": 13
},
"end": {
"line": 8,
"column": 29
},
"identifierName": "StorageComponent"
},
"name": "StorageComponent"
},
"superClass": {
"type": "Identifier",
"start": 335,
"end": 344,
"loc": {
"start": {
"line": 8,
"column": 38
},
"end": {
"line": 8,
"column": 47
},
"identifierName": "Component"
},
"name": "Component"
},
"body": {
"type": "ClassBody",
"start": 345,
"end": 2429,
"loc": {
"start": {
"line": 8,
"column": 48
},
"end": {
"line": 92,
"column": 1
}
},
"body": [
{
"type": "ClassMethod",
"start": 352,
"end": 402,
"loc": {
"start": {
"line": 9,
"column": 4
},
"end": {
"line": 11,
"column": 5
}
},
"static": true,
"computed": false,
"key": {
"type": "Identifier",
"start": 359,
"end": 364,
"loc": {
"start": {
"line": 9,
"column": 11
},
"end": {
"line": 9,
"column": 16
},
"identifierName": "getId"
},
"name": "getId"
},
"kind": "method",
"id": null,
"generator": false,
"expression": false,
"async": false,
"params": [],
"body": {
"type": "BlockStatement",
"start": 367,
"end": 402,
"loc": {
"start": {
"line": 9,
"column": 19
},
"end": {
"line": 11,
"column": 5
}
},
"body": [
{
"type": "ReturnStatement",
"start": 378,
"end": 395,
"loc": {
"start": {
"line": 10,
"column": 8
},
"end": {
"line": 10,
"column": 25
}
},
"argument": {
"type": "StringLiteral",
"start": 385,
"end": 394,
"loc": {
"start": {
"line": 10,
"column": 15
},
"end": {
"line": 10,
"column": 24
}
},
"extra": {
"rawValue": "Storage",
"raw": "\"Storage\""
},
"value": "Storage"
}
}
],
"directives": []
}
},
{
"type": "ClassMethod",
"start": 410,
"end": 565,
"loc": {
"start": {
"line": 13,
"column": 4
},
"end": {
"line": 18,
"column": 5
}
},
"static": true,
"computed": false,
"key": {
"type": "Identifier",
"start": 417,
"end": 426,
"loc": {
"start": {
"line": 13,
"column": 11
},
"end": {
"line": 13,
"column": 20
},
"identifierName": "getSchema"
},
"name": "getSchema"
},
"kind": "method",
"id": null,
"generator": false,
"expression": false,
"async": false,
"params": [],
"body": {
"type": "BlockStatement",
"start": 429,
"end": 565,
"loc": {
"start": {
"line": 13,
"column": 23
},
"end": {
"line": 18,
"column": 5
}
},
"body": [
{
"type": "ReturnStatement",
"start": 440,
"end": 558,
"loc": {
"start": {
"line": 14,
"column": 8
},
"end": {
"line": 17,
"column": 10
}
},
"argument": {
"type": "ObjectExpression",
"start": 447,
"end": 557,
"loc": {
"start": {
"line": 14,
"column": 15
},
"end": {
"line": 17,
"column": 9
}
},
"properties": [
{
"type": "ObjectProperty",
"start": 462,
"end": 485,
"loc": {
"start": {
"line": 15,
"column": 12
},
"end": {
"line": 15,
"column": 35
}
},
"method": false,
"shorthand": false,
"computed": false,
"key": {
"type": "Identifier",
"start": 462,
"end": 473,
"loc": {
"start": {
"line": 15,
"column": 12
},
"end": {
"line": 15,
"column": 23
},
"identifierName": "storedCount"
},
"name": "storedCount"
},
"value": {
"type": "MemberExpression",
"start": 475,
"end": 485,
"loc": {
"start": {
"line": 15,
"column": 25
},
"end": {
"line": 15,
"column": 35
}
},
"object": {
"type": "Identifier",
"start": 475,
"end": 480,
"loc": {
"start": {
"line": 15,
"column": 25
},
"end": {
"line": 15,
"column": 30
},
"identifierName": "types"
},
"name": "types"
},
"property": {
"type": "Identifier",
"start": 481,
"end": 485,
"loc": {
"start": {
"line": 15,
"column": 31
},
"end": {
"line": 15,
"column": 35
},
"identifierName": "uint"
},
"name": "uint"
},
"computed": false
}
},
{
"type": "ObjectProperty",
"start": 500,
"end": 545,
"loc": {
"start": {
"line": 16,
"column": 12
},
"end": {
"line": 16,
"column": 57
}
},
"method": false,
"shorthand": false,
"computed": false,
"key": {
"type": "Identifier",
"start": 500,
"end": 510,
"loc": {
"start": {
"line": 16,
"column": 12
},
"end": {
"line": 16,
"column": 22
},
"identifierName": "storedItem"
},
"name": "storedItem"
},
"value": {
"type": "CallExpression",
"start": 512,
"end": 545,
"loc": {
"start": {
"line": 16,
"column": 24
},
"end": {
"line": 16,
"column": 57
}
},
"callee": {
"type": "MemberExpression",
"start": 512,
"end": 526,
"loc": {
"start": {
"line": 16,
"column": 24
},
"end": {
"line": 16,
"column": 38
}
},
"object": {
"type": "Identifier",
"start": 512,
"end": 517,
"loc": {
"start": {
"line": 16,
"column": 24
},
"end": {
"line": 16,
"column": 29
},
"identifierName": "types"
},
"name": "types"
},
"property": {
"type": "Identifier",
"start": 518,
"end": 526,
"loc": {
"start": {
"line": 16,
"column": 30
},
"end": {
"line": 16,
"column": 38
},
"identifierName": "nullable"
},
"name": "nullable"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"start": 527,
"end": 544,
"loc": {
"start": {
"line": 16,
"column": 39
},
"end": {
"line": 16,
"column": 56
},
"identifierName": "typeItemSingleton"
},
"name": "typeItemSingleton"
}
]
}
}
]
}
}
],
"directives": [],
"trailingComments": null
},
"trailingComments": [
{
"type": "CommentBlock",
"value": "*\r\n * @param {object} param0\r\n * @param {number=} param0.maximumStorage How much this storage can hold\r\n ",
"start": 573,
"end": 694,
"loc": {
"start": {
"line": 20,
"column": 4
},
"end": {
"line": 23,
"column": 7
}
}
}
]
},
{
"type": "ClassMethod",
"start": 700,
"end": 1172,
"loc": {
"start": {
"line": 24,
"column": 4
},
"end": {
"line": 43,
"column": 5
}
},
"static": false,
"computed": false,
"key": {
"type": "Identifier",
"start": 700,
"end": 711,
"loc": {
"start": {
"line": 24,
"column": 4
},
"end": {
"line": 24,
"column": 15
},
"identifierName": "constructor"
},
"name": "constructor",
"leadingComments": null
},
"kind": "constructor",
"id": null,
"generator": false,
"expression": false,
"async": false,
"params": [
{
"type": "ObjectPattern",
"start": 712,
"end": 737,
"loc": {
"start": {
"line": 24,
"column": 16
},
"end": {
"line": 24,
"column": 41
}
},
"properties": [
{
"type": "ObjectProperty",
"start": 714,
"end": 735,
"loc": {
"start": {
"line": 24,
"column": 18
},
"end": {
"line": 24,
"column": 39
}
},
"method": false,
"shorthand": true,
"computed": false,
"key": {
"type": "Identifier",
"start": 714,
"end": 728,
"loc": {
"start": {
"line": 24,
"column": 18
},
"end": {
"line": 24,
"column": 32
},
"identifierName": "maximumStorage"
},
"name": "maximumStorage"
},
"value": {
"type": "AssignmentPattern",
"start": 714,
"end": 735,
"loc": {
"start": {
"line": 24,
"column": 18
},
"end": {
"line": 24,
"column": 39
}
},
"left": {
"type": "Identifier",
"start": 714,
"end": 728,
"loc": {
"start": {
"line": 24,
"column": 18
},
"end": {
"line": 24,
"column": 32
},
"identifierName": "maximumStorage"
},
"name": "maximumStorage"
},
"right": {
"type": "NumericLiteral",
"start": 731,
"end": 735,
"loc": {
"start": {
"line": 24,
"column": 35
},
"end": {
"line": 24,
"column": 39
}
},
"extra": {
"rawValue": 100000000000000000000,
"raw": "1e20"
},
"value": 100000000000000000000
}
},
"extra": {
"shorthand": true
}
}
]
}
],
"body": {
"type": "BlockStatement",
"start": 739,
"end": 1172,
"loc": {
"start": {
"line": 24,
"column": 43
},
"end": {
"line": 43,
"column": 5
}
},
"body": [
{
"type": "ExpressionStatement",
"start": 750,
"end": 758,
"loc": {
"start": {
"line": 25,
"column": 8
},
"end": {
"line": 25,
"column": 16
}
},
"expression": {
"type": "CallExpression",
"start": 750,
"end": 757,
"loc": {
"start": {
"line": 25,
"column": 8
},
"end": {
"line": 25,
"column": 15
}
},
"callee": {
"type": "Super",
"start": 750,
"end": 755,
"loc": {
"start": {
"line": 25,
"column": 8
},
"end": {
"line": 25,
"column": 13
}
}
},
"arguments": []
}
},
{
"type": "ExpressionStatement",
"start": 768,
"end": 805,
"loc": {
"start": {
"line": 26,
"column": 8
},
"end": {
"line": 26,
"column": 45
}
},
"expression": {
"type": "AssignmentExpression",
"start": 768,
"end": 804,
"loc": {
"start": {
"line": 26,
"column": 8
},
"end": {
"line": 26,
"column": 44
}
},
"operator": "=",
"left": {
"type": "MemberExpression",
"start": 768,
"end": 787,
"loc": {
"start": {
"line": 26,
"column": 8
},
"end": {
"line": 26,
"column": 27
}
},
"object": {
"type": "ThisExpression",
"start": 768,
"end": 772,
"loc": {
"start": {
"line": 26,
"column": 8
},
"end": {
"line": 26,
"column": 12
}
}
},
"property": {
"type": "Identifier",
"start": 773,
"end": 787,
"loc": {
"start": {
"line": 26,
"column": 13
},
"end": {
"line": 26,
"column": 27
},
"identifierName": "maximumStorage"
},
"name": "maximumStorage"
},
"computed": false
},
"right": {
"type": "Identifier",
"start": 790,
"end": 804,
"loc": {
"start": {
"line": 26,
"column": 30
},
"end": {
"line": 26,
"column": 44
},
"identifierName": "maximumStorage"
},
"name": "maximumStorage"
}
},
"trailingComments": [
{
"type": "CommentBlock",
"value": "*\r\n * Currently stored item\r\n * @type {BaseItem}\r\n ",
"start": 817,
"end": 896,
"loc": {
"start": {
"line": 28,
"column": 8
},
"end": {
"line": 31,
"column": 11
}
}
}
]
},
{
"type": "ExpressionStatement",
"start": 906,
"end": 929,
"loc": {
"start": {
"line": 32,
"column": 8
},
"end": {
"line": 32,
"column": 31
}
},
"expression": {
"type": "AssignmentExpression",
"start": 906,
"end": 928,
"loc": {
"start": {
"line": 32,
"column": 8
},
"end": {
"line": 32,
"column": 30
}
},
"operator": "=",
"left": {
"type": "MemberExpression",
"start": 906,
"end": 921,
"loc": {
"start": {
"line": 32,
"column": 8
},
"end": {
"line": 32,
"column": 23
}
},
"object": {
"type": "ThisExpression",
"start": 906,
"end": 910,
"loc": {
"start": {
"line": 32,
"column": 8
},
"end": {
"line": 32,
"column": 12
}
},
"leadingComments": null
},
"property": {
"type": "Identifier",
"start": 911,
"end": 921,
"loc": {
"start": {
"line": 32,
"column": 13
},
"end": {
"line": 32,
"column": 23
},
"identifierName": "storedItem"
},
"name": "storedItem"
},
"computed": false,
"leadingComments": null
},
"right": {
"type": "NullLiteral",
"start": 924,
"end": 928,
"loc": {
"start": {
"line": 32,
"column": 26
},
"end": {
"line": 32,
"column": 30
}
}
},
"leadingComments": null
},
"leadingComments": [
{
"type": "CommentBlock",
"value": "*\r\n * Currently stored item\r\n * @type {BaseItem}\r\n ",
"start": 817,
"end": 896,
"loc": {
"start": {
"line": 28,
"column": 8
},
"end": {
"line": 31,
"column": 11
}
}
}
],
"trailingComments": [
{
"type": "CommentBlock",
"value": "*\r\n * How many of this item we have stored\r\n ",
"start": 941,
"end": 1006,
"loc": {
"start": {
"line": 34,
"column": 8
},
"end": {
"line": 36,
"column": 11
}
}
}
]
},
{
"type": "ExpressionStatement",
"start": 1016,
"end": 1037,
"loc": {
"start": {
"line": 37,
"column": 8
},
"end": {
"line": 37,
"column": 29
}
},
"expression": {
"type": "AssignmentExpression",
"start": 1016,
"end": 1036,
"loc": {
"start": {
"line": 37,
"column": 8
},
"end": {
"line": 37,
"column": 28
}
},
"operator": "=",
"left": {
"type": "MemberExpression",
"start": 1016,
"end": 1032,
"loc": {
"start": {
"line": 37,
"column": 8
},
"end": {
"line": 37,
"column": 24
}
},
"object": {
"type": "ThisExpression",
"start": 1016,
"end": 1020,
"loc": {
"start": {
"line": 37,
"column": 8
},
"end": {
"line": 37,
"column": 12
}
},
"leadingComments": null
},
"property": {
"type": "Identifier",
"start": 1021,
"end": 1032,
"loc": {
"start": {
"line": 37,
"column": 13
},
"end": {
"line": 37,
"column": 24
},
"identifierName": "storedCount"
},
"name": "storedCount"
},
"computed": false,
"leadingComments": null
},
"right": {
"type": "NumericLiteral",
"start": 1035,
"end": 1036,
"loc": {
"start": {
"line": 37,
"column": 27
},
"end": {
"line": 37,
"column": 28
}
},
"extra": {
"rawValue": 0,
"raw": "0"
},
"value": 0
},
"leadingComments": null
},
"leadingComments": [
{
"type": "CommentBlock",
"value": "*\r\n * How many of this item we have stored\r\n ",
"start": 941,
"end": 1006,
"loc": {
"start": {
"line": 34,
"column": 8
},
"end": {
"line": 36,
"column": 11
}
}
}
],
"trailingComments": [
{
"type": "CommentBlock",
"value": "*\r\n * We compute an opacity to make sure it doesn't flicker\r\n ",
"start": 1049,
"end": 1131,
"loc": {
"start": {
"line": 39,
"column": 8
},
"end": {
"line": 41,
"column": 11
}
}
}
]
},
{
"type": "ExpressionStatement",
"start": 1141,
"end": 1165,
"loc": {
"start": {
"line": 42,
"column": 8
},
"end": {
"line": 42,
"column": 32
}
},
"expression": {
"type": "AssignmentExpression",
"start": 1141,
"end": 1164,
"loc": {
"start": {
"line": 42,
"column": 8
},
"end": {
"line": 42,
"column": 31
}
},
"operator": "=",
"left": {
"type": "MemberExpression",
"start": 1141,
"end": 1160,
"loc": {
"start": {
"line": 42,
"column": 8
},
"end": {
"line": 42,
"column": 27
}
},
"object": {
"type": "ThisExpression",
"start": 1141,
"end": 1145,
"loc": {
"start": {
"line": 42,
"column": 8
},
"end": {
"line": 42,
"column": 12
}
},
"leadingComments": null
},
"property": {
"type": "Identifier",
"start": 1146,
"end": 1160,
"loc": {
"start": {
"line": 42,
"column": 13
},
"end": {
"line": 42,
"column": 27
},
"identifierName": "overlayOpacity"
},
"name": "overlayOpacity"
},
"computed": false,
"leadingComments": null
},
"right": {
"type": "NumericLiteral",
"start": 1163,
"end": 1164,
"loc": {
"start": {
"line": 42,
"column": 30
},
"end": {
"line": 42,
"column": 31
}
},
"extra": {
"rawValue": 0,
"raw": "0"
},
"value": 0
},
"leadingComments": null
},
"leadingComments": [
{
"type": "CommentBlock",
"value": "*\r\n * We compute an opacity to make sure it doesn't flicker\r\n ",
"start": 1049,
"end": 1131,
"loc": {
"start": {
"line": 39,
"column": 8
},
"end": {
"line": 41,
"column": 11
}
}
}
]
}
],
"directives": [],
"trailingComments": null
},
"leadingComments": [
{
"type": "CommentBlock",
"value": "*\r\n * @param {object} param0\r\n * @param {number=} param0.maximumStorage How much this storage can hold\r\n ",
"start": 573,
"end": 694,
"loc": {
"start": {
"line": 20,
"column": 4
},
"end": {
"line": 23,
"column": 7
}
}
}
],
"trailingComments": [
{
"type": "CommentBlock",
"value": "*\r\n * Returns whether this storage can accept the item\r\n * @param {BaseItem} item\r\n ",
"start": 1180,
"end": 1280,
"loc": {
"start": {
"line": 45,
"column": 4
},
"end": {
"line": 48,
"column": 7
}
}
}
]
},
{
"type": "ClassMethod",
"start": 1286,
"end": 2110,
"loc": {
"start": {
"line": 49,
"column": 4
},
"end": {
"line": 75,
"column": 5
}
},
"static": false,
"computed": false,
"key": {
"type": "Identifier",
"start": 1286,
"end": 1299,
"loc": {
"start": {
"line": 49,
"column": 4
},
"end": {
"line": 49,
"column": 17
},
"identifierName": "canAcceptItem"
},
"name": "canAcceptItem",
"leadingComments": null
},
"kind": "method",
"id": null,
"generator": false,
"expression": false,
"async": false,
"params": [
{
"type": "Identifier",
"start": 1300,
"end": 1304,
"loc": {
"start": {
"line": 49,
"column": 18
},
"end": {
"line": 49,
"column": 22
},
"identifierName": "item"
},
"name": "item"
}
],
"body": {
"type": "BlockStatement",
"start": 1306,
"end": 2110,
"loc": {
"start": {
"line": 49,
"column": 24
},
"end": {
"line": 75,
"column": 5
}
},
"body": [
{
"type": "IfStatement",
"start": 1317,
"end": 1401,
"loc": {
"start": {
"line": 50,
"column": 8
},
"end": {
"line": 52,
"column": 9
}
},
"test": {
"type": "BinaryExpression",
"start": 1321,
"end": 1360,
"loc": {
"start": {
"line": 50,
"column": 12
},
"end": {
"line": 50,
"column": 51
}
},
"left": {
"type": "MemberExpression",
"start": 1321,
"end": 1337,
"loc": {
"start": {
"line": 50,
"column": 12
},
"end": {
"line": 50,
"column": 28
}
},
"object": {
"type": "ThisExpression",
"start": 1321,
"end": 1325,
"loc": {
"start": {
"line": 50,
"column": 12
},
"end": {
"line": 50,
"column": 16
}
}
},
"property": {
"type": "Identifier",
"start": 1326,
"end": 1337,
"loc": {
"start": {
"line": 50,
"column": 17
},
"end": {
"line": 50,
"column": 28
},
"identifierName": "storedCount"
},
"name": "storedCount"
},
"computed": false
},
"operator": ">=",
"right": {
"type": "MemberExpression",
"start": 1341,
"end": 1360,
"loc": {
"start": {
"line": 50,
"column": 32
},
"end": {
"line": 50,
"column": 51
}
},
"object": {
"type": "ThisExpression",
"start": 1341,
"end": 1345,
"loc": {
"start": {
"line": 50,
"column": 32
},
"end": {
"line": 50,
"column": 36
}
}
},
"property": {
"type": "Identifier",
"start": 1346,
"end": 1360,
"loc": {
"start": {
"line": 50,
"column": 37
},
"end": {
"line": 50,
"column": 51
},
"identifierName": "maximumStorage"
},
"name": "maximumStorage"
},
"computed": false
}
},
"consequent": {
"type": "BlockStatement",
"start": 1362,
"end": 1401,
"loc": {
"start": {
"line": 50,
"column": 53
},
"end": {
"line": 52,
"column": 9
}
},
"body": [
{
"type": "ReturnStatement",
"start": 1377,
"end": 1390,
"loc": {
"start": {
"line": 51,
"column": 12
},
"end": {
"line": 51,
"column": 25
}
},
"argument": {
"type": "BooleanLiteral",
"start": 1384,
"end": 1389,
"loc": {
"start": {
"line": 51,
"column": 19
},
"end": {
"line": 51,
"column": 24
}
},
"value": false
}
}
],
"directives": []
},
"alternate": null
},
{
"type": "IfStatement",
"start": 1411,
"end": 1497,
"loc": {
"start": {
"line": 53,
"column": 8
},
"end": {
"line": 55,
"column": 9
}
},
"test": {
"type": "LogicalExpression",
"start": 1415,
"end": 1457,
"loc": {
"start": {
"line": 53,
"column": 12
},
"end": {
"line": 53,
"column": 54
}
},
"left": {
"type": "UnaryExpression",
"start": 1415,
"end": 1431,
"loc": {
"start": {
"line": 53,
"column": 12
},
"end": {
"line": 53,
"column": 28
}
},
"operator": "!",
"prefix": true,
"argument": {
"type": "MemberExpression",
"start": 1416,
"end": 1431,
"loc": {
"start": {
"line": 53,
"column": 13
},
"end": {
"line": 53,
"column": 28
}
},
"object": {
"type": "ThisExpression",
"start": 1416,
"end": 1420,
"loc": {
"start": {
"line": 53,
"column": 13
},
"end": {
"line": 53,
"column": 17
}
}
},
"property": {
"type": "Identifier",
"start": 1421,
"end": 1431,
"loc": {
"start": {
"line": 53,
"column": 18
},
"end": {
"line": 53,
"column": 28
},
"identifierName": "storedItem"
},
"name": "storedItem"
},
"computed": false
},
"extra": {
"parenthesizedArgument": false
}
},
"operator": "||",
"right": {
"type": "BinaryExpression",
"start": 1435,
"end": 1457,
"loc": {
"start": {
"line": 53,
"column": 32
},
"end": {
"line": 53,
"column": 54
}
},
"left": {
"type": "MemberExpression",
"start": 1435,
"end": 1451,
"loc": {
"start": {
"line": 53,
"column": 32
},
"end": {
"line": 53,
"column": 48
}
},
"object": {
"type": "ThisExpression",
"start": 1435,
"end": 1439,
"loc": {
"start": {
"line": 53,
"column": 32
},
"end": {
"line": 53,
"column": 36
}
}
},
"property": {
"type": "Identifier",
"start": 1440,
"end": 1451,
"loc": {
"start": {
"line": 53,
"column": 37
},
"end": {
"line": 53,
"column": 48
},
"identifierName": "storedCount"
},
"name": "storedCount"
},
"computed": false
},
"operator": "===",
"right": {
"type": "NumericLiteral",
"start": 1456,
"end": 1457,
"loc": {
"start": {
"line": 53,
"column": 53
},
"end": {
"line": 53,
"column": 54
}
},
"extra": {
"rawValue": 0,
"raw": "0"
},
"value": 0
}
}
},
"consequent": {
"type": "BlockStatement",
"start": 1459,
"end": 1497,
"loc": {
"start": {
"line": 53,
"column": 56
},
"end": {
"line": 55,
"column": 9
}
},
"body": [
{
"type": "ReturnStatement",
"start": 1474,
"end": 1486,
"loc": {
"start": {
"line": 54,
"column": 12
},
"end": {
"line": 54,
"column": 24
}
},
"argument": {
"type": "BooleanLiteral",
"start": 1481,
"end": 1485,
"loc": {
"start": {
"line": 54,
"column": 19
},
"end": {
"line": 54,
"column": 23
}
},
"value": true
}
}
],
"directives": []
},
"alternate": null
},
{
"type": "VariableDeclaration",
"start": 1509,
"end": 1545,
"loc": {
"start": {
"line": 57,
"column": 8
},
"end": {
"line": 57,
"column": 44
}
},
"declarations": [
{
"type": "VariableDeclarator",
"start": 1515,
"end": 1544,
"loc": {
"start": {
"line": 57,
"column": 14
},
"end": {
"line": 57,
"column": 43
}
},
"id": {
"type": "Identifier",
"start": 1515,
"end": 1523,
"loc": {
"start": {
"line": 57,
"column": 14
},
"end": {
"line": 57,
"column": 22
},
"identifierName": "itemType"
},
"name": "itemType"
},
"init": {
"type": "CallExpression",
"start": 1526,
"end": 1544,
"loc": {
"start": {
"line": 57,
"column": 25
},
"end": {
"line": 57,
"column": 43
}
},
"callee": {
"type": "MemberExpression",
"start": 1526,
"end": 1542,
"loc": {
"start": {
"line": 57,
"column": 25
},
"end": {
"line": 57,
"column": 41
}
},
"object": {
"type": "Identifier",
"start": 1526,
"end": 1530,
"loc": {
"start": {
"line": 57,
"column": 25
},
"end": {
"line": 57,
"column": 29
},
"identifierName": "item"
},
"name": "item"
},
"property": {
"type": "Identifier",
"start": 1531,
"end": 1542,
"loc": {
"start": {
"line": 57,
"column": 30
},
"end": {
"line": 57,
"column": 41
},
"identifierName": "getItemType"
},
"name": "getItemType"
},
"computed": false
},
"arguments": []
}
}
],
"kind": "const",
"trailingComments": [
{
"type": "CommentLine",
"value": " Check type matches",
"start": 1557,
"end": 1578,
"loc": {
"start": {
"line": 59,
"column": 8
},
"end": {
"line": 59,
"column": 29
}
}
}
]
},
{
"type": "IfStatement",
"start": 1588,
"end": 1675,
"loc": {
"start": {
"line": 60,
"column": 8
},
"end": {
"line": 62,
"column": 9
}
},
"test": {
"type": "BinaryExpression",
"start": 1592,
"end": 1634,
"loc": {
"start": {
"line": 60,
"column": 12
},
"end": {
"line": 60,
"column": 54
}
},
"left": {
"type": "Identifier",
"start": 1592,
"end": 1600,
"loc": {
"start": {
"line": 60,
"column": 12
},
"end": {
"line": 60,
"column": 20
},
"identifierName": "itemType"
},
"name": "itemType",
"leadingComments": null
},
"operator": "!==",
"right": {
"type": "CallExpression",
"start": 1605,
"end": 1634,
"loc": {
"start": {
"line": 60,
"column": 25
},
"end": {
"line": 60,
"column": 54
}
},
"callee": {
"type": "MemberExpression",
"start": 1605,
"end": 1632,
"loc": {
"start": {
"line": 60,
"column": 25
},
"end": {
"line": 60,
"column": 52
}
},
"object": {
"type": "MemberExpression",
"start": 1605,
"end": 1620,
"loc": {
"start": {
"line": 60,
"column": 25
},
"end": {
"line": 60,
"column": 40
}
},
"object": {
"type": "ThisExpression",
"start": 1605,
"end": 1609,
"loc": {
"start": {
"line": 60,
"column": 25
},
"end": {
"line": 60,
"column": 29
}
}
},
"property": {
"type": "Identifier",
"start": 1610,
"end": 1620,
"loc": {
"start": {
"line": 60,
"column": 30
},
"end": {
"line": 60,
"column": 40
},
"identifierName": "storedItem"
},
"name": "storedItem"
},
"computed": false
},
"property": {
"type": "Identifier",
"start": 1621,
"end": 1632,
"loc": {
"start": {
"line": 60,
"column": 41
},
"end": {
"line": 60,
"column": 52
},
"identifierName": "getItemType"
},
"name": "getItemType"
},
"computed": false
},
"arguments": []
},
"leadingComments": null
},
"consequent": {
"type": "BlockStatement",
"start": 1636,
"end": 1675,
"loc": {
"start": {
"line": 60,
"column": 56
},
"end": {
"line": 62,
"column": 9
}
},
"body": [
{
"type": "ReturnStatement",
"start": 1651,
"end": 1664,
"loc": {
"start": {
"line": 61,
"column": 12
},
"end": {
"line": 61,
"column": 25
}
},
"argument": {
"type": "BooleanLiteral",
"start": 1658,
"end": 1663,
"loc": {
"start": {
"line": 61,
"column": 19
},
"end": {
"line": 61,
"column": 24
}
},
"value": false
}
}
],
"directives": []
},
"alternate": null,
"leadingComments": [
{
"type": "CommentLine",
"value": " Check type matches",
"start": 1557,
"end": 1578,
"loc": {
"start": {
"line": 59,
"column": 8
},
"end": {
"line": 59,
"column": 29
}
}
}
]
},
{
"type": "IfStatement",
"start": 1687,
"end": 1837,
"loc": {
"start": {
"line": 64,
"column": 8
},
"end": {
"line": 66,
"column": 9
}
},
"test": {
"type": "BinaryExpression",
"start": 1691,
"end": 1711,
"loc": {
"start": {
"line": 64,
"column": 12
},
"end": {
"line": 64,
"column": 32
}
},
"left": {
"type": "Identifier",
"start": 1691,
"end": 1699,
"loc": {
"start": {
"line": 64,
"column": 12
},
"end": {
"line": 64,
"column": 20
},
"identifierName": "itemType"
},
"name": "itemType"
},
"operator": "===",
"right": {
"type": "StringLiteral",
"start": 1704,
"end": 1711,
"loc": {
"start": {
"line": 64,
"column": 25
},
"end": {
"line": 64,
"column": 32
}
},
"extra": {
"rawValue": "color",
"raw": "\"color\""
},
"value": "color"
}
},
"consequent": {
"type": "BlockStatement",
"start": 1713,
"end": 1837,
"loc": {
"start": {
"line": 64,
"column": 34
},
"end": {
"line": 66,
"column": 9
}
},
"body": [
{
"type": "ReturnStatement",
"start": 1728,
"end": 1826,
"loc": {
"start": {
"line": 65,
"column": 12
},
"end": {
"line": 65,
"column": 110
}
},
"argument": {
"type": "BinaryExpression",
"start": 1760,
"end": 1825,
"loc": {
"start": {
"line": 65,
"column": 44
},
"end": {
"line": 65,
"column": 109
}
},
"left": {
"type": "MemberExpression",
"start": 1760,
"end": 1783,
"loc": {
"start": {
"line": 65,
"column": 44
},
"end": {
"line": 65,
"column": 67
}
},
"object": {
"type": "MemberExpression",
"start": 1761,
"end": 1776,
"loc": {
"start": {
"line": 65,
"column": 45
},
"end": {
"line": 65,
"column": 60
}
},
"object": {
"type": "ThisExpression",
"start": 1761,
"end": 1765,
"loc": {
"start": {
"line": 65,
"column": 45
},
"end": {
"line": 65,
"column": 49
}
},
"leadingComments": null
},
"property": {
"type": "Identifier",
"start": 1766,
"end": 1776,
"loc": {
"start": {
"line": 65,
"column": 50
},
"end": {
"line": 65,
"column": 60
},
"identifierName": "storedItem"
},
"name": "storedItem"
},
"computed": false,
"leadingComments": null,
"extra": {
"parenthesized": true,
"parenStart": 1760
}
},
"property": {
"type": "Identifier",
"start": 1778,
"end": 1783,
"loc": {
"start": {
"line": 65,
"column": 62
},
"end": {
"line": 65,
"column": 67
},
"identifierName": "color"
},
"name": "color"
},
"computed": false,
"leadingComments": null
},
"operator": "===",
"right": {
"type": "MemberExpression",
"start": 1813,
"end": 1825,
"loc": {
"start": {
"line": 65,
"column": 97
},
"end": {
"line": 65,
"column": 109
}
},
"object": {
"type": "Identifier",
"start": 1814,
"end": 1818,
"loc": {
"start": {
"line": 65,
"column": 98
},
"end": {
"line": 65,
"column": 102
},
"identifierName": "item"
},
"name": "item",
"leadingComments": null,
"extra": {
"parenthesized": true,
"parenStart": 1813
}
},
"property": {
"type": "Identifier",
"start": 1820,
"end": 1825,
"loc": {
"start": {
"line": 65,
"column": 104
},
"end": {
"line": 65,
"column": 109
},
"identifierName": "color"
},
"name": "color"
},
"computed": false,
"leadingComments": [
{
"type": "CommentBlock",
"value": "* @type {ColorItem} ",
"start": 1788,
"end": 1812,
"loc": {
"start": {
"line": 65,
"column": 72
},
"end": {
"line": 65,
"column": 96
}
}
}
]
},
"leadingComments": [
{
"type": "CommentBlock",
"value": "* @type {ColorItem} ",
"start": 1735,
"end": 1759,
"loc": {
"start": {
"line": 65,
"column": 19
},
"end": {
"line": 65,
"column": 43
}
}
}
]
}
}
],
"directives": []
},
"alternate": null
},
{
"type": "IfStatement",
"start": 1849,
"end": 2080,
"loc": {
"start": {
"line": 68,
"column": 8
},
"end": {
"line": 73,
"column": 9
}
},
"test": {
"type": "BinaryExpression",
"start": 1853,
"end": 1873,
"loc": {
"start": {
"line": 68,
"column": 12
},
"end": {
"line": 68,
"column": 32
}
},
"left": {
"type": "Identifier",
"start": 1853,
"end": 1861,
"loc": {
"start": {
"line": 68,
"column": 12
},
"end": {
"line": 68,
"column": 20
},
"identifierName": "itemType"
},
"name": "itemType"
},
"operator": "===",
"right": {
"type": "StringLiteral",
"start": 1866,
"end": 1873,
"loc": {
"start": {
"line": 68,
"column": 25
},
"end": {
"line": 68,
"column": 32
}
},
"extra": {
"rawValue": "shape",
"raw": "\"shape\""
},
"value": "shape"
}
},
"consequent": {
"type": "BlockStatement",
"start": 1875,
"end": 2080,
"loc": {
"start": {
"line": 68,
"column": 34
},
"end": {
"line": 73,
"column": 9
}
},
"body": [
{
"type": "ReturnStatement",
"start": 1890,
"end": 2069,
"loc": {
"start": {
"line": 69,
"column": 12
},
"end": {
"line": 72,
"column": 14
}
},
"argument": {
"type": "BinaryExpression",
"start": 1941,
"end": 2053,
"loc": {
"start": {
"line": 70,
"column": 41
},
"end": {
"line": 71,
"column": 68
}
},
"left": {
"type": "CallExpression",
"start": 1941,
"end": 1979,
"loc": {
"start": {
"line": 70,
"column": 41
},
"end": {
"line": 70,
"column": 79
}
},
"callee": {
"type": "MemberExpression",
"start": 1941,
"end": 1977,
"loc": {
"start": {
"line": 70,
"column": 41
},
"end": {
"line": 70,
"column": 77
}
},
"object": {
"type": "MemberExpression",
"start": 1941,
"end": 1969,
"loc": {
"start": {
"line": 70,
"column": 41
},
"end": {
"line": 70,
"column": 69
}
},
"object": {
"type": "MemberExpression",
"start": 1942,
"end": 1957,
"loc": {
"start": {
"line": 70,
"column": 42
},
"end": {
"line": 70,
"column": 57
}
},
"object": {
"type": "ThisExpression",
"start": 1942,
"end": 1946,
"loc": {
"start": {
"line": 70,
"column": 42
},
"end": {
"line": 70,
"column": 46
}
},
"leadingComments": null
},
"property": {
"type": "Identifier",
"start": 1947,
"end": 1957,
"loc": {
"start": {
"line": 70,
"column": 47
},
"end": {
"line": 70,
"column": 57
},
"identifierName": "storedItem"
},
"name": "storedItem"
},
"computed": false,
"leadingComments": null,
"extra": {
"parenthesized": true,
"parenStart": 1941
}
},
"property": {
"type": "Identifier",
"start": 1959,
"end": 1969,
"loc": {
"start": {
"line": 70,
"column": 59
},
"end": {
"line": 70,
"column": 69
},
"identifierName": "definition"
},
"name": "definition"
},
"computed": false,
"leadingComments": null
},
"property": {
"type": "Identifier",
"start": 1970,
"end": 1977,
"loc": {
"start": {
"line": 70,
"column": 70
},
"end": {
"line": 70,
"column": 77
},
"identifierName": "getHash"
},
"name": "getHash"
},
"computed": false,
"leadingComments": null
},
"arguments": [],
"leadingComments": null
},
"operator": "===",
"right": {
"type": "CallExpression",
"start": 2026,
"end": 2053,
"loc": {
"start": {
"line": 71,
"column": 41
},
"end": {
"line": 71,
"column": 68
}
},
"callee": {
"type": "MemberExpression",
"start": 2026,
"end": 2051,
"loc": {
"start": {
"line": 71,
"column": 41
},
"end": {
"line": 71,
"column": 66
}
},
"object": {
"type": "MemberExpression",
"start": 2026,
"end": 2043,
"loc": {
"start": {
"line": 71,
"column": 41
},
"end": {
"line": 71,
"column": 58
}
},
"object": {
"type": "Identifier",
"start": 2027,
"end": 2031,
"loc": {
"start": {
"line": 71,
"column": 42
},
"end": {
"line": 71,
"column": 46
},
"identifierName": "item"
},
"name": "item",
"leadingComments": null,
"extra": {
"parenthesized": true,
"parenStart": 2026
}
},
"property": {
"type": "Identifier",
"start": 2033,
"end": 2043,
"loc": {
"start": {
"line": 71,
"column": 48
},
"end": {
"line": 71,
"column": 58
},
"identifierName": "definition"
},
"name": "definition"
},
"computed": false,
"leadingComments": null
},
"property": {
"type": "Identifier",
"start": 2044,
"end": 2051,
"loc": {
"start": {
"line": 71,
"column": 59
},
"end": {
"line": 71,
"column": 66
},
"identifierName": "getHash"
},
"name": "getHash"
},
"computed": false,
"leadingComments": null
},
"arguments": [],
"leadingComments": [
{
"type": "CommentBlock",
"value": "* @type {ShapeItem} ",
"start": 2001,
"end": 2025,
"loc": {
"start": {
"line": 71,
"column": 16
},
"end": {
"line": 71,
"column": 40
}
}
}
]
},
"leadingComments": [
{
"type": "CommentBlock",
"value": "* @type {ShapeItem} ",
"start": 1916,
"end": 1940,
"loc": {
"start": {
"line": 70,
"column": 16
},
"end": {
"line": 70,
"column": 40
}
}
}
],
"extra": {
"parenthesized": true,
"parenStart": 1897
}
}
}
],
"directives": []
},
"alternate": null
},
{
"type": "ReturnStatement",
"start": 2090,
"end": 2103,
"loc": {
"start": {
"line": 74,
"column": 8
},
"end": {
"line": 74,
"column": 21
}
},
"argument": {
"type": "BooleanLiteral",
"start": 2097,
"end": 2102,
"loc": {
"start": {
"line": 74,
"column": 15
},
"end": {
"line": 74,
"column": 20
}
},
"value": false
}
}
],
"directives": [],
"trailingComments": null
},
"leadingComments": [
{
"type": "CommentBlock",
"value": "*\r\n * Returns whether this storage can accept the item\r\n * @param {BaseItem} item\r\n ",
"start": 1180,
"end": 1280,
"loc": {
"start": {
"line": 45,
"column": 4
},
"end": {
"line": 48,
"column": 7
}
}
}
],
"trailingComments": [
{
"type": "CommentBlock",
"value": "*\r\n * Returns whether the storage is full\r\n * @returns {boolean}\r\n ",
"start": 2118,
"end": 2201,
"loc": {
"start": {
"line": 77,
"column": 4
},
"end": {
"line": 80,
"column": 7
}
}
}
]
},
{
"type": "ClassMethod",
"start": 2207,
"end": 2284,
"loc": {
"start": {
"line": 81,
"column": 4
},
"end": {
"line": 83,
"column": 5
}
},
"static": false,
"computed": false,
"key": {
"type": "Identifier",
"start": 2207,
"end": 2216,
"loc": {
"start": {
"line": 81,
"column": 4
},
"end": {
"line": 81,
"column": 13
},
"identifierName": "getIsFull"
},
"name": "getIsFull",
"leadingComments": null
},
"kind": "method",
"id": null,
"generator": false,
"expression": false,
"async": false,
"params": [],
"body": {
"type": "BlockStatement",
"start": 2219,
"end": 2284,
"loc": {
"start": {
"line": 81,
"column": 16
},
"end": {
"line": 83,
"column": 5
}
},
"body": [
{
"type": "ReturnStatement",
"start": 2230,
"end": 2277,
"loc": {
"start": {
"line": 82,
"column": 8
},
"end": {
"line": 82,
"column": 55
}
},
"argument": {
"type": "BinaryExpression",
"start": 2237,
"end": 2276,
"loc": {
"start": {
"line": 82,
"column": 15
},
"end": {
"line": 82,
"column": 54
}
},
"left": {
"type": "MemberExpression",
"start": 2237,
"end": 2253,
"loc": {
"start": {
"line": 82,
"column": 15
},
"end": {
"line": 82,
"column": 31
}
},
"object": {
"type": "ThisExpression",
"start": 2237,
"end": 2241,
"loc": {
"start": {
"line": 82,
"column": 15
},
"end": {
"line": 82,
"column": 19
}
}
},
"property": {
"type": "Identifier",
"start": 2242,
"end": 2253,
"loc": {
"start": {
"line": 82,
"column": 20
},
"end": {
"line": 82,
"column": 31
},
"identifierName": "storedCount"
},
"name": "storedCount"
},
"computed": false
},
"operator": ">=",
"right": {
"type": "MemberExpression",
"start": 2257,
"end": 2276,
"loc": {
"start": {
"line": 82,
"column": 35
},
"end": {
"line": 82,
"column": 54
}
},
"object": {
"type": "ThisExpression",
"start": 2257,
"end": 2261,
"loc": {
"start": {
"line": 82,
"column": 35
},
"end": {
"line": 82,
"column": 39
}
}
},
"property": {
"type": "Identifier",
"start": 2262,
"end": 2276,
"loc": {
"start": {
"line": 82,
"column": 40
},
"end": {
"line": 82,
"column": 54
},
"identifierName": "maximumStorage"
},
"name": "maximumStorage"
},
"computed": false
}
}
}
],
"directives": [],
"trailingComments": null
},
"leadingComments": [
{
"type": "CommentBlock",
"value": "*\r\n * Returns whether the storage is full\r\n * @returns {boolean}\r\n ",
"start": 2118,
"end": 2201,
"loc": {
"start": {
"line": 77,
"column": 4
},
"end": {
"line": 80,
"column": 7
}
}
}
],
"trailingComments": [
{
"type": "CommentBlock",
"value": "*\r\n * @param {BaseItem} item\r\n ",
"start": 2292,
"end": 2335,
"loc": {
"start": {
"line": 85,
"column": 4
},
"end": {
"line": 87,
"column": 7
}
}
}
]
},
{
"type": "ClassMethod",
"start": 2341,
"end": 2426,
"loc": {
"start": {
"line": 88,
"column": 4
},
"end": {
"line": 91,
"column": 5
}
},
"static": false,
"computed": false,
"key": {
"type": "Identifier",
"start": 2341,
"end": 2349,
"loc": {
"start": {
"line": 88,
"column": 4
},
"end": {
"line": 88,
"column": 12
},
"identifierName": "takeItem"
},
"name": "takeItem",
"leadingComments": null
},
"kind": "method",
"id": null,
"generator": false,
"expression": false,
"async": false,
"params": [
{
"type": "Identifier",
"start": 2350,
"end": 2354,
"loc": {
"start": {
"line": 88,
"column": 13
},
"end": {
"line": 88,
"column": 17
},
"identifierName": "item"
},
"name": "item"
}
],
"body": {
"type": "BlockStatement",
"start": 2356,
"end": 2426,
"loc": {
"start": {
"line": 88,
"column": 19
},
"end": {
"line": 91,
"column": 5
}
},
"body": [
{
"type": "ExpressionStatement",
"start": 2367,
"end": 2390,
"loc": {
"start": {
"line": 89,
"column": 8
},
"end": {
"line": 89,
"column": 31
}
},
"expression": {
"type": "AssignmentExpression",
"start": 2367,
"end": 2389,
"loc": {
"start": {
"line": 89,
"column": 8
},
"end": {
"line": 89,
"column": 30
}
},
"operator": "=",
"left": {
"type": "MemberExpression",
"start": 2367,
"end": 2382,
"loc": {
"start": {
"line": 89,
"column": 8
},
"end": {
"line": 89,
"column": 23
}
},
"object": {
"type": "ThisExpression",
"start": 2367,
"end": 2371,
"loc": {
"start": {
"line": 89,
"column": 8
},
"end": {
"line": 89,
"column": 12
}
}
},
"property": {
"type": "Identifier",
"start": 2372,
"end": 2382,
"loc": {
"start": {
"line": 89,
"column": 13
},
"end": {
"line": 89,
"column": 23
},
"identifierName": "storedItem"
},
"name": "storedItem"
},
"computed": false
},
"right": {
"type": "Identifier",
"start": 2385,
"end": 2389,
"loc": {
"start": {
"line": 89,
"column": 26
},
"end": {
"line": 89,
"column": 30
},
"identifierName": "item"
},
"name": "item"
}
}
},
{
"type": "ExpressionStatement",
"start": 2400,
"end": 2419,
"loc": {
"start": {
"line": 90,
"column": 8
},
"end": {
"line": 90,
"column": 27
}
},
"expression": {
"type": "UpdateExpression",
"start": 2400,
"end": 2418,
"loc": {
"start": {
"line": 90,
"column": 8
},
"end": {
"line": 90,
"column": 26
}
},
"operator": "++",
"prefix": false,
"argument": {
"type": "MemberExpression",
"start": 2400,
"end": 2416,
"loc": {
"start": {
"line": 90,
"column": 8
},
"end": {
"line": 90,
"column": 24
}
},
"object": {
"type": "ThisExpression",
"start": 2400,
"end": 2404,
"loc": {
"start": {
"line": 90,
"column": 8
},
"end": {
"line": 90,
"column": 12
}
}
},
"property": {
"type": "Identifier",
"start": 2405,
"end": 2416,
"loc": {
"start": {
"line": 90,
"column": 13
},
"end": {
"line": 90,
"column": 24
},
"identifierName": "storedCount"
},
"name": "storedCount"
},
"computed": false
}
}
}
],
"directives": []
},
"leadingComments": [
{
"type": "CommentBlock",
"value": "*\r\n * @param {BaseItem} item\r\n ",
"start": 2292,
"end": 2335,
"loc": {
"start": {
"line": 85,
"column": 4
},
"end": {
"line": 87,
"column": 7
}
}
}
]
}
]
},
"leadingComments": [],
"trailingComments": []
}
}
],
"directives": []
},
"comments": [
{
"type": "CommentBlock",
"value": "*\r\n * @param {object} param0\r\n * @param {number=} param0.maximumStorage How much this storage can hold\r\n ",
"start": 573,
"end": 694,
"loc": {
"start": {
"line": 20,
"column": 4
},
"end": {
"line": 23,
"column": 7
}
}
},
{
"type": "CommentBlock",
"value": "*\r\n * Currently stored item\r\n * @type {BaseItem}\r\n ",
"start": 817,
"end": 896,
"loc": {
"start": {
"line": 28,
"column": 8
},
"end": {
"line": 31,
"column": 11
}
}
},
{
"type": "CommentBlock",
"value": "*\r\n * How many of this item we have stored\r\n ",
"start": 941,
"end": 1006,
"loc": {
"start": {
"line": 34,
"column": 8
},
"end": {
"line": 36,
"column": 11
}
}
},
{
"type": "CommentBlock",
"value": "*\r\n * We compute an opacity to make sure it doesn't flicker\r\n ",
"start": 1049,
"end": 1131,
"loc": {
"start": {
"line": 39,
"column": 8
},
"end": {
"line": 41,
"column": 11
}
}
},
{
"type": "CommentBlock",
"value": "*\r\n * Returns whether this storage can accept the item\r\n * @param {BaseItem} item\r\n ",
"start": 1180,
"end": 1280,
"loc": {
"start": {
"line": 45,
"column": 4
},
"end": {
"line": 48,
"column": 7
}
}
},
{
"type": "CommentLine",
"value": " Check type matches",
"start": 1557,
"end": 1578,
"loc": {
"start": {
"line": 59,
"column": 8
},
"end": {
"line": 59,
"column": 29
}
}
},
{
"type": "CommentBlock",
"value": "* @type {ColorItem} ",
"start": 1735,
"end": 1759,
"loc": {
"start": {
"line": 65,
"column": 19
},
"end": {
"line": 65,
"column": 43
}
}
},
{
"type": "CommentBlock",
"value": "* @type {ColorItem} ",
"start": 1788,
"end": 1812,
"loc": {
"start": {
"line": 65,
"column": 72
},
"end": {
"line": 65,
"column": 96
}
}
},
{
"type": "CommentBlock",
"value": "* @type {ShapeItem} ",
"start": 1916,
"end": 1940,
"loc": {
"start": {
"line": 70,
"column": 16
},
"end": {
"line": 70,
"column": 40
}
}
},
{
"type": "CommentBlock",
"value": "* @type {ShapeItem} ",
"start": 2001,
"end": 2025,
"loc": {
"start": {
"line": 71,
"column": 16
},
"end": {
"line": 71,
"column": 40
}
}
},
{
"type": "CommentBlock",
"value": "*\r\n * Returns whether the storage is full\r\n * @returns {boolean}\r\n ",
"start": 2118,
"end": 2201,
"loc": {
"start": {
"line": 77,
"column": 4
},
"end": {
"line": 80,
"column": 7
}
}
},
{
"type": "CommentBlock",
"value": "*\r\n * @param {BaseItem} item\r\n ",
"start": 2292,
"end": 2335,
"loc": {
"start": {
"line": 85,
"column": 4
},
"end": {
"line": 87,
"column": 7
}
}
}
],
"tokens": [
{
"type": {
"label": "import",
"keyword": "import",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "import",
"start": 0,
"end": 6,
"loc": {
"start": {
"line": 1,
"column": 0
},
"end": {
"line": 1,
"column": 6
}
}
},
{
"type": {
"label": "{",
"beforeExpr": true,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 7,
"end": 8,
"loc": {
"start": {
"line": 1,
"column": 7
},
"end": {
"line": 1,
"column": 8
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "types",
"start": 9,
"end": 14,
"loc": {
"start": {
"line": 1,
"column": 9
},
"end": {
"line": 1,
"column": 14
}
}
},
{
"type": {
"label": "}",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 15,
"end": 16,
"loc": {
"start": {
"line": 1,
"column": 15
},
"end": {
"line": 1,
"column": 16
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "from",
"start": 17,
"end": 21,
"loc": {
"start": {
"line": 1,
"column": 17
},
"end": {
"line": 1,
"column": 21
}
}
},
{
"type": {
"label": "string",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "../../savegame/serialization",
"start": 22,
"end": 52,
"loc": {
"start": {
"line": 1,
"column": 22
},
"end": {
"line": 1,
"column": 52
}
}
},
{
"type": {
"label": ";",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 52,
"end": 53,
"loc": {
"start": {
"line": 1,
"column": 52
},
"end": {
"line": 1,
"column": 53
}
}
},
{
"type": {
"label": "import",
"keyword": "import",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "import",
"start": 55,
"end": 61,
"loc": {
"start": {
"line": 2,
"column": 0
},
"end": {
"line": 2,
"column": 6
}
}
},
{
"type": {
"label": "{",
"beforeExpr": true,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 62,
"end": 63,
"loc": {
"start": {
"line": 2,
"column": 7
},
"end": {
"line": 2,
"column": 8
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "BaseItem",
"start": 64,
"end": 72,
"loc": {
"start": {
"line": 2,
"column": 9
},
"end": {
"line": 2,
"column": 17
}
}
},
{
"type": {
"label": "}",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 73,
"end": 74,
"loc": {
"start": {
"line": 2,
"column": 18
},
"end": {
"line": 2,
"column": 19
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "from",
"start": 75,
"end": 79,
"loc": {
"start": {
"line": 2,
"column": 20
},
"end": {
"line": 2,
"column": 24
}
}
},
{
"type": {
"label": "string",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "../base_item",
"start": 80,
"end": 94,
"loc": {
"start": {
"line": 2,
"column": 25
},
"end": {
"line": 2,
"column": 39
}
}
},
{
"type": {
"label": ";",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 94,
"end": 95,
"loc": {
"start": {
"line": 2,
"column": 39
},
"end": {
"line": 2,
"column": 40
}
}
},
{
"type": {
"label": "import",
"keyword": "import",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "import",
"start": 97,
"end": 103,
"loc": {
"start": {
"line": 3,
"column": 0
},
"end": {
"line": 3,
"column": 6
}
}
},
{
"type": {
"label": "{",
"beforeExpr": true,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 104,
"end": 105,
"loc": {
"start": {
"line": 3,
"column": 7
},
"end": {
"line": 3,
"column": 8
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "Component",
"start": 106,
"end": 115,
"loc": {
"start": {
"line": 3,
"column": 9
},
"end": {
"line": 3,
"column": 18
}
}
},
{
"type": {
"label": "}",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 116,
"end": 117,
"loc": {
"start": {
"line": 3,
"column": 19
},
"end": {
"line": 3,
"column": 20
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "from",
"start": 118,
"end": 122,
"loc": {
"start": {
"line": 3,
"column": 21
},
"end": {
"line": 3,
"column": 25
}
}
},
{
"type": {
"label": "string",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "../component",
"start": 123,
"end": 137,
"loc": {
"start": {
"line": 3,
"column": 26
},
"end": {
"line": 3,
"column": 40
}
}
},
{
"type": {
"label": ";",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 137,
"end": 138,
"loc": {
"start": {
"line": 3,
"column": 40
},
"end": {
"line": 3,
"column": 41
}
}
},
{
"type": {
"label": "import",
"keyword": "import",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "import",
"start": 140,
"end": 146,
"loc": {
"start": {
"line": 4,
"column": 0
},
"end": {
"line": 4,
"column": 6
}
}
},
{
"type": {
"label": "{",
"beforeExpr": true,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 147,
"end": 148,
"loc": {
"start": {
"line": 4,
"column": 7
},
"end": {
"line": 4,
"column": 8
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "typeItemSingleton",
"start": 149,
"end": 166,
"loc": {
"start": {
"line": 4,
"column": 9
},
"end": {
"line": 4,
"column": 26
}
}
},
{
"type": {
"label": "}",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 167,
"end": 168,
"loc": {
"start": {
"line": 4,
"column": 27
},
"end": {
"line": 4,
"column": 28
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "from",
"start": 169,
"end": 173,
"loc": {
"start": {
"line": 4,
"column": 29
},
"end": {
"line": 4,
"column": 33
}
}
},
{
"type": {
"label": "string",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "../item_resolver",
"start": 174,
"end": 192,
"loc": {
"start": {
"line": 4,
"column": 34
},
"end": {
"line": 4,
"column": 52
}
}
},
{
"type": {
"label": ";",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 192,
"end": 193,
"loc": {
"start": {
"line": 4,
"column": 52
},
"end": {
"line": 4,
"column": 53
}
}
},
{
"type": {
"label": "import",
"keyword": "import",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "import",
"start": 195,
"end": 201,
"loc": {
"start": {
"line": 5,
"column": 0
},
"end": {
"line": 5,
"column": 6
}
}
},
{
"type": {
"label": "{",
"beforeExpr": true,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 202,
"end": 203,
"loc": {
"start": {
"line": 5,
"column": 7
},
"end": {
"line": 5,
"column": 8
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "ColorItem",
"start": 204,
"end": 213,
"loc": {
"start": {
"line": 5,
"column": 9
},
"end": {
"line": 5,
"column": 18
}
}
},
{
"type": {
"label": "}",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 214,
"end": 215,
"loc": {
"start": {
"line": 5,
"column": 19
},
"end": {
"line": 5,
"column": 20
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "from",
"start": 216,
"end": 220,
"loc": {
"start": {
"line": 5,
"column": 21
},
"end": {
"line": 5,
"column": 25
}
}
},
{
"type": {
"label": "string",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "../items/color_item",
"start": 221,
"end": 242,
"loc": {
"start": {
"line": 5,
"column": 26
},
"end": {
"line": 5,
"column": 47
}
}
},
{
"type": {
"label": ";",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 242,
"end": 243,
"loc": {
"start": {
"line": 5,
"column": 47
},
"end": {
"line": 5,
"column": 48
}
}
},
{
"type": {
"label": "import",
"keyword": "import",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "import",
"start": 245,
"end": 251,
"loc": {
"start": {
"line": 6,
"column": 0
},
"end": {
"line": 6,
"column": 6
}
}
},
{
"type": {
"label": "{",
"beforeExpr": true,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 252,
"end": 253,
"loc": {
"start": {
"line": 6,
"column": 7
},
"end": {
"line": 6,
"column": 8
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "ShapeItem",
"start": 254,
"end": 263,
"loc": {
"start": {
"line": 6,
"column": 9
},
"end": {
"line": 6,
"column": 18
}
}
},
{
"type": {
"label": "}",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 264,
"end": 265,
"loc": {
"start": {
"line": 6,
"column": 19
},
"end": {
"line": 6,
"column": 20
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "from",
"start": 266,
"end": 270,
"loc": {
"start": {
"line": 6,
"column": 21
},
"end": {
"line": 6,
"column": 25
}
}
},
{
"type": {
"label": "string",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "../items/shape_item",
"start": 271,
"end": 292,
"loc": {
"start": {
"line": 6,
"column": 26
},
"end": {
"line": 6,
"column": 47
}
}
},
{
"type": {
"label": ";",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 292,
"end": 293,
"loc": {
"start": {
"line": 6,
"column": 47
},
"end": {
"line": 6,
"column": 48
}
}
},
{
"type": {
"label": "export",
"keyword": "export",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "export",
"start": 297,
"end": 303,
"loc": {
"start": {
"line": 8,
"column": 0
},
"end": {
"line": 8,
"column": 6
}
}
},
{
"type": {
"label": "class",
"keyword": "class",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "class",
"start": 304,
"end": 309,
"loc": {
"start": {
"line": 8,
"column": 7
},
"end": {
"line": 8,
"column": 12
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "StorageComponent",
"start": 310,
"end": 326,
"loc": {
"start": {
"line": 8,
"column": 13
},
"end": {
"line": 8,
"column": 29
}
}
},
{
"type": {
"label": "extends",
"keyword": "extends",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "extends",
"start": 327,
"end": 334,
"loc": {
"start": {
"line": 8,
"column": 30
},
"end": {
"line": 8,
"column": 37
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "Component",
"start": 335,
"end": 344,
"loc": {
"start": {
"line": 8,
"column": 38
},
"end": {
"line": 8,
"column": 47
}
}
},
{
"type": {
"label": "{",
"beforeExpr": true,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 345,
"end": 346,
"loc": {
"start": {
"line": 8,
"column": 48
},
"end": {
"line": 8,
"column": 49
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "static",
"start": 352,
"end": 358,
"loc": {
"start": {
"line": 9,
"column": 4
},
"end": {
"line": 9,
"column": 10
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "getId",
"start": 359,
"end": 364,
"loc": {
"start": {
"line": 9,
"column": 11
},
"end": {
"line": 9,
"column": 16
}
}
},
{
"type": {
"label": "(",
"beforeExpr": true,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 364,
"end": 365,
"loc": {
"start": {
"line": 9,
"column": 16
},
"end": {
"line": 9,
"column": 17
}
}
},
{
"type": {
"label": ")",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 365,
"end": 366,
"loc": {
"start": {
"line": 9,
"column": 17
},
"end": {
"line": 9,
"column": 18
}
}
},
{
"type": {
"label": "{",
"beforeExpr": true,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 367,
"end": 368,
"loc": {
"start": {
"line": 9,
"column": 19
},
"end": {
"line": 9,
"column": 20
}
}
},
{
"type": {
"label": "return",
"keyword": "return",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "return",
"start": 378,
"end": 384,
"loc": {
"start": {
"line": 10,
"column": 8
},
"end": {
"line": 10,
"column": 14
}
}
},
{
"type": {
"label": "string",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "Storage",
"start": 385,
"end": 394,
"loc": {
"start": {
"line": 10,
"column": 15
},
"end": {
"line": 10,
"column": 24
}
}
},
{
"type": {
"label": ";",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 394,
"end": 395,
"loc": {
"start": {
"line": 10,
"column": 24
},
"end": {
"line": 10,
"column": 25
}
}
},
{
"type": {
"label": "}",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 401,
"end": 402,
"loc": {
"start": {
"line": 11,
"column": 4
},
"end": {
"line": 11,
"column": 5
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "static",
"start": 410,
"end": 416,
"loc": {
"start": {
"line": 13,
"column": 4
},
"end": {
"line": 13,
"column": 10
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "getSchema",
"start": 417,
"end": 426,
"loc": {
"start": {
"line": 13,
"column": 11
},
"end": {
"line": 13,
"column": 20
}
}
},
{
"type": {
"label": "(",
"beforeExpr": true,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 426,
"end": 427,
"loc": {
"start": {
"line": 13,
"column": 20
},
"end": {
"line": 13,
"column": 21
}
}
},
{
"type": {
"label": ")",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 427,
"end": 428,
"loc": {
"start": {
"line": 13,
"column": 21
},
"end": {
"line": 13,
"column": 22
}
}
},
{
"type": {
"label": "{",
"beforeExpr": true,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 429,
"end": 430,
"loc": {
"start": {
"line": 13,
"column": 23
},
"end": {
"line": 13,
"column": 24
}
}
},
{
"type": {
"label": "return",
"keyword": "return",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "return",
"start": 440,
"end": 446,
"loc": {
"start": {
"line": 14,
"column": 8
},
"end": {
"line": 14,
"column": 14
}
}
},
{
"type": {
"label": "{",
"beforeExpr": true,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 447,
"end": 448,
"loc": {
"start": {
"line": 14,
"column": 15
},
"end": {
"line": 14,
"column": 16
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "storedCount",
"start": 462,
"end": 473,
"loc": {
"start": {
"line": 15,
"column": 12
},
"end": {
"line": 15,
"column": 23
}
}
},
{
"type": {
"label": ":",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 473,
"end": 474,
"loc": {
"start": {
"line": 15,
"column": 23
},
"end": {
"line": 15,
"column": 24
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "types",
"start": 475,
"end": 480,
"loc": {
"start": {
"line": 15,
"column": 25
},
"end": {
"line": 15,
"column": 30
}
}
},
{
"type": {
"label": ".",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 480,
"end": 481,
"loc": {
"start": {
"line": 15,
"column": 30
},
"end": {
"line": 15,
"column": 31
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "uint",
"start": 481,
"end": 485,
"loc": {
"start": {
"line": 15,
"column": 31
},
"end": {
"line": 15,
"column": 35
}
}
},
{
"type": {
"label": ",",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 485,
"end": 486,
"loc": {
"start": {
"line": 15,
"column": 35
},
"end": {
"line": 15,
"column": 36
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "storedItem",
"start": 500,
"end": 510,
"loc": {
"start": {
"line": 16,
"column": 12
},
"end": {
"line": 16,
"column": 22
}
}
},
{
"type": {
"label": ":",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 510,
"end": 511,
"loc": {
"start": {
"line": 16,
"column": 22
},
"end": {
"line": 16,
"column": 23
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "types",
"start": 512,
"end": 517,
"loc": {
"start": {
"line": 16,
"column": 24
},
"end": {
"line": 16,
"column": 29
}
}
},
{
"type": {
"label": ".",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 517,
"end": 518,
"loc": {
"start": {
"line": 16,
"column": 29
},
"end": {
"line": 16,
"column": 30
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "nullable",
"start": 518,
"end": 526,
"loc": {
"start": {
"line": 16,
"column": 30
},
"end": {
"line": 16,
"column": 38
}
}
},
{
"type": {
"label": "(",
"beforeExpr": true,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 526,
"end": 527,
"loc": {
"start": {
"line": 16,
"column": 38
},
"end": {
"line": 16,
"column": 39
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "typeItemSingleton",
"start": 527,
"end": 544,
"loc": {
"start": {
"line": 16,
"column": 39
},
"end": {
"line": 16,
"column": 56
}
}
},
{
"type": {
"label": ")",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 544,
"end": 545,
"loc": {
"start": {
"line": 16,
"column": 56
},
"end": {
"line": 16,
"column": 57
}
}
},
{
"type": {
"label": ",",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 545,
"end": 546,
"loc": {
"start": {
"line": 16,
"column": 57
},
"end": {
"line": 16,
"column": 58
}
}
},
{
"type": {
"label": "}",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 556,
"end": 557,
"loc": {
"start": {
"line": 17,
"column": 8
},
"end": {
"line": 17,
"column": 9
}
}
},
{
"type": {
"label": ";",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 557,
"end": 558,
"loc": {
"start": {
"line": 17,
"column": 9
},
"end": {
"line": 17,
"column": 10
}
}
},
{
"type": {
"label": "}",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 564,
"end": 565,
"loc": {
"start": {
"line": 18,
"column": 4
},
"end": {
"line": 18,
"column": 5
}
}
},
{
"type": "CommentBlock",
"value": "*\r\n * @param {object} param0\r\n * @param {number=} param0.maximumStorage How much this storage can hold\r\n ",
"start": 573,
"end": 694,
"loc": {
"start": {
"line": 20,
"column": 4
},
"end": {
"line": 23,
"column": 7
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "constructor",
"start": 700,
"end": 711,
"loc": {
"start": {
"line": 24,
"column": 4
},
"end": {
"line": 24,
"column": 15
}
}
},
{
"type": {
"label": "(",
"beforeExpr": true,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 711,
"end": 712,
"loc": {
"start": {
"line": 24,
"column": 15
},
"end": {
"line": 24,
"column": 16
}
}
},
{
"type": {
"label": "{",
"beforeExpr": true,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 712,
"end": 713,
"loc": {
"start": {
"line": 24,
"column": 16
},
"end": {
"line": 24,
"column": 17
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "maximumStorage",
"start": 714,
"end": 728,
"loc": {
"start": {
"line": 24,
"column": 18
},
"end": {
"line": 24,
"column": 32
}
}
},
{
"type": {
"label": "=",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": true,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "=",
"start": 729,
"end": 730,
"loc": {
"start": {
"line": 24,
"column": 33
},
"end": {
"line": 24,
"column": 34
}
}
},
{
"type": {
"label": "num",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": 100000000000000000000,
"start": 731,
"end": 735,
"loc": {
"start": {
"line": 24,
"column": 35
},
"end": {
"line": 24,
"column": 39
}
}
},
{
"type": {
"label": "}",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 736,
"end": 737,
"loc": {
"start": {
"line": 24,
"column": 40
},
"end": {
"line": 24,
"column": 41
}
}
},
{
"type": {
"label": ")",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 737,
"end": 738,
"loc": {
"start": {
"line": 24,
"column": 41
},
"end": {
"line": 24,
"column": 42
}
}
},
{
"type": {
"label": "{",
"beforeExpr": true,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 739,
"end": 740,
"loc": {
"start": {
"line": 24,
"column": 43
},
"end": {
"line": 24,
"column": 44
}
}
},
{
"type": {
"label": "super",
"keyword": "super",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "super",
"start": 750,
"end": 755,
"loc": {
"start": {
"line": 25,
"column": 8
},
"end": {
"line": 25,
"column": 13
}
}
},
{
"type": {
"label": "(",
"beforeExpr": true,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 755,
"end": 756,
"loc": {
"start": {
"line": 25,
"column": 13
},
"end": {
"line": 25,
"column": 14
}
}
},
{
"type": {
"label": ")",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 756,
"end": 757,
"loc": {
"start": {
"line": 25,
"column": 14
},
"end": {
"line": 25,
"column": 15
}
}
},
{
"type": {
"label": ";",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 757,
"end": 758,
"loc": {
"start": {
"line": 25,
"column": 15
},
"end": {
"line": 25,
"column": 16
}
}
},
{
"type": {
"label": "this",
"keyword": "this",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "this",
"start": 768,
"end": 772,
"loc": {
"start": {
"line": 26,
"column": 8
},
"end": {
"line": 26,
"column": 12
}
}
},
{
"type": {
"label": ".",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 772,
"end": 773,
"loc": {
"start": {
"line": 26,
"column": 12
},
"end": {
"line": 26,
"column": 13
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "maximumStorage",
"start": 773,
"end": 787,
"loc": {
"start": {
"line": 26,
"column": 13
},
"end": {
"line": 26,
"column": 27
}
}
},
{
"type": {
"label": "=",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": true,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "=",
"start": 788,
"end": 789,
"loc": {
"start": {
"line": 26,
"column": 28
},
"end": {
"line": 26,
"column": 29
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "maximumStorage",
"start": 790,
"end": 804,
"loc": {
"start": {
"line": 26,
"column": 30
},
"end": {
"line": 26,
"column": 44
}
}
},
{
"type": {
"label": ";",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 804,
"end": 805,
"loc": {
"start": {
"line": 26,
"column": 44
},
"end": {
"line": 26,
"column": 45
}
}
},
{
"type": "CommentBlock",
"value": "*\r\n * Currently stored item\r\n * @type {BaseItem}\r\n ",
"start": 817,
"end": 896,
"loc": {
"start": {
"line": 28,
"column": 8
},
"end": {
"line": 31,
"column": 11
}
}
},
{
"type": {
"label": "this",
"keyword": "this",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "this",
"start": 906,
"end": 910,
"loc": {
"start": {
"line": 32,
"column": 8
},
"end": {
"line": 32,
"column": 12
}
}
},
{
"type": {
"label": ".",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 910,
"end": 911,
"loc": {
"start": {
"line": 32,
"column": 12
},
"end": {
"line": 32,
"column": 13
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "storedItem",
"start": 911,
"end": 921,
"loc": {
"start": {
"line": 32,
"column": 13
},
"end": {
"line": 32,
"column": 23
}
}
},
{
"type": {
"label": "=",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": true,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "=",
"start": 922,
"end": 923,
"loc": {
"start": {
"line": 32,
"column": 24
},
"end": {
"line": 32,
"column": 25
}
}
},
{
"type": {
"label": "null",
"keyword": "null",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "null",
"start": 924,
"end": 928,
"loc": {
"start": {
"line": 32,
"column": 26
},
"end": {
"line": 32,
"column": 30
}
}
},
{
"type": {
"label": ";",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 928,
"end": 929,
"loc": {
"start": {
"line": 32,
"column": 30
},
"end": {
"line": 32,
"column": 31
}
}
},
{
"type": "CommentBlock",
"value": "*\r\n * How many of this item we have stored\r\n ",
"start": 941,
"end": 1006,
"loc": {
"start": {
"line": 34,
"column": 8
},
"end": {
"line": 36,
"column": 11
}
}
},
{
"type": {
"label": "this",
"keyword": "this",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "this",
"start": 1016,
"end": 1020,
"loc": {
"start": {
"line": 37,
"column": 8
},
"end": {
"line": 37,
"column": 12
}
}
},
{
"type": {
"label": ".",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 1020,
"end": 1021,
"loc": {
"start": {
"line": 37,
"column": 12
},
"end": {
"line": 37,
"column": 13
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "storedCount",
"start": 1021,
"end": 1032,
"loc": {
"start": {
"line": 37,
"column": 13
},
"end": {
"line": 37,
"column": 24
}
}
},
{
"type": {
"label": "=",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": true,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "=",
"start": 1033,
"end": 1034,
"loc": {
"start": {
"line": 37,
"column": 25
},
"end": {
"line": 37,
"column": 26
}
}
},
{
"type": {
"label": "num",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": 0,
"start": 1035,
"end": 1036,
"loc": {
"start": {
"line": 37,
"column": 27
},
"end": {
"line": 37,
"column": 28
}
}
},
{
"type": {
"label": ";",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 1036,
"end": 1037,
"loc": {
"start": {
"line": 37,
"column": 28
},
"end": {
"line": 37,
"column": 29
}
}
},
{
"type": "CommentBlock",
"value": "*\r\n * We compute an opacity to make sure it doesn't flicker\r\n ",
"start": 1049,
"end": 1131,
"loc": {
"start": {
"line": 39,
"column": 8
},
"end": {
"line": 41,
"column": 11
}
}
},
{
"type": {
"label": "this",
"keyword": "this",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "this",
"start": 1141,
"end": 1145,
"loc": {
"start": {
"line": 42,
"column": 8
},
"end": {
"line": 42,
"column": 12
}
}
},
{
"type": {
"label": ".",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 1145,
"end": 1146,
"loc": {
"start": {
"line": 42,
"column": 12
},
"end": {
"line": 42,
"column": 13
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "overlayOpacity",
"start": 1146,
"end": 1160,
"loc": {
"start": {
"line": 42,
"column": 13
},
"end": {
"line": 42,
"column": 27
}
}
},
{
"type": {
"label": "=",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": true,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "=",
"start": 1161,
"end": 1162,
"loc": {
"start": {
"line": 42,
"column": 28
},
"end": {
"line": 42,
"column": 29
}
}
},
{
"type": {
"label": "num",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": 0,
"start": 1163,
"end": 1164,
"loc": {
"start": {
"line": 42,
"column": 30
},
"end": {
"line": 42,
"column": 31
}
}
},
{
"type": {
"label": ";",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 1164,
"end": 1165,
"loc": {
"start": {
"line": 42,
"column": 31
},
"end": {
"line": 42,
"column": 32
}
}
},
{
"type": {
"label": "}",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 1171,
"end": 1172,
"loc": {
"start": {
"line": 43,
"column": 4
},
"end": {
"line": 43,
"column": 5
}
}
},
{
"type": "CommentBlock",
"value": "*\r\n * Returns whether this storage can accept the item\r\n * @param {BaseItem} item\r\n ",
"start": 1180,
"end": 1280,
"loc": {
"start": {
"line": 45,
"column": 4
},
"end": {
"line": 48,
"column": 7
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "canAcceptItem",
"start": 1286,
"end": 1299,
"loc": {
"start": {
"line": 49,
"column": 4
},
"end": {
"line": 49,
"column": 17
}
}
},
{
"type": {
"label": "(",
"beforeExpr": true,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 1299,
"end": 1300,
"loc": {
"start": {
"line": 49,
"column": 17
},
"end": {
"line": 49,
"column": 18
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "item",
"start": 1300,
"end": 1304,
"loc": {
"start": {
"line": 49,
"column": 18
},
"end": {
"line": 49,
"column": 22
}
}
},
{
"type": {
"label": ")",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 1304,
"end": 1305,
"loc": {
"start": {
"line": 49,
"column": 22
},
"end": {
"line": 49,
"column": 23
}
}
},
{
"type": {
"label": "{",
"beforeExpr": true,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 1306,
"end": 1307,
"loc": {
"start": {
"line": 49,
"column": 24
},
"end": {
"line": 49,
"column": 25
}
}
},
{
"type": {
"label": "if",
"keyword": "if",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "if",
"start": 1317,
"end": 1319,
"loc": {
"start": {
"line": 50,
"column": 8
},
"end": {
"line": 50,
"column": 10
}
}
},
{
"type": {
"label": "(",
"beforeExpr": true,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 1320,
"end": 1321,
"loc": {
"start": {
"line": 50,
"column": 11
},
"end": {
"line": 50,
"column": 12
}
}
},
{
"type": {
"label": "this",
"keyword": "this",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "this",
"start": 1321,
"end": 1325,
"loc": {
"start": {
"line": 50,
"column": 12
},
"end": {
"line": 50,
"column": 16
}
}
},
{
"type": {
"label": ".",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 1325,
"end": 1326,
"loc": {
"start": {
"line": 50,
"column": 16
},
"end": {
"line": 50,
"column": 17
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "storedCount",
"start": 1326,
"end": 1337,
"loc": {
"start": {
"line": 50,
"column": 17
},
"end": {
"line": 50,
"column": 28
}
}
},
{
"type": {
"label": "</>",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": 7,
"updateContext": null
},
"value": ">=",
"start": 1338,
"end": 1340,
"loc": {
"start": {
"line": 50,
"column": 29
},
"end": {
"line": 50,
"column": 31
}
}
},
{
"type": {
"label": "this",
"keyword": "this",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "this",
"start": 1341,
"end": 1345,
"loc": {
"start": {
"line": 50,
"column": 32
},
"end": {
"line": 50,
"column": 36
}
}
},
{
"type": {
"label": ".",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 1345,
"end": 1346,
"loc": {
"start": {
"line": 50,
"column": 36
},
"end": {
"line": 50,
"column": 37
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "maximumStorage",
"start": 1346,
"end": 1360,
"loc": {
"start": {
"line": 50,
"column": 37
},
"end": {
"line": 50,
"column": 51
}
}
},
{
"type": {
"label": ")",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 1360,
"end": 1361,
"loc": {
"start": {
"line": 50,
"column": 51
},
"end": {
"line": 50,
"column": 52
}
}
},
{
"type": {
"label": "{",
"beforeExpr": true,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 1362,
"end": 1363,
"loc": {
"start": {
"line": 50,
"column": 53
},
"end": {
"line": 50,
"column": 54
}
}
},
{
"type": {
"label": "return",
"keyword": "return",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "return",
"start": 1377,
"end": 1383,
"loc": {
"start": {
"line": 51,
"column": 12
},
"end": {
"line": 51,
"column": 18
}
}
},
{
"type": {
"label": "false",
"keyword": "false",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "false",
"start": 1384,
"end": 1389,
"loc": {
"start": {
"line": 51,
"column": 19
},
"end": {
"line": 51,
"column": 24
}
}
},
{
"type": {
"label": ";",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 1389,
"end": 1390,
"loc": {
"start": {
"line": 51,
"column": 24
},
"end": {
"line": 51,
"column": 25
}
}
},
{
"type": {
"label": "}",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 1400,
"end": 1401,
"loc": {
"start": {
"line": 52,
"column": 8
},
"end": {
"line": 52,
"column": 9
}
}
},
{
"type": {
"label": "if",
"keyword": "if",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "if",
"start": 1411,
"end": 1413,
"loc": {
"start": {
"line": 53,
"column": 8
},
"end": {
"line": 53,
"column": 10
}
}
},
{
"type": {
"label": "(",
"beforeExpr": true,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 1414,
"end": 1415,
"loc": {
"start": {
"line": 53,
"column": 11
},
"end": {
"line": 53,
"column": 12
}
}
},
{
"type": {
"label": "prefix",
"beforeExpr": true,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": true,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "!",
"start": 1415,
"end": 1416,
"loc": {
"start": {
"line": 53,
"column": 12
},
"end": {
"line": 53,
"column": 13
}
}
},
{
"type": {
"label": "this",
"keyword": "this",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "this",
"start": 1416,
"end": 1420,
"loc": {
"start": {
"line": 53,
"column": 13
},
"end": {
"line": 53,
"column": 17
}
}
},
{
"type": {
"label": ".",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 1420,
"end": 1421,
"loc": {
"start": {
"line": 53,
"column": 17
},
"end": {
"line": 53,
"column": 18
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "storedItem",
"start": 1421,
"end": 1431,
"loc": {
"start": {
"line": 53,
"column": 18
},
"end": {
"line": 53,
"column": 28
}
}
},
{
"type": {
"label": "||",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": 1,
"updateContext": null
},
"value": "||",
"start": 1432,
"end": 1434,
"loc": {
"start": {
"line": 53,
"column": 29
},
"end": {
"line": 53,
"column": 31
}
}
},
{
"type": {
"label": "this",
"keyword": "this",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "this",
"start": 1435,
"end": 1439,
"loc": {
"start": {
"line": 53,
"column": 32
},
"end": {
"line": 53,
"column": 36
}
}
},
{
"type": {
"label": ".",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 1439,
"end": 1440,
"loc": {
"start": {
"line": 53,
"column": 36
},
"end": {
"line": 53,
"column": 37
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "storedCount",
"start": 1440,
"end": 1451,
"loc": {
"start": {
"line": 53,
"column": 37
},
"end": {
"line": 53,
"column": 48
}
}
},
{
"type": {
"label": "==/!=",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": 6,
"updateContext": null
},
"value": "===",
"start": 1452,
"end": 1455,
"loc": {
"start": {
"line": 53,
"column": 49
},
"end": {
"line": 53,
"column": 52
}
}
},
{
"type": {
"label": "num",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": 0,
"start": 1456,
"end": 1457,
"loc": {
"start": {
"line": 53,
"column": 53
},
"end": {
"line": 53,
"column": 54
}
}
},
{
"type": {
"label": ")",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 1457,
"end": 1458,
"loc": {
"start": {
"line": 53,
"column": 54
},
"end": {
"line": 53,
"column": 55
}
}
},
{
"type": {
"label": "{",
"beforeExpr": true,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 1459,
"end": 1460,
"loc": {
"start": {
"line": 53,
"column": 56
},
"end": {
"line": 53,
"column": 57
}
}
},
{
"type": {
"label": "return",
"keyword": "return",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "return",
"start": 1474,
"end": 1480,
"loc": {
"start": {
"line": 54,
"column": 12
},
"end": {
"line": 54,
"column": 18
}
}
},
{
"type": {
"label": "true",
"keyword": "true",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "true",
"start": 1481,
"end": 1485,
"loc": {
"start": {
"line": 54,
"column": 19
},
"end": {
"line": 54,
"column": 23
}
}
},
{
"type": {
"label": ";",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 1485,
"end": 1486,
"loc": {
"start": {
"line": 54,
"column": 23
},
"end": {
"line": 54,
"column": 24
}
}
},
{
"type": {
"label": "}",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 1496,
"end": 1497,
"loc": {
"start": {
"line": 55,
"column": 8
},
"end": {
"line": 55,
"column": 9
}
}
},
{
"type": {
"label": "const",
"keyword": "const",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "const",
"start": 1509,
"end": 1514,
"loc": {
"start": {
"line": 57,
"column": 8
},
"end": {
"line": 57,
"column": 13
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "itemType",
"start": 1515,
"end": 1523,
"loc": {
"start": {
"line": 57,
"column": 14
},
"end": {
"line": 57,
"column": 22
}
}
},
{
"type": {
"label": "=",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": true,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "=",
"start": 1524,
"end": 1525,
"loc": {
"start": {
"line": 57,
"column": 23
},
"end": {
"line": 57,
"column": 24
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "item",
"start": 1526,
"end": 1530,
"loc": {
"start": {
"line": 57,
"column": 25
},
"end": {
"line": 57,
"column": 29
}
}
},
{
"type": {
"label": ".",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 1530,
"end": 1531,
"loc": {
"start": {
"line": 57,
"column": 29
},
"end": {
"line": 57,
"column": 30
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "getItemType",
"start": 1531,
"end": 1542,
"loc": {
"start": {
"line": 57,
"column": 30
},
"end": {
"line": 57,
"column": 41
}
}
},
{
"type": {
"label": "(",
"beforeExpr": true,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 1542,
"end": 1543,
"loc": {
"start": {
"line": 57,
"column": 41
},
"end": {
"line": 57,
"column": 42
}
}
},
{
"type": {
"label": ")",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 1543,
"end": 1544,
"loc": {
"start": {
"line": 57,
"column": 42
},
"end": {
"line": 57,
"column": 43
}
}
},
{
"type": {
"label": ";",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 1544,
"end": 1545,
"loc": {
"start": {
"line": 57,
"column": 43
},
"end": {
"line": 57,
"column": 44
}
}
},
{
"type": "CommentLine",
"value": " Check type matches",
"start": 1557,
"end": 1578,
"loc": {
"start": {
"line": 59,
"column": 8
},
"end": {
"line": 59,
"column": 29
}
}
},
{
"type": {
"label": "if",
"keyword": "if",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "if",
"start": 1588,
"end": 1590,
"loc": {
"start": {
"line": 60,
"column": 8
},
"end": {
"line": 60,
"column": 10
}
}
},
{
"type": {
"label": "(",
"beforeExpr": true,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 1591,
"end": 1592,
"loc": {
"start": {
"line": 60,
"column": 11
},
"end": {
"line": 60,
"column": 12
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "itemType",
"start": 1592,
"end": 1600,
"loc": {
"start": {
"line": 60,
"column": 12
},
"end": {
"line": 60,
"column": 20
}
}
},
{
"type": {
"label": "==/!=",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": 6,
"updateContext": null
},
"value": "!==",
"start": 1601,
"end": 1604,
"loc": {
"start": {
"line": 60,
"column": 21
},
"end": {
"line": 60,
"column": 24
}
}
},
{
"type": {
"label": "this",
"keyword": "this",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "this",
"start": 1605,
"end": 1609,
"loc": {
"start": {
"line": 60,
"column": 25
},
"end": {
"line": 60,
"column": 29
}
}
},
{
"type": {
"label": ".",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 1609,
"end": 1610,
"loc": {
"start": {
"line": 60,
"column": 29
},
"end": {
"line": 60,
"column": 30
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "storedItem",
"start": 1610,
"end": 1620,
"loc": {
"start": {
"line": 60,
"column": 30
},
"end": {
"line": 60,
"column": 40
}
}
},
{
"type": {
"label": ".",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 1620,
"end": 1621,
"loc": {
"start": {
"line": 60,
"column": 40
},
"end": {
"line": 60,
"column": 41
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "getItemType",
"start": 1621,
"end": 1632,
"loc": {
"start": {
"line": 60,
"column": 41
},
"end": {
"line": 60,
"column": 52
}
}
},
{
"type": {
"label": "(",
"beforeExpr": true,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 1632,
"end": 1633,
"loc": {
"start": {
"line": 60,
"column": 52
},
"end": {
"line": 60,
"column": 53
}
}
},
{
"type": {
"label": ")",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 1633,
"end": 1634,
"loc": {
"start": {
"line": 60,
"column": 53
},
"end": {
"line": 60,
"column": 54
}
}
},
{
"type": {
"label": ")",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 1634,
"end": 1635,
"loc": {
"start": {
"line": 60,
"column": 54
},
"end": {
"line": 60,
"column": 55
}
}
},
{
"type": {
"label": "{",
"beforeExpr": true,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 1636,
"end": 1637,
"loc": {
"start": {
"line": 60,
"column": 56
},
"end": {
"line": 60,
"column": 57
}
}
},
{
"type": {
"label": "return",
"keyword": "return",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "return",
"start": 1651,
"end": 1657,
"loc": {
"start": {
"line": 61,
"column": 12
},
"end": {
"line": 61,
"column": 18
}
}
},
{
"type": {
"label": "false",
"keyword": "false",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "false",
"start": 1658,
"end": 1663,
"loc": {
"start": {
"line": 61,
"column": 19
},
"end": {
"line": 61,
"column": 24
}
}
},
{
"type": {
"label": ";",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 1663,
"end": 1664,
"loc": {
"start": {
"line": 61,
"column": 24
},
"end": {
"line": 61,
"column": 25
}
}
},
{
"type": {
"label": "}",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 1674,
"end": 1675,
"loc": {
"start": {
"line": 62,
"column": 8
},
"end": {
"line": 62,
"column": 9
}
}
},
{
"type": {
"label": "if",
"keyword": "if",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "if",
"start": 1687,
"end": 1689,
"loc": {
"start": {
"line": 64,
"column": 8
},
"end": {
"line": 64,
"column": 10
}
}
},
{
"type": {
"label": "(",
"beforeExpr": true,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 1690,
"end": 1691,
"loc": {
"start": {
"line": 64,
"column": 11
},
"end": {
"line": 64,
"column": 12
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "itemType",
"start": 1691,
"end": 1699,
"loc": {
"start": {
"line": 64,
"column": 12
},
"end": {
"line": 64,
"column": 20
}
}
},
{
"type": {
"label": "==/!=",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": 6,
"updateContext": null
},
"value": "===",
"start": 1700,
"end": 1703,
"loc": {
"start": {
"line": 64,
"column": 21
},
"end": {
"line": 64,
"column": 24
}
}
},
{
"type": {
"label": "string",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "color",
"start": 1704,
"end": 1711,
"loc": {
"start": {
"line": 64,
"column": 25
},
"end": {
"line": 64,
"column": 32
}
}
},
{
"type": {
"label": ")",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 1711,
"end": 1712,
"loc": {
"start": {
"line": 64,
"column": 32
},
"end": {
"line": 64,
"column": 33
}
}
},
{
"type": {
"label": "{",
"beforeExpr": true,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 1713,
"end": 1714,
"loc": {
"start": {
"line": 64,
"column": 34
},
"end": {
"line": 64,
"column": 35
}
}
},
{
"type": {
"label": "return",
"keyword": "return",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "return",
"start": 1728,
"end": 1734,
"loc": {
"start": {
"line": 65,
"column": 12
},
"end": {
"line": 65,
"column": 18
}
}
},
{
"type": "CommentBlock",
"value": "* @type {ColorItem} ",
"start": 1735,
"end": 1759,
"loc": {
"start": {
"line": 65,
"column": 19
},
"end": {
"line": 65,
"column": 43
}
}
},
{
"type": {
"label": "(",
"beforeExpr": true,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 1760,
"end": 1761,
"loc": {
"start": {
"line": 65,
"column": 44
},
"end": {
"line": 65,
"column": 45
}
}
},
{
"type": {
"label": "this",
"keyword": "this",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "this",
"start": 1761,
"end": 1765,
"loc": {
"start": {
"line": 65,
"column": 45
},
"end": {
"line": 65,
"column": 49
}
}
},
{
"type": {
"label": ".",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 1765,
"end": 1766,
"loc": {
"start": {
"line": 65,
"column": 49
},
"end": {
"line": 65,
"column": 50
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "storedItem",
"start": 1766,
"end": 1776,
"loc": {
"start": {
"line": 65,
"column": 50
},
"end": {
"line": 65,
"column": 60
}
}
},
{
"type": {
"label": ")",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 1776,
"end": 1777,
"loc": {
"start": {
"line": 65,
"column": 60
},
"end": {
"line": 65,
"column": 61
}
}
},
{
"type": {
"label": ".",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 1777,
"end": 1778,
"loc": {
"start": {
"line": 65,
"column": 61
},
"end": {
"line": 65,
"column": 62
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "color",
"start": 1778,
"end": 1783,
"loc": {
"start": {
"line": 65,
"column": 62
},
"end": {
"line": 65,
"column": 67
}
}
},
{
"type": {
"label": "==/!=",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": 6,
"updateContext": null
},
"value": "===",
"start": 1784,
"end": 1787,
"loc": {
"start": {
"line": 65,
"column": 68
},
"end": {
"line": 65,
"column": 71
}
}
},
{
"type": "CommentBlock",
"value": "* @type {ColorItem} ",
"start": 1788,
"end": 1812,
"loc": {
"start": {
"line": 65,
"column": 72
},
"end": {
"line": 65,
"column": 96
}
}
},
{
"type": {
"label": "(",
"beforeExpr": true,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 1813,
"end": 1814,
"loc": {
"start": {
"line": 65,
"column": 97
},
"end": {
"line": 65,
"column": 98
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "item",
"start": 1814,
"end": 1818,
"loc": {
"start": {
"line": 65,
"column": 98
},
"end": {
"line": 65,
"column": 102
}
}
},
{
"type": {
"label": ")",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 1818,
"end": 1819,
"loc": {
"start": {
"line": 65,
"column": 102
},
"end": {
"line": 65,
"column": 103
}
}
},
{
"type": {
"label": ".",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 1819,
"end": 1820,
"loc": {
"start": {
"line": 65,
"column": 103
},
"end": {
"line": 65,
"column": 104
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "color",
"start": 1820,
"end": 1825,
"loc": {
"start": {
"line": 65,
"column": 104
},
"end": {
"line": 65,
"column": 109
}
}
},
{
"type": {
"label": ";",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 1825,
"end": 1826,
"loc": {
"start": {
"line": 65,
"column": 109
},
"end": {
"line": 65,
"column": 110
}
}
},
{
"type": {
"label": "}",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 1836,
"end": 1837,
"loc": {
"start": {
"line": 66,
"column": 8
},
"end": {
"line": 66,
"column": 9
}
}
},
{
"type": {
"label": "if",
"keyword": "if",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "if",
"start": 1849,
"end": 1851,
"loc": {
"start": {
"line": 68,
"column": 8
},
"end": {
"line": 68,
"column": 10
}
}
},
{
"type": {
"label": "(",
"beforeExpr": true,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 1852,
"end": 1853,
"loc": {
"start": {
"line": 68,
"column": 11
},
"end": {
"line": 68,
"column": 12
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "itemType",
"start": 1853,
"end": 1861,
"loc": {
"start": {
"line": 68,
"column": 12
},
"end": {
"line": 68,
"column": 20
}
}
},
{
"type": {
"label": "==/!=",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": 6,
"updateContext": null
},
"value": "===",
"start": 1862,
"end": 1865,
"loc": {
"start": {
"line": 68,
"column": 21
},
"end": {
"line": 68,
"column": 24
}
}
},
{
"type": {
"label": "string",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "shape",
"start": 1866,
"end": 1873,
"loc": {
"start": {
"line": 68,
"column": 25
},
"end": {
"line": 68,
"column": 32
}
}
},
{
"type": {
"label": ")",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 1873,
"end": 1874,
"loc": {
"start": {
"line": 68,
"column": 32
},
"end": {
"line": 68,
"column": 33
}
}
},
{
"type": {
"label": "{",
"beforeExpr": true,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 1875,
"end": 1876,
"loc": {
"start": {
"line": 68,
"column": 34
},
"end": {
"line": 68,
"column": 35
}
}
},
{
"type": {
"label": "return",
"keyword": "return",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "return",
"start": 1890,
"end": 1896,
"loc": {
"start": {
"line": 69,
"column": 12
},
"end": {
"line": 69,
"column": 18
}
}
},
{
"type": {
"label": "(",
"beforeExpr": true,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 1897,
"end": 1898,
"loc": {
"start": {
"line": 69,
"column": 19
},
"end": {
"line": 69,
"column": 20
}
}
},
{
"type": "CommentBlock",
"value": "* @type {ShapeItem} ",
"start": 1916,
"end": 1940,
"loc": {
"start": {
"line": 70,
"column": 16
},
"end": {
"line": 70,
"column": 40
}
}
},
{
"type": {
"label": "(",
"beforeExpr": true,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 1941,
"end": 1942,
"loc": {
"start": {
"line": 70,
"column": 41
},
"end": {
"line": 70,
"column": 42
}
}
},
{
"type": {
"label": "this",
"keyword": "this",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "this",
"start": 1942,
"end": 1946,
"loc": {
"start": {
"line": 70,
"column": 42
},
"end": {
"line": 70,
"column": 46
}
}
},
{
"type": {
"label": ".",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 1946,
"end": 1947,
"loc": {
"start": {
"line": 70,
"column": 46
},
"end": {
"line": 70,
"column": 47
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "storedItem",
"start": 1947,
"end": 1957,
"loc": {
"start": {
"line": 70,
"column": 47
},
"end": {
"line": 70,
"column": 57
}
}
},
{
"type": {
"label": ")",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 1957,
"end": 1958,
"loc": {
"start": {
"line": 70,
"column": 57
},
"end": {
"line": 70,
"column": 58
}
}
},
{
"type": {
"label": ".",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 1958,
"end": 1959,
"loc": {
"start": {
"line": 70,
"column": 58
},
"end": {
"line": 70,
"column": 59
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "definition",
"start": 1959,
"end": 1969,
"loc": {
"start": {
"line": 70,
"column": 59
},
"end": {
"line": 70,
"column": 69
}
}
},
{
"type": {
"label": ".",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 1969,
"end": 1970,
"loc": {
"start": {
"line": 70,
"column": 69
},
"end": {
"line": 70,
"column": 70
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "getHash",
"start": 1970,
"end": 1977,
"loc": {
"start": {
"line": 70,
"column": 70
},
"end": {
"line": 70,
"column": 77
}
}
},
{
"type": {
"label": "(",
"beforeExpr": true,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 1977,
"end": 1978,
"loc": {
"start": {
"line": 70,
"column": 77
},
"end": {
"line": 70,
"column": 78
}
}
},
{
"type": {
"label": ")",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 1978,
"end": 1979,
"loc": {
"start": {
"line": 70,
"column": 78
},
"end": {
"line": 70,
"column": 79
}
}
},
{
"type": {
"label": "==/!=",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": 6,
"updateContext": null
},
"value": "===",
"start": 1980,
"end": 1983,
"loc": {
"start": {
"line": 70,
"column": 80
},
"end": {
"line": 70,
"column": 83
}
}
},
{
"type": "CommentBlock",
"value": "* @type {ShapeItem} ",
"start": 2001,
"end": 2025,
"loc": {
"start": {
"line": 71,
"column": 16
},
"end": {
"line": 71,
"column": 40
}
}
},
{
"type": {
"label": "(",
"beforeExpr": true,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 2026,
"end": 2027,
"loc": {
"start": {
"line": 71,
"column": 41
},
"end": {
"line": 71,
"column": 42
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "item",
"start": 2027,
"end": 2031,
"loc": {
"start": {
"line": 71,
"column": 42
},
"end": {
"line": 71,
"column": 46
}
}
},
{
"type": {
"label": ")",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 2031,
"end": 2032,
"loc": {
"start": {
"line": 71,
"column": 46
},
"end": {
"line": 71,
"column": 47
}
}
},
{
"type": {
"label": ".",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 2032,
"end": 2033,
"loc": {
"start": {
"line": 71,
"column": 47
},
"end": {
"line": 71,
"column": 48
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "definition",
"start": 2033,
"end": 2043,
"loc": {
"start": {
"line": 71,
"column": 48
},
"end": {
"line": 71,
"column": 58
}
}
},
{
"type": {
"label": ".",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 2043,
"end": 2044,
"loc": {
"start": {
"line": 71,
"column": 58
},
"end": {
"line": 71,
"column": 59
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "getHash",
"start": 2044,
"end": 2051,
"loc": {
"start": {
"line": 71,
"column": 59
},
"end": {
"line": 71,
"column": 66
}
}
},
{
"type": {
"label": "(",
"beforeExpr": true,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 2051,
"end": 2052,
"loc": {
"start": {
"line": 71,
"column": 66
},
"end": {
"line": 71,
"column": 67
}
}
},
{
"type": {
"label": ")",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 2052,
"end": 2053,
"loc": {
"start": {
"line": 71,
"column": 67
},
"end": {
"line": 71,
"column": 68
}
}
},
{
"type": {
"label": ")",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 2067,
"end": 2068,
"loc": {
"start": {
"line": 72,
"column": 12
},
"end": {
"line": 72,
"column": 13
}
}
},
{
"type": {
"label": ";",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 2068,
"end": 2069,
"loc": {
"start": {
"line": 72,
"column": 13
},
"end": {
"line": 72,
"column": 14
}
}
},
{
"type": {
"label": "}",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 2079,
"end": 2080,
"loc": {
"start": {
"line": 73,
"column": 8
},
"end": {
"line": 73,
"column": 9
}
}
},
{
"type": {
"label": "return",
"keyword": "return",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "return",
"start": 2090,
"end": 2096,
"loc": {
"start": {
"line": 74,
"column": 8
},
"end": {
"line": 74,
"column": 14
}
}
},
{
"type": {
"label": "false",
"keyword": "false",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "false",
"start": 2097,
"end": 2102,
"loc": {
"start": {
"line": 74,
"column": 15
},
"end": {
"line": 74,
"column": 20
}
}
},
{
"type": {
"label": ";",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 2102,
"end": 2103,
"loc": {
"start": {
"line": 74,
"column": 20
},
"end": {
"line": 74,
"column": 21
}
}
},
{
"type": {
"label": "}",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 2109,
"end": 2110,
"loc": {
"start": {
"line": 75,
"column": 4
},
"end": {
"line": 75,
"column": 5
}
}
},
{
"type": "CommentBlock",
"value": "*\r\n * Returns whether the storage is full\r\n * @returns {boolean}\r\n ",
"start": 2118,
"end": 2201,
"loc": {
"start": {
"line": 77,
"column": 4
},
"end": {
"line": 80,
"column": 7
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "getIsFull",
"start": 2207,
"end": 2216,
"loc": {
"start": {
"line": 81,
"column": 4
},
"end": {
"line": 81,
"column": 13
}
}
},
{
"type": {
"label": "(",
"beforeExpr": true,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 2216,
"end": 2217,
"loc": {
"start": {
"line": 81,
"column": 13
},
"end": {
"line": 81,
"column": 14
}
}
},
{
"type": {
"label": ")",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 2217,
"end": 2218,
"loc": {
"start": {
"line": 81,
"column": 14
},
"end": {
"line": 81,
"column": 15
}
}
},
{
"type": {
"label": "{",
"beforeExpr": true,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 2219,
"end": 2220,
"loc": {
"start": {
"line": 81,
"column": 16
},
"end": {
"line": 81,
"column": 17
}
}
},
{
"type": {
"label": "return",
"keyword": "return",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "return",
"start": 2230,
"end": 2236,
"loc": {
"start": {
"line": 82,
"column": 8
},
"end": {
"line": 82,
"column": 14
}
}
},
{
"type": {
"label": "this",
"keyword": "this",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "this",
"start": 2237,
"end": 2241,
"loc": {
"start": {
"line": 82,
"column": 15
},
"end": {
"line": 82,
"column": 19
}
}
},
{
"type": {
"label": ".",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 2241,
"end": 2242,
"loc": {
"start": {
"line": 82,
"column": 19
},
"end": {
"line": 82,
"column": 20
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "storedCount",
"start": 2242,
"end": 2253,
"loc": {
"start": {
"line": 82,
"column": 20
},
"end": {
"line": 82,
"column": 31
}
}
},
{
"type": {
"label": "</>",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": 7,
"updateContext": null
},
"value": ">=",
"start": 2254,
"end": 2256,
"loc": {
"start": {
"line": 82,
"column": 32
},
"end": {
"line": 82,
"column": 34
}
}
},
{
"type": {
"label": "this",
"keyword": "this",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "this",
"start": 2257,
"end": 2261,
"loc": {
"start": {
"line": 82,
"column": 35
},
"end": {
"line": 82,
"column": 39
}
}
},
{
"type": {
"label": ".",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 2261,
"end": 2262,
"loc": {
"start": {
"line": 82,
"column": 39
},
"end": {
"line": 82,
"column": 40
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "maximumStorage",
"start": 2262,
"end": 2276,
"loc": {
"start": {
"line": 82,
"column": 40
},
"end": {
"line": 82,
"column": 54
}
}
},
{
"type": {
"label": ";",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 2276,
"end": 2277,
"loc": {
"start": {
"line": 82,
"column": 54
},
"end": {
"line": 82,
"column": 55
}
}
},
{
"type": {
"label": "}",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 2283,
"end": 2284,
"loc": {
"start": {
"line": 83,
"column": 4
},
"end": {
"line": 83,
"column": 5
}
}
},
{
"type": "CommentBlock",
"value": "*\r\n * @param {BaseItem} item\r\n ",
"start": 2292,
"end": 2335,
"loc": {
"start": {
"line": 85,
"column": 4
},
"end": {
"line": 87,
"column": 7
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "takeItem",
"start": 2341,
"end": 2349,
"loc": {
"start": {
"line": 88,
"column": 4
},
"end": {
"line": 88,
"column": 12
}
}
},
{
"type": {
"label": "(",
"beforeExpr": true,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 2349,
"end": 2350,
"loc": {
"start": {
"line": 88,
"column": 12
},
"end": {
"line": 88,
"column": 13
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "item",
"start": 2350,
"end": 2354,
"loc": {
"start": {
"line": 88,
"column": 13
},
"end": {
"line": 88,
"column": 17
}
}
},
{
"type": {
"label": ")",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 2354,
"end": 2355,
"loc": {
"start": {
"line": 88,
"column": 17
},
"end": {
"line": 88,
"column": 18
}
}
},
{
"type": {
"label": "{",
"beforeExpr": true,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 2356,
"end": 2357,
"loc": {
"start": {
"line": 88,
"column": 19
},
"end": {
"line": 88,
"column": 20
}
}
},
{
"type": {
"label": "this",
"keyword": "this",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "this",
"start": 2367,
"end": 2371,
"loc": {
"start": {
"line": 89,
"column": 8
},
"end": {
"line": 89,
"column": 12
}
}
},
{
"type": {
"label": ".",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 2371,
"end": 2372,
"loc": {
"start": {
"line": 89,
"column": 12
},
"end": {
"line": 89,
"column": 13
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "storedItem",
"start": 2372,
"end": 2382,
"loc": {
"start": {
"line": 89,
"column": 13
},
"end": {
"line": 89,
"column": 23
}
}
},
{
"type": {
"label": "=",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": true,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "=",
"start": 2383,
"end": 2384,
"loc": {
"start": {
"line": 89,
"column": 24
},
"end": {
"line": 89,
"column": 25
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "item",
"start": 2385,
"end": 2389,
"loc": {
"start": {
"line": 89,
"column": 26
},
"end": {
"line": 89,
"column": 30
}
}
},
{
"type": {
"label": ";",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 2389,
"end": 2390,
"loc": {
"start": {
"line": 89,
"column": 30
},
"end": {
"line": 89,
"column": 31
}
}
},
{
"type": {
"label": "this",
"keyword": "this",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"value": "this",
"start": 2400,
"end": 2404,
"loc": {
"start": {
"line": 90,
"column": 8
},
"end": {
"line": 90,
"column": 12
}
}
},
{
"type": {
"label": ".",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 2404,
"end": 2405,
"loc": {
"start": {
"line": 90,
"column": 12
},
"end": {
"line": 90,
"column": 13
}
}
},
{
"type": {
"label": "name",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"value": "storedCount",
"start": 2405,
"end": 2416,
"loc": {
"start": {
"line": 90,
"column": 13
},
"end": {
"line": 90,
"column": 24
}
}
},
{
"type": {
"label": "++/--",
"beforeExpr": false,
"startsExpr": true,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": true,
"postfix": true,
"binop": null
},
"value": "++",
"start": 2416,
"end": 2418,
"loc": {
"start": {
"line": 90,
"column": 24
},
"end": {
"line": 90,
"column": 26
}
}
},
{
"type": {
"label": ";",
"beforeExpr": true,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 2418,
"end": 2419,
"loc": {
"start": {
"line": 90,
"column": 26
},
"end": {
"line": 90,
"column": 27
}
}
},
{
"type": {
"label": "}",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 2425,
"end": 2426,
"loc": {
"start": {
"line": 91,
"column": 4
},
"end": {
"line": 91,
"column": 5
}
}
},
{
"type": {
"label": "}",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null
},
"start": 2428,
"end": 2429,
"loc": {
"start": {
"line": 92,
"column": 0
},
"end": {
"line": 92,
"column": 1
}
}
},
{
"type": {
"label": "eof",
"beforeExpr": false,
"startsExpr": false,
"rightAssociative": false,
"isLoop": false,
"isAssign": false,
"prefix": false,
"postfix": false,
"binop": null,
"updateContext": null
},
"start": 2431,
"end": 2431,
"loc": {
"start": {
"line": 93,
"column": 0
},
"end": {
"line": 93,
"column": 0
}
}
}
]
}