"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; Eif ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { Eif (protoProps) defineProperties(Constructor.prototype, protoProps); Iif (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }();
function _classCallCheck(instance, Constructor) { Iif (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
var Landmark = function () {
function Landmark(_ref) {
var name = _ref.name,
cost = _ref.cost,
description = _ref.description;
_classCallCheck(this, Landmark);
this.name = name;
this.cost = cost;
this.description = description;
// set to default state
this.activate();
this.destroy();
}
_createClass(Landmark, [{
key: "destroy",
value: function destroy() {
if (this.name !== "City Hall") this.activated = false;
}
}, {
key: "activate",
value: function activate() {
this.activated = true;
}
}]);
return Landmark;
}();
exports.default = Landmark;
//# sourceMappingURL=Landmark.js.map |