User prompt
Fix Bug: 'TypeError: this.hasResources is not a function' in this line: 'if (utility.action === 'trade' && this.hasResources()) {' Line Number: 70
User prompt
Fix Bug: 'TypeError: this.hasResources is not a function' in this line: 'if (utility.action === 'trade' && this.hasResources()) {' Line Number: 70
User prompt
Fix Bug: 'TypeError: this.hasResources is not a function' in this line: 'if (utility.action === 'trade' && this.hasResources()) {' Line Number: 70
User prompt
Fix Bug: 'TypeError: this.hasResources is not a function' in this line: 'if (utility.action === 'trade' && this.hasResources()) {' Line Number: 70
User prompt
Fix Bug: 'TypeError: this.hasResources is not a function' in this line: 'if (utility.action === 'trade' && this.hasResources()) {' Line Number: 70
User prompt
Fix Bug: 'TypeError: this.hasResources is not a function' in this line: 'if (utility.action === 'trade' && this.hasResources()) {' Line Number: 70
User prompt
Fix Bug: 'TypeError: this.hasResources is not a function' in this line: 'if (utility.action === 'trade' && this.hasResources()) {' Line Number: 70
User prompt
Fix Bug: 'TypeError: this.hasResources is not a function' in this line: 'if (utility.action === 'trade' && this.hasResources()) {' Line Number: 70
User prompt
Fix Bug: 'TypeError: this.hasResources is not a function' in this line: 'if (utility.action === 'trade' && this.hasResources()) {' Line Number: 70
User prompt
Fix Bug: 'TypeError: this.hasResources is not a function' in this line: 'if (utility.action === 'trade' && this.hasResources()) {' Line Number: 70
User prompt
Fix Bug: 'TypeError: this.hasResources is not a function' in this line: 'if (utility.action === 'trade' && this.hasResources()) {' Line Number: 70
User prompt
Fix Bug: 'TypeError: this.hasResources is not a function' in this line: 'if (utility.action === 'trade' && this.hasResources()) {' Line Number: 70
User prompt
Fix Bug: 'TypeError: this.hasResources is not a function' in this line: 'if (utility.action === 'trade' && this.hasResources()) {' Line Number: 70
User prompt
Fix Bug: 'TypeError: this.hasResources is not a function' in this line: 'if (utility.action === 'trade' && this.hasResources()) {' Line Number: 70
User prompt
Fix Bug: 'TypeError: this.hasResources is not a function' in this line: 'if (utility.action === 'trade' && this.hasResources()) {' Line Number: 70
User prompt
Fix Bug: 'TypeError: this.hasResources is not a function' in this line: 'if (utility.action === 'trade' && this.hasResources()) {' Line Number: 70
User prompt
Fix Bug: 'TypeError: this.hasResources is not a function' in this line: 'if (utility.action === 'trade' && this.hasResources()) {' Line Number: 70
User prompt
Fix Bug: 'TypeError: this.hasResources is not a function' in this line: 'if (utility.action === 'trade' && this.hasResources()) {' Line Number: 70
User prompt
Fix Bug: 'TypeError: this.hasResources is not a function' in this line: 'if (utility.action === 'trade' && this.hasResources()) {' Line Number: 70
User prompt
Fix Bug: 'TypeError: this.hasResources is not a function' in this line: 'if (utility.action === 'trade' && this.hasResources()) {' Line Number: 70
User prompt
Fix Bug: 'TypeError: this.hasResources is not a function' in this line: 'if (utility.action === 'trade' && this.hasResources()) {' Line Number: 70
User prompt
Fix Bug: 'TypeError: this.hasResources is not a function' in this line: 'if (utility.action === 'trade' && this.hasResources()) {' Line Number: 70
User prompt
Fix Bug: 'TypeError: this.hasResources is not a function' in this line: 'if (utility.action === 'trade' && this.hasResources()) {' Line Number: 70
User prompt
Fix Bug: 'TypeError: this.hasResources is not a function' in this line: 'if (utility.action === 'trade' && this.hasResources()) {' Line Number: 70
User prompt
Fix Bug: 'TypeError: this.hasResources is not a function' in this line: 'if (utility.action === 'trade' && this.hasResources()) {' Line Number: 70
===================================================================
--- original.js
+++ change.js
@@ -109,10 +109,10 @@
if (this.tiredness <= 0) {
this.state = 'atHome';
}
};
- self.hasResources = function () {
- return self.carriedWood > 0 || self.carriedRock > 0 || self.carriedFood > 0;
+ Villager.prototype.hasResources = function () {
+ return this.carriedWood > 0 || this.carriedRock > 0 || this.carriedFood > 0;
};
Villager.prototype.isDoingSomething = function () {
return this.state === 'goingToWork' || this.state === 'working' || this.state === 'goingHome' || this.state === 'resting' || this.state === 'plantingTree' || this.state === 'buildingHouse';
};
A background of a paysage with plain and without tree or montainbut no water see from the top in the air 100m by 100m Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
One human medieval villager in a warcraft 2 style Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
a house in a warcraft 2 style Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
A tree a rock and crambery in a RTS style Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
A heart comic style Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
A cloud in a comic style Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
A market in a RTS fantasy style Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
An Inn in a RTS fantasy style Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
An school in a RTS fantasy style Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
An bakery in a RTS fantasy style Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
A well in a RTS fantasy style Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
A tree in a rts style Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
An apple in a rts style Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
A rock in a rts style Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
A home in a RTS and fantasy style. Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
A brewery in a fantasy rts style. Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
A lumberjack in a fantasy rts style. Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
a marketplace in a fantasy rts style. Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
a festival in a fantasy rts style. Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.