Page MenuHomeWildfire Games

Also account for elevation for melee units.
Needs ReviewPublic

Authored by Freagarach on Aug 8 2019, 12:46 PM.
This revision needs review, but there are no reviewers specified.

Details

Reviewers
None
Summary

This adds a debonus to the range of melee units when standing higher or lower.
Not sure whether anyone would like this in or not, but it works and is realistic.
(Probably no one wants it in: it gives no noticable difference in attack range and when it would be, players might not understand where the difference comes from. But since I already uploaded the patch earlier, I'll keep it open. Feel free to close as won't be in, as appropriate.)

Test Plan

Verify that melee units can still attack eachother and that they have to get a tad closer to actually attack when standing higher or lower than their targets.

Event Timeline

Freagarach created this revision.Aug 8 2019, 12:46 PM
Freagarach created this object with visibility "No One".
Freagarach updated this revision to Diff 9678.Sep 9 2019, 3:22 PM
Freagarach edited the summary of this revision. (Show Details)

Fixed test.

Freagarach edited the summary of this revision. (Show Details)
Freagarach edited the test plan for this revision. (Show Details)
Freagarach changed the visibility from "No One" to "Public (No Login Required)".

Updated test to use code style update (, at end of object property list spanning multiple lines).

Freagarach edited the summary of this revision. (Show Details)Sat, Dec 21, 12:01 PM

Successful build - Chance fights ever on the side of the prudent.

Link to build: https://jenkins.wildfiregames.com/job/vs2015-differential/823/display/redirect

Successful build - Chance fights ever on the side of the prudent.

Linter detected issues:
Executing section Source...
Executing section JS...
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'SetInterval' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|  35|  35| 
|  36|  36| 
|  37|  37| 	AddMock(SYSTEM_ENTITY, IID_Timer, {
|  38|    |-		SetInterval: function() { },
|    |  38|+		"SetInterval": function() { },
|  39|  39| 		SetTimeout: function() { },
|  40|  40| 	});
|  41|  41| 
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'SetTimeout' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|  36|  36| 
|  37|  37| 	AddMock(SYSTEM_ENTITY, IID_Timer, {
|  38|  38| 		SetInterval: function() { },
|  39|    |-		SetTimeout: function() { },
|    |  39|+		"SetTimeout": function() { },
|  40|  40| 	});
|  41|  41| 
|  42|  42| 	AddMock(SYSTEM_ENTITY, IID_RangeManager, {
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'CreateActiveQuery' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|  40|  40| 	});
|  41|  41| 
|  42|  42| 	AddMock(SYSTEM_ENTITY, IID_RangeManager, {
|  43|    |-		CreateActiveQuery: function(ent, minRange, maxRange, players, iid, flags) {
|    |  43|+		"CreateActiveQuery": function(ent, minRange, maxRange, players, iid, flags) {
|  44|  44| 			return 1;
|  45|  45| 		},
|  46|  46| 		EnableActiveQuery: function(id) { },
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'EnableActiveQuery' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|  43|  43| 		CreateActiveQuery: function(ent, minRange, maxRange, players, iid, flags) {
|  44|  44| 			return 1;
|  45|  45| 		},
|  46|    |-		EnableActiveQuery: function(id) { },
|    |  46|+		"EnableActiveQuery": function(id) { },
|  47|  47| 		ResetActiveQuery: function(id) { if (mode == 0) return []; else return [enemy]; },
|  48|  48| 		DisableActiveQuery: function(id) { },
|  49|  49| 		GetEntityFlagMask: function(identifier) { },
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'ResetActiveQuery' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|  44|  44| 			return 1;
|  45|  45| 		},
|  46|  46| 		EnableActiveQuery: function(id) { },
|  47|    |-		ResetActiveQuery: function(id) { if (mode == 0) return []; else return [enemy]; },
|    |  47|+		"ResetActiveQuery": function(id) { if (mode == 0) return []; else return [enemy]; },
|  48|  48| 		DisableActiveQuery: function(id) { },
|  49|  49| 		GetEntityFlagMask: function(identifier) { },
|  50|  50| 	});
|    | [NORMAL] ESLintBear (no-else-return):
|    | Unnecessary 'else' after 'return'.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|  44|  44| 			return 1;
|  45|  45| 		},
|  46|  46| 		EnableActiveQuery: function(id) { },
|  47|    |-		ResetActiveQuery: function(id) { if (mode == 0) return []; else return [enemy]; },
|    |  47|+		ResetActiveQuery: function(id) { if (mode == 0) return []; return [enemy]; },
|  48|  48| 		DisableActiveQuery: function(id) { },
|  49|  49| 		GetEntityFlagMask: function(identifier) { },
|  50|  50| 	});
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'DisableActiveQuery' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|  45|  45| 		},
|  46|  46| 		EnableActiveQuery: function(id) { },
|  47|  47| 		ResetActiveQuery: function(id) { if (mode == 0) return []; else return [enemy]; },
|  48|    |-		DisableActiveQuery: function(id) { },
|    |  48|+		"DisableActiveQuery": function(id) { },
|  49|  49| 		GetEntityFlagMask: function(identifier) { },
|  50|  50| 	});
|  51|  51| 
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'GetEntityFlagMask' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|  46|  46| 		EnableActiveQuery: function(id) { },
|  47|  47| 		ResetActiveQuery: function(id) { if (mode == 0) return []; else return [enemy]; },
|  48|  48| 		DisableActiveQuery: function(id) { },
|  49|    |-		GetEntityFlagMask: function(identifier) { },
|    |  49|+		"GetEntityFlagMask": function(identifier) { },
|  50|  50| 	});
|  51|  51| 
|  52|  52| 	AddMock(SYSTEM_ENTITY, IID_TemplateManager, {
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'GetCurrentTemplateName' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|  50|  50| 	});
|  51|  51| 
|  52|  52| 	AddMock(SYSTEM_ENTITY, IID_TemplateManager, {
|  53|    |-		GetCurrentTemplateName: function(ent) { return "special/formations/line_closed"; },
|    |  53|+		"GetCurrentTemplateName": function(ent) { return "special/formations/line_closed"; },
|  54|  54| 	});
|  55|  55| 
|  56|  56| 	AddMock(SYSTEM_ENTITY, IID_PlayerManager, {
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'GetPlayerByID' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|  54|  54| 	});
|  55|  55| 
|  56|  56| 	AddMock(SYSTEM_ENTITY, IID_PlayerManager, {
|  57|    |-		GetPlayerByID: function(id) { return playerEntity; },
|    |  57|+		"GetPlayerByID": function(id) { return playerEntity; },
|  58|  58| 		GetNumPlayers: function() { return 2; },
|  59|  59| 	});
|  60|  60| 
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'GetNumPlayers' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|  55|  55| 
|  56|  56| 	AddMock(SYSTEM_ENTITY, IID_PlayerManager, {
|  57|  57| 		GetPlayerByID: function(id) { return playerEntity; },
|  58|    |-		GetNumPlayers: function() { return 2; },
|    |  58|+		"GetNumPlayers": function() { return 2; },
|  59|  59| 	});
|  60|  60| 
|  61|  61| 	AddMock(playerEntity, IID_Player, {
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'IsAlly' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|  59|  59| 	});
|  60|  60| 
|  61|  61| 	AddMock(playerEntity, IID_Player, {
|  62|    |-		IsAlly: function() { return false; },
|    |  62|+		"IsAlly": function() { return false; },
|  63|  63| 		IsEnemy: function() { return true; },
|  64|  64| 		GetEnemies: function() { return []; },
|  65|  65| 	});
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'IsEnemy' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|  60|  60| 
|  61|  61| 	AddMock(playerEntity, IID_Player, {
|  62|  62| 		IsAlly: function() { return false; },
|  63|    |-		IsEnemy: function() { return true; },
|    |  63|+		"IsEnemy": function() { return true; },
|  64|  64| 		GetEnemies: function() { return []; },
|  65|  65| 	});
|  66|  66| 
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'GetEnemies' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|  61|  61| 	AddMock(playerEntity, IID_Player, {
|  62|  62| 		IsAlly: function() { return false; },
|  63|  63| 		IsEnemy: function() { return true; },
|  64|    |-		GetEnemies: function() { return []; },
|    |  64|+		"GetEnemies": function() { return []; },
|  65|  65| 	});
|  66|  66| 
|  67|  67| 	AddMock(SYSTEM_ENTITY, IID_ObstructionManager, {
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'GetClassesList' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|  71|  71| 	var unitAI = ConstructComponent(unit, "UnitAI", { "FormationController": "false", "DefaultStance": "aggressive" });
|  72|  72| 
|  73|  73| 	AddMock(unit, IID_Identity, {
|  74|    |-		GetClassesList: function() { return []; },
|    |  74|+		"GetClassesList": function() { return []; },
|  75|  75| 	});
|  76|  76| 
|  77|  77| 	AddMock(unit, IID_Ownership, {
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'GetOwner' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|  75|  75| 	});
|  76|  76| 
|  77|  77| 	AddMock(unit, IID_Ownership, {
|  78|    |-		GetOwner: function() { return 1; },
|    |  78|+		"GetOwner": function() { return 1; },
|  79|  79| 	});
|  80|  80| 
|  81|  81| 	AddMock(unit, IID_Position, {
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'GetTurretParent' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|  79|  79| 	});
|  80|  80| 
|  81|  81| 	AddMock(unit, IID_Position, {
|  82|    |-		GetTurretParent: function() { return INVALID_ENTITY; },
|    |  82|+		"GetTurretParent": function() { return INVALID_ENTITY; },
|  83|  83| 		GetPosition: function() { return new Vector3D(); },
|  84|  84| 		GetPosition2D: function() { return new Vector2D(); },
|  85|  85| 		GetRotation: function() { return { "y": 0 }; },
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'GetPosition' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|  80|  80| 
|  81|  81| 	AddMock(unit, IID_Position, {
|  82|  82| 		GetTurretParent: function() { return INVALID_ENTITY; },
|  83|    |-		GetPosition: function() { return new Vector3D(); },
|    |  83|+		"GetPosition": function() { return new Vector3D(); },
|  84|  84| 		GetPosition2D: function() { return new Vector2D(); },
|  85|  85| 		GetRotation: function() { return { "y": 0 }; },
|  86|  86| 		IsInWorld: function() { return true; },
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'GetPosition2D' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|  81|  81| 	AddMock(unit, IID_Position, {
|  82|  82| 		GetTurretParent: function() { return INVALID_ENTITY; },
|  83|  83| 		GetPosition: function() { return new Vector3D(); },
|  84|    |-		GetPosition2D: function() { return new Vector2D(); },
|    |  84|+		"GetPosition2D": function() { return new Vector2D(); },
|  85|  85| 		GetRotation: function() { return { "y": 0 }; },
|  86|  86| 		IsInWorld: function() { return true; },
|  87|  87| 	});
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'GetRotation' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|  82|  82| 		GetTurretParent: function() { return INVALID_ENTITY; },
|  83|  83| 		GetPosition: function() { return new Vector3D(); },
|  84|  84| 		GetPosition2D: function() { return new Vector2D(); },
|  85|    |-		GetRotation: function() { return { "y": 0 }; },
|    |  85|+		"GetRotation": function() { return { "y": 0 }; },
|  86|  86| 		IsInWorld: function() { return true; },
|  87|  87| 	});
|  88|  88| 
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'IsInWorld' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|  83|  83| 		GetPosition: function() { return new Vector3D(); },
|  84|  84| 		GetPosition2D: function() { return new Vector2D(); },
|  85|  85| 		GetRotation: function() { return { "y": 0 }; },
|  86|    |-		IsInWorld: function() { return true; },
|    |  86|+		"IsInWorld": function() { return true; },
|  87|  87| 	});
|  88|  88| 
|  89|  89| 	AddMock(unit, IID_UnitMotion, {
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'GetRange' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|  96|  96| 	});
|  97|  97| 
|  98|  98| 	AddMock(unit, IID_Vision, {
|  99|    |-		GetRange: function() { return 10; },
|    |  99|+		"GetRange": function() { return 10; },
| 100| 100| 	});
| 101| 101| 
| 102| 102| 	AddMock(unit, IID_Attack, {
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'GetRange' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 100| 100| 	});
| 101| 101| 
| 102| 102| 	AddMock(unit, IID_Attack, {
| 103|    |-		GetRange: function() { return { "max": 10, "min": 0, "elevationBonus": 0 }; },
|    | 103|+		"GetRange": function() { return { "max": 10, "min": 0, "elevationBonus": 0 }; },
| 104| 104| 		GetFullAttackRange: function() { return { "max": 40, "min": 0, "elevationBonus": 0 }; },
| 105| 105| 		GetBestAttackAgainst: function(t) { return "melee"; },
| 106| 106| 		GetPreference: function(t) { return 0; },
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'GetFullAttackRange' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 101| 101| 
| 102| 102| 	AddMock(unit, IID_Attack, {
| 103| 103| 		GetRange: function() { return { "max": 10, "min": 0, "elevationBonus": 0 }; },
| 104|    |-		GetFullAttackRange: function() { return { "max": 40, "min": 0, "elevationBonus": 0 }; },
|    | 104|+		"GetFullAttackRange": function() { return { "max": 40, "min": 0, "elevationBonus": 0 }; },
| 105| 105| 		GetBestAttackAgainst: function(t) { return "melee"; },
| 106| 106| 		GetPreference: function(t) { return 0; },
| 107| 107| 		GetTimers: function() { return { "prepare": 500, "repeat": 1000 }; },
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'GetBestAttackAgainst' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 102| 102| 	AddMock(unit, IID_Attack, {
| 103| 103| 		GetRange: function() { return { "max": 10, "min": 0, "elevationBonus": 0 }; },
| 104| 104| 		GetFullAttackRange: function() { return { "max": 40, "min": 0, "elevationBonus": 0 }; },
| 105|    |-		GetBestAttackAgainst: function(t) { return "melee"; },
|    | 105|+		"GetBestAttackAgainst": function(t) { return "melee"; },
| 106| 106| 		GetPreference: function(t) { return 0; },
| 107| 107| 		GetTimers: function() { return { "prepare": 500, "repeat": 1000 }; },
| 108| 108| 		CanAttack: function(v) { return true; },
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'GetPreference' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 103| 103| 		GetRange: function() { return { "max": 10, "min": 0, "elevationBonus": 0 }; },
| 104| 104| 		GetFullAttackRange: function() { return { "max": 40, "min": 0, "elevationBonus": 0 }; },
| 105| 105| 		GetBestAttackAgainst: function(t) { return "melee"; },
| 106|    |-		GetPreference: function(t) { return 0; },
|    | 106|+		"GetPreference": function(t) { return 0; },
| 107| 107| 		GetTimers: function() { return { "prepare": 500, "repeat": 1000 }; },
| 108| 108| 		CanAttack: function(v) { return true; },
| 109| 109| 		CompareEntitiesByPreference: function(a, b) { return 0; },
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'GetTimers' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 104| 104| 		GetFullAttackRange: function() { return { "max": 40, "min": 0, "elevationBonus": 0 }; },
| 105| 105| 		GetBestAttackAgainst: function(t) { return "melee"; },
| 106| 106| 		GetPreference: function(t) { return 0; },
| 107|    |-		GetTimers: function() { return { "prepare": 500, "repeat": 1000 }; },
|    | 107|+		"GetTimers": function() { return { "prepare": 500, "repeat": 1000 }; },
| 108| 108| 		CanAttack: function(v) { return true; },
| 109| 109| 		CompareEntitiesByPreference: function(a, b) { return 0; },
| 110| 110| 	});
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'CanAttack' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 105| 105| 		GetBestAttackAgainst: function(t) { return "melee"; },
| 106| 106| 		GetPreference: function(t) { return 0; },
| 107| 107| 		GetTimers: function() { return { "prepare": 500, "repeat": 1000 }; },
| 108|    |-		CanAttack: function(v) { return true; },
|    | 108|+		"CanAttack": function(v) { return true; },
| 109| 109| 		CompareEntitiesByPreference: function(a, b) { return 0; },
| 110| 110| 	});
| 111| 111| 
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'CompareEntitiesByPreference' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 106| 106| 		GetPreference: function(t) { return 0; },
| 107| 107| 		GetTimers: function() { return { "prepare": 500, "repeat": 1000 }; },
| 108| 108| 		CanAttack: function(v) { return true; },
| 109|    |-		CompareEntitiesByPreference: function(a, b) { return 0; },
|    | 109|+		"CompareEntitiesByPreference": function(a, b) { return 0; },
| 110| 110| 	});
| 111| 111| 
| 112| 112| 	unitAI.OnCreate();
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'GetHitpoints' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 117| 117| 	if (mode == 1)
| 118| 118| 	{
| 119| 119| 		AddMock(enemy, IID_Health, {
| 120|    |-			GetHitpoints: function() { return 10; },
|    | 120|+			"GetHitpoints": function() { return 10; },
| 121| 121| 		});
| 122| 122| 		AddMock(enemy, IID_UnitAI, {
| 123| 123| 			IsAnimal: function() { return false; }
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'IsAnimal' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 120| 120| 			GetHitpoints: function() { return 10; },
| 121| 121| 		});
| 122| 122| 		AddMock(enemy, IID_UnitAI, {
| 123|    |-			IsAnimal: function() { return false; }
|    | 123|+			"IsAnimal": function() { return false; }
| 124| 124| 		});
| 125| 125| 
| 126| 126| 		AddMock(enemy, IID_Position, {
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'GetTurretParent' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 124| 124| 		});
| 125| 125| 
| 126| 126| 		AddMock(enemy, IID_Position, {
| 127|    |-			GetTurretParent: function() { return INVALID_ENTITY; },
|    | 127|+			"GetTurretParent": function() { return INVALID_ENTITY; },
| 128| 128| 			GetPosition: function() { return new Vector3D(); },
| 129| 129| 			GetPosition2D: function() { return new Vector2D(); },
| 130| 130| 			IsInWorld: function() { return true; },
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'GetPosition' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 125| 125| 
| 126| 126| 		AddMock(enemy, IID_Position, {
| 127| 127| 			GetTurretParent: function() { return INVALID_ENTITY; },
| 128|    |-			GetPosition: function() { return new Vector3D(); },
|    | 128|+			"GetPosition": function() { return new Vector3D(); },
| 129| 129| 			GetPosition2D: function() { return new Vector2D(); },
| 130| 130| 			IsInWorld: function() { return true; },
| 131| 131| 		});
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'GetPosition2D' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 126| 126| 		AddMock(enemy, IID_Position, {
| 127| 127| 			GetTurretParent: function() { return INVALID_ENTITY; },
| 128| 128| 			GetPosition: function() { return new Vector3D(); },
| 129|    |-			GetPosition2D: function() { return new Vector2D(); },
|    | 129|+			"GetPosition2D": function() { return new Vector2D(); },
| 130| 130| 			IsInWorld: function() { return true; },
| 131| 131| 		});
| 132| 132| 	}
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'IsInWorld' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 127| 127| 			GetTurretParent: function() { return INVALID_ENTITY; },
| 128| 128| 			GetPosition: function() { return new Vector3D(); },
| 129| 129| 			GetPosition2D: function() { return new Vector2D(); },
| 130|    |-			IsInWorld: function() { return true; },
|    | 130|+			"IsInWorld": function() { return true; },
| 131| 131| 		});
| 132| 132| 	}
| 133| 133| 	else if (mode == 2)
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'GetHitpoints' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 132| 132| 	}
| 133| 133| 	else if (mode == 2)
| 134| 134| 		AddMock(enemy, IID_Health, {
| 135|    |-			GetHitpoints: function() { return 0; },
|    | 135|+			"GetHitpoints": function() { return 0; },
| 136| 136| 		});
| 137| 137| 
| 138| 138| 	var controllerFormation = ConstructComponent(controller, "Formation", {"FormationName": "Line Closed", "FormationShape": "square", "ShiftRows": "false", "SortingClasses": "", "WidthDepthRatio": 1, "UnitSeparationWidthMultiplier": 1, "UnitSeparationDepthMultiplier": 1, "SpeedMultiplier": 1, "Sloppyness": 0});
|    | [NORMAL] ESLintBear (object-curly-spacing):
|    | A space is required after '{'.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 135| 135| 			GetHitpoints: function() { return 0; },
| 136| 136| 		});
| 137| 137| 
| 138|    |-	var controllerFormation = ConstructComponent(controller, "Formation", {"FormationName": "Line Closed", "FormationShape": "square", "ShiftRows": "false", "SortingClasses": "", "WidthDepthRatio": 1, "UnitSeparationWidthMultiplier": 1, "UnitSeparationDepthMultiplier": 1, "SpeedMultiplier": 1, "Sloppyness": 0});
|    | 138|+	var controllerFormation = ConstructComponent(controller, "Formation", { "FormationName": "Line Closed", "FormationShape": "square", "ShiftRows": "false", "SortingClasses": "", "WidthDepthRatio": 1, "UnitSeparationWidthMultiplier": 1, "UnitSeparationDepthMultiplier": 1, "SpeedMultiplier": 1, "Sloppyness": 0});
| 139| 139| 	var controllerAI = ConstructComponent(controller, "UnitAI", { "FormationController": "true", "DefaultStance": "aggressive" });
| 140| 140| 
| 141| 141| 	AddMock(controller, IID_Position, {
|    | [NORMAL] ESLintBear (object-curly-spacing):
|    | A space is required before '}'.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 135| 135| 			GetHitpoints: function() { return 0; },
| 136| 136| 		});
| 137| 137| 
| 138|    |-	var controllerFormation = ConstructComponent(controller, "Formation", {"FormationName": "Line Closed", "FormationShape": "square", "ShiftRows": "false", "SortingClasses": "", "WidthDepthRatio": 1, "UnitSeparationWidthMultiplier": 1, "UnitSeparationDepthMultiplier": 1, "SpeedMultiplier": 1, "Sloppyness": 0});
|    | 138|+	var controllerFormation = ConstructComponent(controller, "Formation", {"FormationName": "Line Closed", "FormationShape": "square", "ShiftRows": "false", "SortingClasses": "", "WidthDepthRatio": 1, "UnitSeparationWidthMultiplier": 1, "UnitSeparationDepthMultiplier": 1, "SpeedMultiplier": 1, "Sloppyness": 0 });
| 139| 139| 	var controllerAI = ConstructComponent(controller, "UnitAI", { "FormationController": "true", "DefaultStance": "aggressive" });
| 140| 140| 
| 141| 141| 	AddMock(controller, IID_Position, {
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'JumpTo' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 139| 139| 	var controllerAI = ConstructComponent(controller, "UnitAI", { "FormationController": "true", "DefaultStance": "aggressive" });
| 140| 140| 
| 141| 141| 	AddMock(controller, IID_Position, {
| 142|    |-		JumpTo: function(x, z) { this.x = x; this.z = z; },
|    | 142|+		"JumpTo": function(x, z) { this.x = x; this.z = z; },
| 143| 143| 		GetTurretParent: function() { return INVALID_ENTITY; },
| 144| 144| 		GetPosition: function() { return new Vector3D(this.x, 0, this.z); },
| 145| 145| 		GetPosition2D: function() { return new Vector2D(this.x, this.z); },
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'GetTurretParent' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 140| 140| 
| 141| 141| 	AddMock(controller, IID_Position, {
| 142| 142| 		JumpTo: function(x, z) { this.x = x; this.z = z; },
| 143|    |-		GetTurretParent: function() { return INVALID_ENTITY; },
|    | 143|+		"GetTurretParent": function() { return INVALID_ENTITY; },
| 144| 144| 		GetPosition: function() { return new Vector3D(this.x, 0, this.z); },
| 145| 145| 		GetPosition2D: function() { return new Vector2D(this.x, this.z); },
| 146| 146| 		GetRotation: function() { return { "y": 0 }; },
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'GetPosition' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 141| 141| 	AddMock(controller, IID_Position, {
| 142| 142| 		JumpTo: function(x, z) { this.x = x; this.z = z; },
| 143| 143| 		GetTurretParent: function() { return INVALID_ENTITY; },
| 144|    |-		GetPosition: function() { return new Vector3D(this.x, 0, this.z); },
|    | 144|+		"GetPosition": function() { return new Vector3D(this.x, 0, this.z); },
| 145| 145| 		GetPosition2D: function() { return new Vector2D(this.x, this.z); },
| 146| 146| 		GetRotation: function() { return { "y": 0 }; },
| 147| 147| 		IsInWorld: function() { return true; },
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'GetPosition2D' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 142| 142| 		JumpTo: function(x, z) { this.x = x; this.z = z; },
| 143| 143| 		GetTurretParent: function() { return INVALID_ENTITY; },
| 144| 144| 		GetPosition: function() { return new Vector3D(this.x, 0, this.z); },
| 145|    |-		GetPosition2D: function() { return new Vector2D(this.x, this.z); },
|    | 145|+		"GetPosition2D": function() { return new Vector2D(this.x, this.z); },
| 146| 146| 		GetRotation: function() { return { "y": 0 }; },
| 147| 147| 		IsInWorld: function() { return true; },
| 148| 148| 	});
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'GetRotation' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 143| 143| 		GetTurretParent: function() { return INVALID_ENTITY; },
| 144| 144| 		GetPosition: function() { return new Vector3D(this.x, 0, this.z); },
| 145| 145| 		GetPosition2D: function() { return new Vector2D(this.x, this.z); },
| 146|    |-		GetRotation: function() { return { "y": 0 }; },
|    | 146|+		"GetRotation": function() { return { "y": 0 }; },
| 147| 147| 		IsInWorld: function() { return true; },
| 148| 148| 	});
| 149| 149| 
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'IsInWorld' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 144| 144| 		GetPosition: function() { return new Vector3D(this.x, 0, this.z); },
| 145| 145| 		GetPosition2D: function() { return new Vector2D(this.x, this.z); },
| 146| 146| 		GetRotation: function() { return { "y": 0 }; },
| 147|    |-		IsInWorld: function() { return true; },
|    | 147|+		"IsInWorld": function() { return true; },
| 148| 148| 	});
| 149| 149| 
| 150| 150| 	AddMock(controller, IID_UnitMotion, {
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'SetInterval' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 194| 194| 	var unitAIs = [];
| 195| 195| 
| 196| 196| 	AddMock(SYSTEM_ENTITY, IID_Timer, {
| 197|    |-		SetInterval: function() { },
|    | 197|+		"SetInterval": function() { },
| 198| 198| 		SetTimeout: function() { },
| 199| 199| 	});
| 200| 200| 
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'SetTimeout' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 195| 195| 
| 196| 196| 	AddMock(SYSTEM_ENTITY, IID_Timer, {
| 197| 197| 		SetInterval: function() { },
| 198|    |-		SetTimeout: function() { },
|    | 198|+		"SetTimeout": function() { },
| 199| 199| 	});
| 200| 200| 
| 201| 201| 
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'CreateActiveQuery' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 200| 200| 
| 201| 201| 
| 202| 202| 	AddMock(SYSTEM_ENTITY, IID_RangeManager, {
| 203|    |-		CreateActiveQuery: function(ent, minRange, maxRange, players, iid, flags) {
|    | 203|+		"CreateActiveQuery": function(ent, minRange, maxRange, players, iid, flags) {
| 204| 204| 			return 1;
| 205| 205| 		},
| 206| 206| 		EnableActiveQuery: function(id) { },
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'EnableActiveQuery' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 203| 203| 		CreateActiveQuery: function(ent, minRange, maxRange, players, iid, flags) {
| 204| 204| 			return 1;
| 205| 205| 		},
| 206|    |-		EnableActiveQuery: function(id) { },
|    | 206|+		"EnableActiveQuery": function(id) { },
| 207| 207| 		ResetActiveQuery: function(id) { return [enemy]; },
| 208| 208| 		DisableActiveQuery: function(id) { },
| 209| 209| 		GetEntityFlagMask: function(identifier) { },
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'ResetActiveQuery' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 204| 204| 			return 1;
| 205| 205| 		},
| 206| 206| 		EnableActiveQuery: function(id) { },
| 207|    |-		ResetActiveQuery: function(id) { return [enemy]; },
|    | 207|+		"ResetActiveQuery": function(id) { return [enemy]; },
| 208| 208| 		DisableActiveQuery: function(id) { },
| 209| 209| 		GetEntityFlagMask: function(identifier) { },
| 210| 210| 	});
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'DisableActiveQuery' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 205| 205| 		},
| 206| 206| 		EnableActiveQuery: function(id) { },
| 207| 207| 		ResetActiveQuery: function(id) { return [enemy]; },
| 208|    |-		DisableActiveQuery: function(id) { },
|    | 208|+		"DisableActiveQuery": function(id) { },
| 209| 209| 		GetEntityFlagMask: function(identifier) { },
| 210| 210| 	});
| 211| 211| 
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'GetEntityFlagMask' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 206| 206| 		EnableActiveQuery: function(id) { },
| 207| 207| 		ResetActiveQuery: function(id) { return [enemy]; },
| 208| 208| 		DisableActiveQuery: function(id) { },
| 209|    |-		GetEntityFlagMask: function(identifier) { },
|    | 209|+		"GetEntityFlagMask": function(identifier) { },
| 210| 210| 	});
| 211| 211| 
| 212| 212| 	AddMock(SYSTEM_ENTITY, IID_TemplateManager, {
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'GetCurrentTemplateName' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 210| 210| 	});
| 211| 211| 
| 212| 212| 	AddMock(SYSTEM_ENTITY, IID_TemplateManager, {
| 213|    |-		GetCurrentTemplateName: function(ent) { return "special/formations/line_closed"; },
|    | 213|+		"GetCurrentTemplateName": function(ent) { return "special/formations/line_closed"; },
| 214| 214| 	});
| 215| 215| 
| 216| 216| 	AddMock(SYSTEM_ENTITY, IID_PlayerManager, {
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'GetPlayerByID' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 214| 214| 	});
| 215| 215| 
| 216| 216| 	AddMock(SYSTEM_ENTITY, IID_PlayerManager, {
| 217|    |-		GetPlayerByID: function(id) { return playerEntity; },
|    | 217|+		"GetPlayerByID": function(id) { return playerEntity; },
| 218| 218| 		GetNumPlayers: function() { return 2; },
| 219| 219| 	});
| 220| 220| 
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'GetNumPlayers' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 215| 215| 
| 216| 216| 	AddMock(SYSTEM_ENTITY, IID_PlayerManager, {
| 217| 217| 		GetPlayerByID: function(id) { return playerEntity; },
| 218|    |-		GetNumPlayers: function() { return 2; },
|    | 218|+		"GetNumPlayers": function() { return 2; },
| 219| 219| 	});
| 220| 220| 
| 221| 221| 	AddMock(SYSTEM_ENTITY, IID_ObstructionManager, {
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'IsAlly' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 223| 223| 	});
| 224| 224| 
| 225| 225| 	AddMock(playerEntity, IID_Player, {
| 226|    |-		IsAlly: function() { return false; },
|    | 226|+		"IsAlly": function() { return false; },
| 227| 227| 		IsEnemy: function() { return true; },
| 228| 228| 		GetEnemies: function() { return []; },
| 229| 229| 	});
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'IsEnemy' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 224| 224| 
| 225| 225| 	AddMock(playerEntity, IID_Player, {
| 226| 226| 		IsAlly: function() { return false; },
| 227|    |-		IsEnemy: function() { return true; },
|    | 227|+		"IsEnemy": function() { return true; },
| 228| 228| 		GetEnemies: function() { return []; },
| 229| 229| 	});
| 230| 230| 
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'GetEnemies' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 225| 225| 	AddMock(playerEntity, IID_Player, {
| 226| 226| 		IsAlly: function() { return false; },
| 227| 227| 		IsEnemy: function() { return true; },
| 228|    |-		GetEnemies: function() { return []; },
|    | 228|+		"GetEnemies": function() { return []; },
| 229| 229| 	});
| 230| 230| 
| 231| 231| 	// create units
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'GetClassesList' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 236| 236| 		var unitAI = ConstructComponent(unit + i, "UnitAI", { "FormationController": "false", "DefaultStance": "aggressive" });
| 237| 237| 
| 238| 238| 		AddMock(unit + i, IID_Identity, {
| 239|    |-			GetClassesList: function() { return []; },
|    | 239|+			"GetClassesList": function() { return []; },
| 240| 240| 		});
| 241| 241| 
| 242| 242| 		AddMock(unit + i, IID_Ownership, {
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'GetOwner' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 240| 240| 		});
| 241| 241| 
| 242| 242| 		AddMock(unit + i, IID_Ownership, {
| 243|    |-			GetOwner: function() { return 1; },
|    | 243|+			"GetOwner": function() { return 1; },
| 244| 244| 		});
| 245| 245| 
| 246| 246| 		AddMock(unit + i, IID_Position, {
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'GetTurretParent' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 244| 244| 		});
| 245| 245| 
| 246| 246| 		AddMock(unit + i, IID_Position, {
| 247|    |-			GetTurretParent: function() { return INVALID_ENTITY; },
|    | 247|+			"GetTurretParent": function() { return INVALID_ENTITY; },
| 248| 248| 			GetPosition: function() { return new Vector3D(); },
| 249| 249| 			GetPosition2D: function() { return new Vector2D(); },
| 250| 250| 			GetRotation: function() { return { "y": 0 }; },
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'GetPosition' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 245| 245| 
| 246| 246| 		AddMock(unit + i, IID_Position, {
| 247| 247| 			GetTurretParent: function() { return INVALID_ENTITY; },
| 248|    |-			GetPosition: function() { return new Vector3D(); },
|    | 248|+			"GetPosition": function() { return new Vector3D(); },
| 249| 249| 			GetPosition2D: function() { return new Vector2D(); },
| 250| 250| 			GetRotation: function() { return { "y": 0 }; },
| 251| 251| 			IsInWorld: function() { return true; },
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'GetPosition2D' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 246| 246| 		AddMock(unit + i, IID_Position, {
| 247| 247| 			GetTurretParent: function() { return INVALID_ENTITY; },
| 248| 248| 			GetPosition: function() { return new Vector3D(); },
| 249|    |-			GetPosition2D: function() { return new Vector2D(); },
|    | 249|+			"GetPosition2D": function() { return new Vector2D(); },
| 250| 250| 			GetRotation: function() { return { "y": 0 }; },
| 251| 251| 			IsInWorld: function() { return true; },
| 252| 252| 		});
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'GetRotation' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 247| 247| 			GetTurretParent: function() { return INVALID_ENTITY; },
| 248| 248| 			GetPosition: function() { return new Vector3D(); },
| 249| 249| 			GetPosition2D: function() { return new Vector2D(); },
| 250|    |-			GetRotation: function() { return { "y": 0 }; },
|    | 250|+			"GetRotation": function() { return { "y": 0 }; },
| 251| 251| 			IsInWorld: function() { return true; },
| 252| 252| 		});
| 253| 253| 
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'IsInWorld' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 248| 248| 			GetPosition: function() { return new Vector3D(); },
| 249| 249| 			GetPosition2D: function() { return new Vector2D(); },
| 250| 250| 			GetRotation: function() { return { "y": 0 }; },
| 251|    |-			IsInWorld: function() { return true; },
|    | 251|+			"IsInWorld": function() { return true; },
| 252| 252| 		});
| 253| 253| 
| 254| 254| 		AddMock(unit + i, IID_UnitMotion, {
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'GetRange' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 261| 261| 		});
| 262| 262| 
| 263| 263| 		AddMock(unit + i, IID_Vision, {
| 264|    |-			GetRange: function() { return 10; },
|    | 264|+			"GetRange": function() { return 10; },
| 265| 265| 		});
| 266| 266| 
| 267| 267| 		AddMock(unit + i, IID_Attack, {
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'GetRange' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 265| 265| 		});
| 266| 266| 
| 267| 267| 		AddMock(unit + i, IID_Attack, {
| 268|    |-			GetRange: function() { return { "max":10, "min": 0, "elevationBonus": 0 }; },
|    | 268|+			"GetRange": function() { return { "max":10, "min": 0, "elevationBonus": 0 }; },
| 269| 269| 			GetFullAttackRange: function() { return { "max": 40, "min": 0 }; },
| 270| 270| 			GetBestAttackAgainst: function(t) { return "melee"; },
| 271| 271| 			GetTimers: function() { return { "prepare": 500, "repeat": 1000 }; },
|    | [NORMAL] ESLintBear (key-spacing):
|    | Missing space before value for key 'max'.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 265| 265| 		});
| 266| 266| 
| 267| 267| 		AddMock(unit + i, IID_Attack, {
| 268|    |-			GetRange: function() { return { "max":10, "min": 0, "elevationBonus": 0 }; },
|    | 268|+			GetRange: function() { return { "max": 10, "min": 0, "elevationBonus": 0 }; },
| 269| 269| 			GetFullAttackRange: function() { return { "max": 40, "min": 0 }; },
| 270| 270| 			GetBestAttackAgainst: function(t) { return "melee"; },
| 271| 271| 			GetTimers: function() { return { "prepare": 500, "repeat": 1000 }; },
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'GetFullAttackRange' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 266| 266| 
| 267| 267| 		AddMock(unit + i, IID_Attack, {
| 268| 268| 			GetRange: function() { return { "max":10, "min": 0, "elevationBonus": 0 }; },
| 269|    |-			GetFullAttackRange: function() { return { "max": 40, "min": 0 }; },
|    | 269|+			"GetFullAttackRange": function() { return { "max": 40, "min": 0 }; },
| 270| 270| 			GetBestAttackAgainst: function(t) { return "melee"; },
| 271| 271| 			GetTimers: function() { return { "prepare": 500, "repeat": 1000 }; },
| 272| 272| 			CanAttack: function(v) { return true; },
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'GetBestAttackAgainst' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 267| 267| 		AddMock(unit + i, IID_Attack, {
| 268| 268| 			GetRange: function() { return { "max":10, "min": 0, "elevationBonus": 0 }; },
| 269| 269| 			GetFullAttackRange: function() { return { "max": 40, "min": 0 }; },
| 270|    |-			GetBestAttackAgainst: function(t) { return "melee"; },
|    | 270|+			"GetBestAttackAgainst": function(t) { return "melee"; },
| 271| 271| 			GetTimers: function() { return { "prepare": 500, "repeat": 1000 }; },
| 272| 272| 			CanAttack: function(v) { return true; },
| 273| 273| 			CompareEntitiesByPreference: function(a, b) { return 0; },
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'GetTimers' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 268| 268| 			GetRange: function() { return { "max":10, "min": 0, "elevationBonus": 0 }; },
| 269| 269| 			GetFullAttackRange: function() { return { "max": 40, "min": 0 }; },
| 270| 270| 			GetBestAttackAgainst: function(t) { return "melee"; },
| 271|    |-			GetTimers: function() { return { "prepare": 500, "repeat": 1000 }; },
|    | 271|+			"GetTimers": function() { return { "prepare": 500, "repeat": 1000 }; },
| 272| 272| 			CanAttack: function(v) { return true; },
| 273| 273| 			CompareEntitiesByPreference: function(a, b) { return 0; },
| 274| 274| 		});
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'CanAttack' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 269| 269| 			GetFullAttackRange: function() { return { "max": 40, "min": 0 }; },
| 270| 270| 			GetBestAttackAgainst: function(t) { return "melee"; },
| 271| 271| 			GetTimers: function() { return { "prepare": 500, "repeat": 1000 }; },
| 272|    |-			CanAttack: function(v) { return true; },
|    | 272|+			"CanAttack": function(v) { return true; },
| 273| 273| 			CompareEntitiesByPreference: function(a, b) { return 0; },
| 274| 274| 		});
| 275| 275| 
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'CompareEntitiesByPreference' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 270| 270| 			GetBestAttackAgainst: function(t) { return "melee"; },
| 271| 271| 			GetTimers: function() { return { "prepare": 500, "repeat": 1000 }; },
| 272| 272| 			CanAttack: function(v) { return true; },
| 273|    |-			CompareEntitiesByPreference: function(a, b) { return 0; },
|    | 273|+			"CompareEntitiesByPreference": function(a, b) { return 0; },
| 274| 274| 		});
| 275| 275| 
| 276| 276| 		unitAI.OnCreate();
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'GetHitpoints' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 282| 282| 
| 283| 283| 	// Create enemy.
| 284| 284| 	AddMock(enemy, IID_Health, {
| 285|    |-		GetHitpoints: function() { return 40; },
|    | 285|+		"GetHitpoints": function() { return 40; },
| 286| 286| 	});
| 287| 287| 
| 288| 288| 	AddMock(enemy, IID_Position, {
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'GetTurretParent' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 286| 286| 	});
| 287| 287| 
| 288| 288| 	AddMock(enemy, IID_Position, {
| 289|    |-		GetTurretParent: function() { return INVALID_ENTITY; },
|    | 289|+		"GetTurretParent": function() { return INVALID_ENTITY; },
| 290| 290| 		GetPosition: function() { return new Vector3D(); },
| 291| 291| 		GetPosition2D: function() { return new Vector2D(); },
| 292| 292| 		IsInWorld: function() { return true; },
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'GetPosition' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 287| 287| 
| 288| 288| 	AddMock(enemy, IID_Position, {
| 289| 289| 		GetTurretParent: function() { return INVALID_ENTITY; },
| 290|    |-		GetPosition: function() { return new Vector3D(); },
|    | 290|+		"GetPosition": function() { return new Vector3D(); },
| 291| 291| 		GetPosition2D: function() { return new Vector2D(); },
| 292| 292| 		IsInWorld: function() { return true; },
| 293| 293| 	});
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'GetPosition2D' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 288| 288| 	AddMock(enemy, IID_Position, {
| 289| 289| 		GetTurretParent: function() { return INVALID_ENTITY; },
| 290| 290| 		GetPosition: function() { return new Vector3D(); },
| 291|    |-		GetPosition2D: function() { return new Vector2D(); },
|    | 291|+		"GetPosition2D": function() { return new Vector2D(); },
| 292| 292| 		IsInWorld: function() { return true; },
| 293| 293| 	});
| 294| 294| 
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'IsInWorld' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 289| 289| 		GetTurretParent: function() { return INVALID_ENTITY; },
| 290| 290| 		GetPosition: function() { return new Vector3D(); },
| 291| 291| 		GetPosition2D: function() { return new Vector2D(); },
| 292|    |-		IsInWorld: function() { return true; },
|    | 292|+		"IsInWorld": function() { return true; },
| 293| 293| 	});
| 294| 294| 
| 295| 295| 	var controllerFormation = ConstructComponent(controller, "Formation", {"FormationName": "Line Closed", "FormationShape": "square", "ShiftRows": "false", "SortingClasses": "", "WidthDepthRatio": 1, "UnitSeparationWidthMultiplier": 1, "UnitSeparationDepthMultiplier": 1, "SpeedMultiplier": 1, "Sloppyness": 0});
|    | [NORMAL] ESLintBear (object-curly-spacing):
|    | A space is required after '{'.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 292| 292| 		IsInWorld: function() { return true; },
| 293| 293| 	});
| 294| 294| 
| 295|    |-	var controllerFormation = ConstructComponent(controller, "Formation", {"FormationName": "Line Closed", "FormationShape": "square", "ShiftRows": "false", "SortingClasses": "", "WidthDepthRatio": 1, "UnitSeparationWidthMultiplier": 1, "UnitSeparationDepthMultiplier": 1, "SpeedMultiplier": 1, "Sloppyness": 0});
|    | 295|+	var controllerFormation = ConstructComponent(controller, "Formation", { "FormationName": "Line Closed", "FormationShape": "square", "ShiftRows": "false", "SortingClasses": "", "WidthDepthRatio": 1, "UnitSeparationWidthMultiplier": 1, "UnitSeparationDepthMultiplier": 1, "SpeedMultiplier": 1, "Sloppyness": 0});
| 296| 296| 	var controllerAI = ConstructComponent(controller, "UnitAI", { "FormationController": "true", "DefaultStance": "aggressive" });
| 297| 297| 
| 298| 298| 	AddMock(controller, IID_Position, {
|    | [NORMAL] ESLintBear (object-curly-spacing):
|    | A space is required before '}'.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 292| 292| 		IsInWorld: function() { return true; },
| 293| 293| 	});
| 294| 294| 
| 295|    |-	var controllerFormation = ConstructComponent(controller, "Formation", {"FormationName": "Line Closed", "FormationShape": "square", "ShiftRows": "false", "SortingClasses": "", "WidthDepthRatio": 1, "UnitSeparationWidthMultiplier": 1, "UnitSeparationDepthMultiplier": 1, "SpeedMultiplier": 1, "Sloppyness": 0});
|    | 295|+	var controllerFormation = ConstructComponent(controller, "Formation", {"FormationName": "Line Closed", "FormationShape": "square", "ShiftRows": "false", "SortingClasses": "", "WidthDepthRatio": 1, "UnitSeparationWidthMultiplier": 1, "UnitSeparationDepthMultiplier": 1, "SpeedMultiplier": 1, "Sloppyness": 0 });
| 296| 296| 	var controllerAI = ConstructComponent(controller, "UnitAI", { "FormationController": "true", "DefaultStance": "aggressive" });
| 297| 297| 
| 298| 298| 	AddMock(controller, IID_Position, {
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'GetTurretParent' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 296| 296| 	var controllerAI = ConstructComponent(controller, "UnitAI", { "FormationController": "true", "DefaultStance": "aggressive" });
| 297| 297| 
| 298| 298| 	AddMock(controller, IID_Position, {
| 299|    |-		GetTurretParent: function() { return INVALID_ENTITY; },
|    | 299|+		"GetTurretParent": function() { return INVALID_ENTITY; },
| 300| 300| 		JumpTo: function(x, z) { this.x = x; this.z = z; },
| 301| 301| 		GetPosition: function() { return new Vector3D(this.x, 0, this.z); },
| 302| 302| 		GetPosition2D: function() { return new Vector2D(this.x, this.z); },
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'JumpTo' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 297| 297| 
| 298| 298| 	AddMock(controller, IID_Position, {
| 299| 299| 		GetTurretParent: function() { return INVALID_ENTITY; },
| 300|    |-		JumpTo: function(x, z) { this.x = x; this.z = z; },
|    | 300|+		"JumpTo": function(x, z) { this.x = x; this.z = z; },
| 301| 301| 		GetPosition: function() { return new Vector3D(this.x, 0, this.z); },
| 302| 302| 		GetPosition2D: function() { return new Vector2D(this.x, this.z); },
| 303| 303| 		GetRotation: function() { return { "y": 0 }; },
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'GetPosition' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 298| 298| 	AddMock(controller, IID_Position, {
| 299| 299| 		GetTurretParent: function() { return INVALID_ENTITY; },
| 300| 300| 		JumpTo: function(x, z) { this.x = x; this.z = z; },
| 301|    |-		GetPosition: function() { return new Vector3D(this.x, 0, this.z); },
|    | 301|+		"GetPosition": function() { return new Vector3D(this.x, 0, this.z); },
| 302| 302| 		GetPosition2D: function() { return new Vector2D(this.x, this.z); },
| 303| 303| 		GetRotation: function() { return { "y": 0 }; },
| 304| 304| 		IsInWorld: function() { return true; },
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'GetPosition2D' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 299| 299| 		GetTurretParent: function() { return INVALID_ENTITY; },
| 300| 300| 		JumpTo: function(x, z) { this.x = x; this.z = z; },
| 301| 301| 		GetPosition: function() { return new Vector3D(this.x, 0, this.z); },
| 302|    |-		GetPosition2D: function() { return new Vector2D(this.x, this.z); },
|    | 302|+		"GetPosition2D": function() { return new Vector2D(this.x, this.z); },
| 303| 303| 		GetRotation: function() { return { "y": 0 }; },
| 304| 304| 		IsInWorld: function() { return true; },
| 305| 305| 	});
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'GetRotation' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 300| 300| 		JumpTo: function(x, z) { this.x = x; this.z = z; },
| 301| 301| 		GetPosition: function() { return new Vector3D(this.x, 0, this.z); },
| 302| 302| 		GetPosition2D: function() { return new Vector2D(this.x, this.z); },
| 303|    |-		GetRotation: function() { return { "y": 0 }; },
|    | 303|+		"GetRotation": function() { return { "y": 0 }; },
| 304| 304| 		IsInWorld: function() { return true; },
| 305| 305| 	});
| 306| 306| 
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'IsInWorld' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 301| 301| 		GetPosition: function() { return new Vector3D(this.x, 0, this.z); },
| 302| 302| 		GetPosition2D: function() { return new Vector2D(this.x, this.z); },
| 303| 303| 		GetRotation: function() { return { "y": 0 }; },
| 304|    |-		IsInWorld: function() { return true; },
|    | 304|+		"IsInWorld": function() { return true; },
| 305| 305| 	});
| 306| 306| 
| 307| 307| 	AddMock(controller, IID_UnitMotion, {
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'GetRange' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 314| 314| 	});
| 315| 315| 
| 316| 316| 	AddMock(controller, IID_Attack, {
| 317|    |-		GetRange: function() { return { "max":10, "min": 0, "elevationBonus": 0 }; },
|    | 317|+		"GetRange": function() { return { "max":10, "min": 0, "elevationBonus": 0 }; },
| 318| 318| 		CanAttackAsFormation: function() { return false; },
| 319| 319| 	});
| 320| 320| 
|    | [NORMAL] ESLintBear (key-spacing):
|    | Missing space before value for key 'max'.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 314| 314| 	});
| 315| 315| 
| 316| 316| 	AddMock(controller, IID_Attack, {
| 317|    |-		GetRange: function() { return { "max":10, "min": 0, "elevationBonus": 0 }; },
|    | 317|+		GetRange: function() { return { "max": 10, "min": 0, "elevationBonus": 0 }; },
| 318| 318| 		CanAttackAsFormation: function() { return false; },
| 319| 319| 	});
| 320| 320| 
|    | [NORMAL] ESLintBear (quote-props):
|    | Unquoted property 'CanAttackAsFormation' found.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 315| 315| 
| 316| 316| 	AddMock(controller, IID_Attack, {
| 317| 317| 		GetRange: function() { return { "max":10, "min": 0, "elevationBonus": 0 }; },
| 318|    |-		CanAttackAsFormation: function() { return false; },
|    | 318|+		"CanAttackAsFormation": function() { return false; },
| 319| 319| 	});
| 320| 320| 
| 321| 321| 	controllerAI.OnCreate();
|    | [NORMAL] ESLintBear (object-curly-spacing):
|    | A space is required after '{'.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 327| 327| 	for (var ent of unitAIs)
| 328| 328| 		TS_ASSERT_EQUALS(unitAI.fsmStateName, "INDIVIDUAL.COMBAT.ATTACKING");
| 329| 329| 
| 330|    |-	controllerAI.MoveIntoFormation({"name": "Circle"});
|    | 330|+	controllerAI.MoveIntoFormation({ "name": "Circle"});
| 331| 331| 
| 332| 332| 	// let all units be in position
| 333| 333| 	for (var ent of unitAIs)
|    | [NORMAL] ESLintBear (object-curly-spacing):
|    | A space is required before '}'.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 327| 327| 	for (var ent of unitAIs)
| 328| 328| 		TS_ASSERT_EQUALS(unitAI.fsmStateName, "INDIVIDUAL.COMBAT.ATTACKING");
| 329| 329| 
| 330|    |-	controllerAI.MoveIntoFormation({"name": "Circle"});
|    | 330|+	controllerAI.MoveIntoFormation({"name": "Circle" });
| 331| 331| 
| 332| 332| 	// let all units be in position
| 333| 333| 	for (var ent of unitAIs)

binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
|  47| »   »   ResetActiveQuery:·function(id)·{·if·(mode·==·0)·return·[];·else·return·[enemy];·},
|    | [NORMAL] ESLintBear (brace-rules/brace-on-same-line):
|    | Closing curly brace appears on the same line as the subsequent block.

binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 232| »   for·(var·i·=·0;·i·<·unitCount;·i++)·{
|    | [NORMAL] ESLintBear (brace-rules/brace-on-same-line):
|    | Opening curly brace appears on the same line as controlling statement.

binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 333| »   for·(var·ent·of·unitAIs)
|    | [NORMAL] JSHintBear:
|    | 'ent' is already defined.

binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 336| »   for·(var·ent·of·unitAIs)
|    | [NORMAL] JSHintBear:
|    | 'ent' is already defined.

binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 328| »   »   TS_ASSERT_EQUALS(unitAI.fsmStateName,·"INDIVIDUAL.COMBAT.ATTACKING");
|    | [NORMAL] JSHintBear:
|    | 'unitAI' used out of scope.

binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
| 337| »   »   TS_ASSERT_EQUALS(unitAI.fsmStateName,·"INDIVIDUAL.COMBAT.ATTACKING");
|    | [NORMAL] JSHintBear:
|    | 'unitAI' used out of scope.
|    | [NORMAL] ESLintBear (no-else-return):
|    | Unnecessary 'else' after 'return'.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
| 767| 767| 					this.FinishOrder();
| 768| 768| 					return;
| 769| 769| 				}
| 770|    |-				else
| 771|    |-				{
|    | 770|+				
| 772| 771| 					this.SetNextState("GARRISON.APPROACHING");
| 773| 772| 					return;
| 774|    |-				}
|    | 773|+				
| 775| 774| 			}
| 776| 775| 
| 777| 776| 			this.SetNextState("GARRISON.GARRISONING");
|    | [NORMAL] ESLintBear (key-spacing):
|    | Missing space before value for key 'GARRISON'.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|1035|1035| 			},
|1036|1036| 		},
|1037|1037| 
|1038|    |-		"GARRISON":{
|    |1038|+		"GARRISON": {
|1039|1039| 			"APPROACHING": {
|1040|1040| 				"enter": function() {
|1041|1041| 					if (!this.MoveToGarrisonRange(this.order.data.target))
|    | [NORMAL] ESLintBear (operator-linebreak):
|    | '&&' should be placed at the end of the line.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|2000|2000| 
|2001|2001| 				"Attacked": function(msg) {
|2002|2002| 					// If we are capturing and are attacked by something that we would not capture, attack that entity instead
|2003|    |-					if (this.order.data.attackType == "Capture" && (this.GetStance().targetAttackersAlways || !this.order.data.force)
|2004|    |-						&& this.order.data.target != msg.data.attacker && this.GetBestAttackAgainst(msg.data.attacker, true) != "Capture")
|    |2003|+					if (this.order.data.attackType == "Capture" && (this.GetStance().targetAttackersAlways || !this.order.data.force) &&
|    |2004|+						this.order.data.target != msg.data.attacker && this.GetBestAttackAgainst(msg.data.attacker, true) != "Capture")
|2005|2005| 						this.RespondToTargetedEntities([msg.data.attacker]);
|2006|2006| 				},
|2007|2007| 			},
|    | [NORMAL] ESLintBear (object-curly-spacing):
|    | A space is required after '{'.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|2728|2728| 					{
|2729|2729| 						// The building was already finished/fully repaired before we arrived;
|2730|2730| 						// let the ConstructionFinished handler handle this.
|2731|    |-						this.OnGlobalConstructionFinished({"entity": this.repairTarget, "newentity": this.repairTarget});
|    |2731|+						this.OnGlobalConstructionFinished({ "entity": this.repairTarget, "newentity": this.repairTarget});
|2732|2732| 						return true;
|2733|2733| 					}
|2734|2734| 
|    | [NORMAL] ESLintBear (object-curly-spacing):
|    | A space is required before '}'.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|2728|2728| 					{
|2729|2729| 						// The building was already finished/fully repaired before we arrived;
|2730|2730| 						// let the ConstructionFinished handler handle this.
|2731|    |-						this.OnGlobalConstructionFinished({"entity": this.repairTarget, "newentity": this.repairTarget});
|    |2731|+						this.OnGlobalConstructionFinished({"entity": this.repairTarget, "newentity": this.repairTarget });
|2732|2732| 						return true;
|2733|2733| 					}
|2734|2734| 
|    | [NORMAL] ESLintBear (indent):
|    | Expected indentation of 2 tabs but found 7.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|3242|3242| 		"COMBAT": "INDIVIDUAL.COMBAT", // reuse the same combat behaviour for animals
|3243|3243| 
|3244|3244| 		"WALKING": "INDIVIDUAL.WALKING",	// reuse the same walking behaviour for animals
|3245|    |-							// only used for domestic animals
|    |3245|+		// only used for domestic animals
|3246|3246| 	},
|3247|3247| };
|3248|3248| 
|    | [NORMAL] ESLintBear (no-unneeded-ternary):
|    | Unnecessary use of boolean literals in conditional expression.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|3299|3299| 
|3300|3300| UnitAI.prototype.IsAnimal = function()
|3301|3301| {
|3302|    |-	return (this.template.NaturalBehaviour ? true : false);
|    |3302|+	return (!!this.template.NaturalBehaviour);
|3303|3303| };
|3304|3304| 
|3305|3305| UnitAI.prototype.IsDangerousAnimal = function()
|    | [NORMAL] ESLintBear (comma-spacing):
|    | A space is required after ','.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|3415|3415| 		{
|3416|3416| 			let index = this.GetCurrentState().indexOf(".");
|3417|3417| 			if (index != -1)
|3418|    |-				this.UnitFsm.SwitchToNextState(this, this.GetCurrentState().slice(0,index));
|    |3418|+				this.UnitFsm.SwitchToNextState(this, this.GetCurrentState().slice(0, index));
|3419|3419| 			this.Stop(false);
|3420|3420| 		}
|3421|3421| 
|    | [NORMAL] ESLintBear (object-curly-spacing):
|    | A space is required after '{'.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|3471|3471| 		if (this.orderQueue[i].type != "PickupUnit" || this.orderQueue[i].data.target != msg.entity)
|3472|3472| 			continue;
|3473|3473| 		if (i == 0)
|3474|    |-			this.UnitFsm.ProcessMessage(this, {"type": "PickupCanceled", "data": msg});
|    |3474|+			this.UnitFsm.ProcessMessage(this, { "type": "PickupCanceled", "data": msg});
|3475|3475| 		else
|3476|3476| 			this.orderQueue.splice(i, 1);
|3477|3477| 		Engine.PostMessage(this.entity, MT_UnitAIOrderDataChanged, { "to": this.GetOrderData() });
|    | [NORMAL] ESLintBear (object-curly-spacing):
|    | A space is required before '}'.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|3471|3471| 		if (this.orderQueue[i].type != "PickupUnit" || this.orderQueue[i].data.target != msg.entity)
|3472|3472| 			continue;
|3473|3473| 		if (i == 0)
|3474|    |-			this.UnitFsm.ProcessMessage(this, {"type": "PickupCanceled", "data": msg});
|    |3474|+			this.UnitFsm.ProcessMessage(this, {"type": "PickupCanceled", "data": msg });
|3475|3475| 		else
|3476|3476| 			this.orderQueue.splice(i, 1);
|3477|3477| 		Engine.PostMessage(this.entity, MT_UnitAIOrderDataChanged, { "to": this.GetOrderData() });
|    | [NORMAL] ESLintBear (spaced-comment):
|    | Expected space or tab after '//' in comment.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|3555|3555| };
|3556|3556| 
|3557|3557| 
|3558|    |-//// FSM linkage functions ////
|    |3558|+// // FSM linkage functions ////
|3559|3559| 
|3560|3560| // Setting the next state to the current state will leave/re-enter the top-most substate.
|3561|3561| UnitAI.prototype.SetNextState = function(state)
|    | [NORMAL] ESLintBear (object-curly-spacing):
|    | A space is required after '{'.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|3725|3725| 				continue;
|3726|3726| 			if (this.orderQueue[i].type == type)
|3727|3727| 				continue;
|3728|    |-			this.orderQueue.splice(i, 0, {"type": type, "data": data});
|    |3728|+			this.orderQueue.splice(i, 0, { "type": type, "data": data});
|3729|3729| 			Engine.PostMessage(this.entity, MT_UnitAIOrderDataChanged, { "to": this.GetOrderData() });
|3730|3730| 			return;
|3731|3731| 		}
|    | [NORMAL] ESLintBear (object-curly-spacing):
|    | A space is required before '}'.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|3725|3725| 				continue;
|3726|3726| 			if (this.orderQueue[i].type == type)
|3727|3727| 				continue;
|3728|    |-			this.orderQueue.splice(i, 0, {"type": type, "data": data});
|    |3728|+			this.orderQueue.splice(i, 0, {"type": type, "data": data });
|3729|3729| 			Engine.PostMessage(this.entity, MT_UnitAIOrderDataChanged, { "to": this.GetOrderData() });
|3730|3730| 			return;
|3731|3731| 		}
|    | [NORMAL] ESLintBear (object-curly-spacing):
|    | A space is required after '{'.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|3896|3896| 	if (data.timerRepeat === undefined)
|3897|3897| 		this.timer = undefined;
|3898|3898| 
|3899|    |-	this.UnitFsm.ProcessMessage(this, {"type": "Timer", "data": data, "lateness": lateness});
|    |3899|+	this.UnitFsm.ProcessMessage(this, { "type": "Timer", "data": data, "lateness": lateness});
|3900|3900| };
|3901|3901| 
|3902|3902| /**
|    | [NORMAL] ESLintBear (object-curly-spacing):
|    | A space is required before '}'.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|3896|3896| 	if (data.timerRepeat === undefined)
|3897|3897| 		this.timer = undefined;
|3898|3898| 
|3899|    |-	this.UnitFsm.ProcessMessage(this, {"type": "Timer", "data": data, "lateness": lateness});
|    |3899|+	this.UnitFsm.ProcessMessage(this, {"type": "Timer", "data": data, "lateness": lateness });
|3900|3900| };
|3901|3901| 
|3902|3902| /**
|    | [NORMAL] ESLintBear (object-curly-spacing):
|    | A space is required after '{'.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|3941|3941| 	// TODO: This is a bit inefficient since every unit listens to every
|3942|3942| 	// construction message - ideally we could scope it to only the one we're building
|3943|3943| 
|3944|    |-	this.UnitFsm.ProcessMessage(this, {"type": "ConstructionFinished", "data": msg});
|    |3944|+	this.UnitFsm.ProcessMessage(this, { "type": "ConstructionFinished", "data": msg});
|3945|3945| };
|3946|3946| 
|3947|3947| UnitAI.prototype.OnGlobalEntityRenamed = function(msg)
|    | [NORMAL] ESLintBear (object-curly-spacing):
|    | A space is required before '}'.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|3941|3941| 	// TODO: This is a bit inefficient since every unit listens to every
|3942|3942| 	// construction message - ideally we could scope it to only the one we're building
|3943|3943| 
|3944|    |-	this.UnitFsm.ProcessMessage(this, {"type": "ConstructionFinished", "data": msg});
|    |3944|+	this.UnitFsm.ProcessMessage(this, {"type": "ConstructionFinished", "data": msg });
|3945|3945| };
|3946|3946| 
|3947|3947| UnitAI.prototype.OnGlobalEntityRenamed = function(msg)
|    | [NORMAL] ESLintBear (object-curly-spacing):
|    | A space is required after '{'.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|3966|3966| 
|3967|3967| UnitAI.prototype.OnAttacked = function(msg)
|3968|3968| {
|3969|    |-	this.UnitFsm.ProcessMessage(this, {"type": "Attacked", "data": msg});
|    |3969|+	this.UnitFsm.ProcessMessage(this, { "type": "Attacked", "data": msg});
|3970|3970| };
|3971|3971| 
|3972|3972| UnitAI.prototype.OnGuardedAttacked = function(msg)
|    | [NORMAL] ESLintBear (object-curly-spacing):
|    | A space is required before '}'.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|3966|3966| 
|3967|3967| UnitAI.prototype.OnAttacked = function(msg)
|3968|3968| {
|3969|    |-	this.UnitFsm.ProcessMessage(this, {"type": "Attacked", "data": msg});
|    |3969|+	this.UnitFsm.ProcessMessage(this, {"type": "Attacked", "data": msg });
|3970|3970| };
|3971|3971| 
|3972|3972| UnitAI.prototype.OnGuardedAttacked = function(msg)
|    | [NORMAL] ESLintBear (object-curly-spacing):
|    | A space is required after '{'.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|3971|3971| 
|3972|3972| UnitAI.prototype.OnGuardedAttacked = function(msg)
|3973|3973| {
|3974|    |-	this.UnitFsm.ProcessMessage(this, {"type": "GuardedAttacked", "data": msg.data});
|    |3974|+	this.UnitFsm.ProcessMessage(this, { "type": "GuardedAttacked", "data": msg.data});
|3975|3975| };
|3976|3976| 
|3977|3977| UnitAI.prototype.OnHealthChanged = function(msg)
|    | [NORMAL] ESLintBear (object-curly-spacing):
|    | A space is required before '}'.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|3971|3971| 
|3972|3972| UnitAI.prototype.OnGuardedAttacked = function(msg)
|3973|3973| {
|3974|    |-	this.UnitFsm.ProcessMessage(this, {"type": "GuardedAttacked", "data": msg.data});
|    |3974|+	this.UnitFsm.ProcessMessage(this, {"type": "GuardedAttacked", "data": msg.data });
|3975|3975| };
|3976|3976| 
|3977|3977| UnitAI.prototype.OnHealthChanged = function(msg)
|    | [NORMAL] ESLintBear (object-curly-spacing):
|    | A space is required after '{'.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|3976|3976| 
|3977|3977| UnitAI.prototype.OnHealthChanged = function(msg)
|3978|3978| {
|3979|    |-	this.UnitFsm.ProcessMessage(this, {"type": "HealthChanged", "from": msg.from, "to": msg.to});
|    |3979|+	this.UnitFsm.ProcessMessage(this, { "type": "HealthChanged", "from": msg.from, "to": msg.to});
|3980|3980| };
|3981|3981| 
|3982|3982| UnitAI.prototype.OnRangeUpdate = function(msg)
|    | [NORMAL] ESLintBear (object-curly-spacing):
|    | A space is required before '}'.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|3976|3976| 
|3977|3977| UnitAI.prototype.OnHealthChanged = function(msg)
|3978|3978| {
|3979|    |-	this.UnitFsm.ProcessMessage(this, {"type": "HealthChanged", "from": msg.from, "to": msg.to});
|    |3979|+	this.UnitFsm.ProcessMessage(this, {"type": "HealthChanged", "from": msg.from, "to": msg.to });
|3980|3980| };
|3981|3981| 
|3982|3982| UnitAI.prototype.OnRangeUpdate = function(msg)
|    | [NORMAL] ESLintBear (object-curly-spacing):
|    | A space is required after '{'.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|3982|3982| UnitAI.prototype.OnRangeUpdate = function(msg)
|3983|3983| {
|3984|3984| 	if (msg.tag == this.losRangeQuery)
|3985|    |-		this.UnitFsm.ProcessMessage(this, {"type": "LosRangeUpdate", "data": msg});
|    |3985|+		this.UnitFsm.ProcessMessage(this, { "type": "LosRangeUpdate", "data": msg});
|3986|3986| 	else if (msg.tag == this.losHealRangeQuery)
|3987|3987| 		this.UnitFsm.ProcessMessage(this, {"type": "LosHealRangeUpdate", "data": msg});
|3988|3988| };
|    | [NORMAL] ESLintBear (object-curly-spacing):
|    | A space is required before '}'.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|3982|3982| UnitAI.prototype.OnRangeUpdate = function(msg)
|3983|3983| {
|3984|3984| 	if (msg.tag == this.losRangeQuery)
|3985|    |-		this.UnitFsm.ProcessMessage(this, {"type": "LosRangeUpdate", "data": msg});
|    |3985|+		this.UnitFsm.ProcessMessage(this, {"type": "LosRangeUpdate", "data": msg });
|3986|3986| 	else if (msg.tag == this.losHealRangeQuery)
|3987|3987| 		this.UnitFsm.ProcessMessage(this, {"type": "LosHealRangeUpdate", "data": msg});
|3988|3988| };
|    | [NORMAL] ESLintBear (object-curly-spacing):
|    | A space is required after '{'.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|3984|3984| 	if (msg.tag == this.losRangeQuery)
|3985|3985| 		this.UnitFsm.ProcessMessage(this, {"type": "LosRangeUpdate", "data": msg});
|3986|3986| 	else if (msg.tag == this.losHealRangeQuery)
|3987|    |-		this.UnitFsm.ProcessMessage(this, {"type": "LosHealRangeUpdate", "data": msg});
|    |3987|+		this.UnitFsm.ProcessMessage(this, { "type": "LosHealRangeUpdate", "data": msg});
|3988|3988| };
|3989|3989| 
|3990|3990| UnitAI.prototype.OnPackFinished = function(msg)
|    | [NORMAL] ESLintBear (object-curly-spacing):
|    | A space is required before '}'.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|3984|3984| 	if (msg.tag == this.losRangeQuery)
|3985|3985| 		this.UnitFsm.ProcessMessage(this, {"type": "LosRangeUpdate", "data": msg});
|3986|3986| 	else if (msg.tag == this.losHealRangeQuery)
|3987|    |-		this.UnitFsm.ProcessMessage(this, {"type": "LosHealRangeUpdate", "data": msg});
|    |3987|+		this.UnitFsm.ProcessMessage(this, {"type": "LosHealRangeUpdate", "data": msg });
|3988|3988| };
|3989|3989| 
|3990|3990| UnitAI.prototype.OnPackFinished = function(msg)
|    | [NORMAL] ESLintBear (object-curly-spacing):
|    | A space is required after '{'.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|3989|3989| 
|3990|3990| UnitAI.prototype.OnPackFinished = function(msg)
|3991|3991| {
|3992|    |-	this.UnitFsm.ProcessMessage(this, {"type": "PackFinished", "packed": msg.packed});
|    |3992|+	this.UnitFsm.ProcessMessage(this, { "type": "PackFinished", "packed": msg.packed});
|3993|3993| };
|3994|3994| 
|3995|3995| //// Helper functions to be called by the FSM ////
|    | [NORMAL] ESLintBear (object-curly-spacing):
|    | A space is required before '}'.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|3989|3989| 
|3990|3990| UnitAI.prototype.OnPackFinished = function(msg)
|3991|3991| {
|3992|    |-	this.UnitFsm.ProcessMessage(this, {"type": "PackFinished", "packed": msg.packed});
|    |3992|+	this.UnitFsm.ProcessMessage(this, {"type": "PackFinished", "packed": msg.packed });
|3993|3993| };
|3994|3994| 
|3995|3995| //// Helper functions to be called by the FSM ////
|    | [NORMAL] ESLintBear (spaced-comment):
|    | Expected space or tab after '//' in comment.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|3992|3992| 	this.UnitFsm.ProcessMessage(this, {"type": "PackFinished", "packed": msg.packed});
|3993|3993| };
|3994|3994| 
|3995|    |-//// Helper functions to be called by the FSM ////
|    |3995|+// // Helper functions to be called by the FSM ////
|3996|3996| 
|3997|3997| UnitAI.prototype.GetWalkSpeed = function()
|3998|3998| {
|    | [NORMAL] ESLintBear (operator-linebreak):
|    | '&&' should be placed at the end of the line.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|4662|4662| UnitAI.prototype.AttackEntityInZone = function(ents)
|4663|4663| {
|4664|4664| 	var target = ents.find(target =>
|4665|    |-		this.CanAttack(target)
|4666|    |-		&& this.CheckTargetDistanceFromHeldPosition(target, IID_Attack, this.GetBestAttackAgainst(target, true))
|    |4665|+		this.CanAttack(target) &&
|    |4666|+		this.CheckTargetDistanceFromHeldPosition(target, IID_Attack, this.GetBestAttackAgainst(target, true))
|4667|4667| 		&& (this.GetStance().respondChaseBeyondVision || this.CheckTargetIsInVisionRange(target))
|4668|4668| 	);
|4669|4669| 	if (!target)
|    | [NORMAL] ESLintBear (operator-linebreak):
|    | '&&' should be placed at the end of the line.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|4663|4663| {
|4664|4664| 	var target = ents.find(target =>
|4665|4665| 		this.CanAttack(target)
|4666|    |-		&& this.CheckTargetDistanceFromHeldPosition(target, IID_Attack, this.GetBestAttackAgainst(target, true))
|4667|    |-		&& (this.GetStance().respondChaseBeyondVision || this.CheckTargetIsInVisionRange(target))
|    |4666|+		&& this.CheckTargetDistanceFromHeldPosition(target, IID_Attack, this.GetBestAttackAgainst(target, true)) &&
|    |4667|+		(this.GetStance().respondChaseBeyondVision || this.CheckTargetIsInVisionRange(target))
|4668|4668| 	);
|4669|4669| 	if (!target)
|4670|4670| 		return false;
|    | [NORMAL] ESLintBear (no-multi-spaces):
|    | Multiple spaces found before 'Engine'.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|4727|4727| 	// If we are guarding/escorting, don't abandon as long as the guarded unit is in target range of the attacker
|4728|4728| 	if (this.isGuardOf)
|4729|4729| 	{
|4730|    |-		var cmpUnitAI =  Engine.QueryInterface(target, IID_UnitAI);
|    |4730|+		var cmpUnitAI = Engine.QueryInterface(target, IID_UnitAI);
|4731|4731| 		var cmpAttack = Engine.QueryInterface(target, IID_Attack);
|4732|4732| 		if (cmpUnitAI && cmpAttack &&
|4733|4733| 		    cmpAttack.GetAttackTypes().some(type => cmpUnitAI.CheckTargetAttackRange(this.isGuardOf, type)))
|    | [NORMAL] ESLintBear (indent):
|    | Expected indentation of 3 tabs but found 4.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|4731|4731| 		var cmpAttack = Engine.QueryInterface(target, IID_Attack);
|4732|4732| 		if (cmpUnitAI && cmpAttack &&
|4733|4733| 		    cmpAttack.GetAttackTypes().some(type => cmpUnitAI.CheckTargetAttackRange(this.isGuardOf, type)))
|4734|    |-				return false;
|    |4734|+			return false;
|4735|4735| 	}
|4736|4736| 
|4737|4737| 	// Stop if we're in hold-ground mode and it's too far from the holding point
|    | [NORMAL] ESLintBear (no-multi-spaces):
|    | Multiple spaces found before 'Engine'.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|4769|4769| 	// If we are guarding/escorting, chase at least as long as the guarded unit is in target range of the attacker
|4770|4770| 	if (this.isGuardOf)
|4771|4771| 	{
|4772|    |-		let cmpUnitAI =  Engine.QueryInterface(target, IID_UnitAI);
|    |4772|+		let cmpUnitAI = Engine.QueryInterface(target, IID_UnitAI);
|4773|4773| 		let cmpAttack = Engine.QueryInterface(target, IID_Attack);
|4774|4774| 		if (cmpUnitAI && cmpAttack &&
|4775|4775| 		    cmpAttack.GetAttackTypes().some(type => cmpUnitAI.CheckTargetAttackRange(this.isGuardOf, type)))
|    | [NORMAL] ESLintBear (spaced-comment):
|    | Expected space or tab after '//' in comment.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|4782|4782| 	return false;
|4783|4783| };
|4784|4784| 
|4785|    |-//// External interface functions ////
|    |4785|+// // External interface functions ////
|4786|4786| 
|4787|4787| UnitAI.prototype.SetFormationController = function(ent)
|4788|4788| {
|    | [NORMAL] ESLintBear (no-else-return):
|    | Unnecessary 'else' after 'return'.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|4938|4938| 	{
|4939|4939| 		if (this.isGuardOf == target && this.order && this.order.type == "Guard")
|4940|4940| 			return;
|4941|    |-		else
|4942|    |-			this.RemoveGuard();
|    |4941|+		this.RemoveGuard();
|4943|4942| 	}
|4944|4943| 
|4945|4944| 	this.AddOrder("Guard", { "target": target, "force": false }, queued);
|    | [NORMAL] ESLintBear (no-trailing-spaces):
|    | Trailing spaces not allowed.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|5270|5270| 	    this.workOrders.length && this.workOrders[0].type == "Trade")
|5271|5271| 	{
|5272|5272| 		let cmpTrader = Engine.QueryInterface(this.entity, IID_Trader);
|5273|    |-		if (cmpTrader.HasBothMarkets() && 
|    |5273|+		if (cmpTrader.HasBothMarkets() &&
|5274|5274| 		   (cmpTrader.GetFirstMarket() == target && cmpTrader.GetSecondMarket() == source ||
|5275|5275| 		    cmpTrader.GetFirstMarket() == source && cmpTrader.GetSecondMarket() == target))
|5276|5276| 		{
|    | [NORMAL] ESLintBear (operator-linebreak):
|    | '&&' should be placed at the end of the line.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|5551|5551| 				{
|5552|5552| 					var cmpIdentity = Engine.QueryInterface(targ, IID_Identity);
|5553|5553| 					var targetClasses = this.order.data.targetClasses;
|5554|    |-					if (targetClasses.attack && cmpIdentity
|5555|    |-						&& !MatchesClassList(cmpIdentity.GetClassesList(), targetClasses.attack))
|    |5554|+					if (targetClasses.attack && cmpIdentity &&
|    |5555|+						!MatchesClassList(cmpIdentity.GetClassesList(), targetClasses.attack))
|5556|5556| 						continue;
|5557|5557| 					if (targetClasses.avoid && cmpIdentity
|5558|5558| 						&& MatchesClassList(cmpIdentity.GetClassesList(), targetClasses.avoid))
|    | [NORMAL] ESLintBear (operator-linebreak):
|    | '&&' should be placed at the end of the line.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|5554|5554| 					if (targetClasses.attack && cmpIdentity
|5555|5555| 						&& !MatchesClassList(cmpIdentity.GetClassesList(), targetClasses.attack))
|5556|5556| 						continue;
|5557|    |-					if (targetClasses.avoid && cmpIdentity
|5558|    |-						&& MatchesClassList(cmpIdentity.GetClassesList(), targetClasses.avoid))
|    |5557|+					if (targetClasses.avoid && cmpIdentity &&
|    |5558|+						MatchesClassList(cmpIdentity.GetClassesList(), targetClasses.avoid))
|5559|5559| 						continue;
|5560|5560| 					// Only used by the AIs to prevent some choices of targets
|5561|5561| 					if (targetClasses.vetoEntities && targetClasses.vetoEntities[targ])
|    | [NORMAL] ESLintBear (operator-linebreak):
|    | '&&' should be placed at the end of the line.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|5577|5577| 		{
|5578|5578| 			var cmpIdentity = Engine.QueryInterface(targ, IID_Identity);
|5579|5579| 			var targetClasses = this.order.data.targetClasses;
|5580|    |-			if (cmpIdentity && targetClasses.attack
|5581|    |-				&& !MatchesClassList(cmpIdentity.GetClassesList(), targetClasses.attack))
|    |5580|+			if (cmpIdentity && targetClasses.attack &&
|    |5581|+				!MatchesClassList(cmpIdentity.GetClassesList(), targetClasses.attack))
|5582|5582| 				continue;
|5583|5583| 			if (cmpIdentity && targetClasses.avoid
|5584|5584| 				&& MatchesClassList(cmpIdentity.GetClassesList(), targetClasses.avoid))
|    | [NORMAL] ESLintBear (operator-linebreak):
|    | '&&' should be placed at the end of the line.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|5580|5580| 			if (cmpIdentity && targetClasses.attack
|5581|5581| 				&& !MatchesClassList(cmpIdentity.GetClassesList(), targetClasses.attack))
|5582|5582| 				continue;
|5583|    |-			if (cmpIdentity && targetClasses.avoid
|5584|    |-				&& MatchesClassList(cmpIdentity.GetClassesList(), targetClasses.avoid))
|    |5583|+			if (cmpIdentity && targetClasses.avoid &&
|    |5584|+				MatchesClassList(cmpIdentity.GetClassesList(), targetClasses.avoid))
|5585|5585| 				continue;
|5586|5586| 			// Only used by the AIs to prevent some choices of targets
|5587|5587| 			if (targetClasses.vetoEntities && targetClasses.vetoEntities[targ])
|    | [NORMAL] ESLintBear (object-curly-spacing):
|    | A space is required after '{'.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|5737|5737| 
|5738|5738| UnitAI.prototype.SetHeldPosition = function(x, z)
|5739|5739| {
|5740|    |-	this.heldPosition = {"x": x, "z": z};
|    |5740|+	this.heldPosition = { "x": x, "z": z};
|5741|5741| };
|5742|5742| 
|5743|5743| UnitAI.prototype.SetHeldPositionOnEntity = function(entity)
|    | [NORMAL] ESLintBear (object-curly-spacing):
|    | A space is required before '}'.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|5737|5737| 
|5738|5738| UnitAI.prototype.SetHeldPosition = function(x, z)
|5739|5739| {
|5740|    |-	this.heldPosition = {"x": x, "z": z};
|    |5740|+	this.heldPosition = {"x": x, "z": z };
|5741|5741| };
|5742|5742| 
|5743|5743| UnitAI.prototype.SetHeldPositionOnEntity = function(entity)
|    | [NORMAL] ESLintBear (spaced-comment):
|    | Expected space or tab after '//' in comment.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|5764|5764| 	return false;
|5765|5765| };
|5766|5766| 
|5767|    |-//// Helper functions ////
|    |5767|+// // Helper functions ////
|5768|5768| 
|5769|5769| UnitAI.prototype.CanAttack = function(target)
|5770|5770| {
|    | [NORMAL] ESLintBear (spaced-comment):
|    | Expected space or tab after '//' in comment.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|5968|5968| 	return cmpPack && cmpPack.IsPacking();
|5969|5969| };
|5970|5970| 
|5971|    |-//// Formation specific functions ////
|    |5971|+// // Formation specific functions ////
|5972|5972| 
|5973|5973| UnitAI.prototype.IsAttackingAsFormation = function()
|5974|5974| {
|    | [NORMAL] ESLintBear (operator-linebreak):
|    | '&&' should be placed at the end of the line.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|5973|5973| UnitAI.prototype.IsAttackingAsFormation = function()
|5974|5974| {
|5975|5975| 	var cmpAttack = Engine.QueryInterface(this.entity, IID_Attack);
|5976|    |-	return cmpAttack && cmpAttack.CanAttackAsFormation()
|5977|    |-		&& this.GetCurrentState() == "FORMATIONCONTROLLER.COMBAT.ATTACKING";
|    |5976|+	return cmpAttack && cmpAttack.CanAttackAsFormation() &&
|    |5977|+		this.GetCurrentState() == "FORMATIONCONTROLLER.COMBAT.ATTACKING";
|5978|5978| };
|5979|5979| 
|5980|5980| //// Animal specific functions ////
|    | [NORMAL] ESLintBear (spaced-comment):
|    | Expected space or tab after '//' in comment.
|----|    | /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|    |++++| /zpool0/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
|5977|5977| 		&& this.GetCurrentState() == "FORMATIONCONTROLLER.COMBAT.ATTACKING";
|5978|5978| };
|5979|5979| 
|5980|    |-//// Animal specific functions ////
|    |5980|+// // Animal specific functions ////
|5981|5981| 
|5982|5982| UnitAI.prototype.MoveRandomly = function(distance)
|5983|5983| {

binaries/data/mods/public/simulation/components/UnitAI.js
| 333| »   »   »   return·true;
|    | [NORMAL] ESLintBear (consistent-return):
|    | Method 'Order.WalkToTarget' expected no return value.

binaries/data/mods/public/simulation/components/UnitAI.js
| 922| »   »   »   "enter":·function()·{
|    | [NORMAL] ESLintBear (consistent-return):
|    | Expected to return a value at the end of method 'enter'.

binaries/data/mods/public/simulation/components/UnitAI.js
| 947| »   »   »   "enter":·function(msg)·{
|    | [NORMAL] ESLintBear (consistent-return):
|    | Expected to return a value at the end of method 'enter'.

binaries/data/mods/public/simulation/components/UnitAI.js
| 997| »   »   »   »   »   return·true;
|    | [NORMAL] ESLintBear (consistent-return):
|    | Method 'enter' expected no return value.

binaries/data/mods/public/simulation/components/UnitAI.js
|1040| »   »   »   »   "enter":·function()·{
|    | [NORMAL] ESLintBear (consistent-return):
|    | Expected to return a value at the end of method 'enter'.

binaries/data/mods/public/simulation/components/UnitAI.js
|1085| »   »   »   "enter":·function()·{
|    | [NORMAL] ESLintBear (consistent-return):
|    | Expected to return a value at the end of method 'enter'.

binaries/data/mods/public/simulation/components/UnitAI.js
|1117| »   »   »   »   "enter":·function()·{
|    | [NORMAL] ESLintBear (consistent-return):
|    | Expected to return a value at the end of method 'enter'.

binaries/data/mods/public/simulation/components/UnitAI.js
|1277| »   »   "enter":·function()·{
|    | [NORMAL] ESLintBear (consistent-return):
|    | Expected to return a value at the end of method 'enter'.

binaries/data/mods/public/simulation/components/UnitAI.js
|1344| »   »   »   "enter":·function()·{
|    | [NORMAL] ESLintBear (consistent-return):
|    | Expected to return a value at the end of method 'enter'.

binaries/data/mods/public/simulation/components/UnitAI.js
|1536| »   »   »   "enter":·function()·{
|    | [NORMAL] ESLintBear (consistent-return):
|    | Expected to return a value at the end of method 'enter'.

binaries/data/mods/public/simulation/components/UnitAI.js
|1558| »   »   »   "enter":·function()·{
|    | [NORMAL] ESLintBear (consistent-return):
|    | Expected to return a value at the end of method 'enter'.

binaries/data/mods/public/simulation/components/UnitAI.js
|1590| »   »   »   "enter":·function()·{
|    | [NORMAL] ESLintBear (consistent-return):
|    | Expected to return a value at the end of method 'enter'.

binaries/data/mods/public/simulation/components/UnitAI.js
|1744| »   »   »   "enter":·function()·{
|    | [NORMAL] ESLintBear (consistent-return):
|    | Expected to return a value at the end of method 'enter'.

binaries/data/mods/public/simulation/components/UnitAI.js
|1794| »   »   »   »   "enter":·function()·{
|    | [NORMAL] ESLintBear (consistent-return):
|    | Expected to return a value at the end of method 'enter'.

binaries/data/mods/public/simulation/components/UnitAI.js
|1872| »   »   »   »   "enter":·function()·{
|    | [NORMAL] ESLintBear (consistent-return):
|    | Expected to return a value at the end of method 'enter'.

binaries/data/mods/public/simulation/components/UnitAI.js
|2049| »   »   »   »   "enter":·function()·{
|    | [NORMAL] ESLintBear (consistent-return):
|    | Expected to return a value at the end of method 'enter'.

binaries/data/mods/public/simulation/components/UnitAI.js
|2165| »   »   »   »   "enter":·function()·{
|    | [NORMAL] ESLintBear (consistent-return):
|    | Expected to return a value at the end of method 'enter'.

binaries/data/mods/public/simulation/components/UnitAI.js
|2440| »   »   »   »   "enter":·function()·{
|    | [NORMAL] ESLintBear (consistent-return):
|    | Expected to return a value at the end of method 'enter'.

binaries/data/mods/public/simulation/components/UnitAI.js
|2473| »   »   »   »   "enter":·function()·{
|    | [NORMAL] ESLintBear (consistent-return):
|    | Expected to return a value at the end of method 'enter'.

binaries/data/mods/public/simulation/components/UnitAI.js
|2579| »   »   »   »   "enter":·function()·{
|    | [NORMAL] ESLintBear (consistent-return):
|    | Expected to return a value at the end of method 'enter'.

binaries/data/mods/public/simulation/components/UnitAI.js
|2645| »   »   »   »   "enter":·function()·{
|    | [NORMAL] ESLintBear (consistent-return):
|    | Expected to return a value at the end of method 'enter'.

binaries/data/mods/public/simulation/components/UnitAI.js
|2684| »   »   »   »   "enter":·function()·{
|    | [NORMAL] ESLintBear (consistent-return):
|    | Expected to return a value at the end of method 'enter'.

binaries/data/mods/public/simulation/components/UnitAI.js
|2884| »   »   »   »   "enter":·function()·{
|    | [NORMAL] ESLintBear (consistent-return):
|    | Expected to return a value at the end of method 'enter'.

binaries/data/mods/public/simulation/components/UnitAI.js
|3077| »   »   »   »   "enter":·function()·{
|    | [NORMAL] ESLintBear (consistent-return):
|    | Expected to return a value at the end of method 'enter'.

binaries/data/mods/public/simulation/components/UnitAI.js
|3801| »   var·isWorkType·=·type·=>·type·==·"Gather"·||·type·==·"Trade"·||·type·==·"Repair"·||·type·==·"ReturnResource";
|    | [NORMAL] ESLintBear (no-shadow):
|    | 'type' is already declared in the upper scope.

binaries/data/mods/public/simulation/components/UnitAI.js
|4649| »   var·target·=·ents.find(target·=>·this.CanAttack(target));
|    | [NORMAL] ESLintBear (no-shadow):
|    | 'target' is already declared in the upper scope.

binaries/data/mods/public/simulation/components/UnitAI.js
|4664| »   var·target·=·ents.find(target·=>
|    | [NORMAL] ESLintBear (no-shadow):
|    | 'target' is already declared in the upper scope.

binaries/data/mods/public/simulation/components/UnitAI.js
|4710| »   var·ent·=·ents.find(ent·=>·this.CanHeal(ent));
|    | [NORMAL] ESLintBear (no-shadow):
|    | 'ent' is already declared in the upper scope.

binaries/data/mods/public/simulation/components/UnitAI.js
|4733| »   »   ····cmpAttack.GetAttackTypes().some(type·=>·cmpUnitAI.CheckTargetAttackRange(this.isGuardOf,·type)))
|    | [NORMAL] ESLintBear (no-shadow):
|    | 'type' is already declared in the upper scope.

binaries/data/mods/public/simulation/components/UnitAI.js
|2004| »   »   »   »   »   »   &&·this.order.data.target·!=·msg.data.attacker·&&·this.GetBestAttackAgainst(msg.data.attacker,·true)·!=·"Capture")
|    | [NORMAL] JSHintBear:
|    | Misleading line break before '&&'; readers may interpret this as an expression boundary.

binaries/data/mods/public/simulation/components/UnitAI.js
|3763| »   »   var·order·=·{·"type":·type,·"data":·data·};
|    | [NORMAL] JSHintBear:
|    | 'order' is already defined.

binaries/data/mods/public/simulation/components/UnitAI.js
|3832| »   for·(var·i·=·0;·i·<·this.orderQueue.length;·++i)
|    | [NORMAL] JSHintBear:
|    | 'i' is already defined.

binaries/data/mods/public/simulation/components/UnitAI.js
|4666| »   »   &&·this.CheckTargetDistanceFromHeldPosition(target,·IID_Attack,·this.GetBestAttackAgainst(target,·true))
|    | [NORMAL] JSHintBear:
|    | Misleading line break before '&&'; readers may interpret this as an expression boundary.

binaries/data/mods/public/simulation/components/UnitAI.js
|4667| »   »   &&·(this.GetStance().respondChaseBeyondVision·||·this.CheckTargetIsInVisionRange(target))
|    | [NORMAL] JSHintBear:
|    | Misleading line break before '&&'; readers may interpret this as an expression boundary.

binaries/data/mods/public/simulation/components/UnitAI.js
|5555| »   »   »   »   »   »   &&·!MatchesClassList(cmpIdentity.GetClassesList(),·targetClasses.attack))
|    | [NORMAL] JSHintBear:
|    | Misleading line break before '&&'; readers may interpret this as an expression boundary.

binaries/data/mods/public/simulation/components/UnitAI.js
|5558| »   »   »   »   »   »   &&·MatchesClassList(cmpIdentity.GetClassesList(),·targetClasses.avoid))
|    | [NORMAL] JSHintBear:
|    | Misleading line break before '&&'; readers may interpret this as an expression boundary.

binaries/data/mods/public/simulation/components/UnitAI.js
|5571| »   var·targets·=·this.GetTargetsFromUnit();
|    | [NORMAL] JSHintBear:
|    | 'targets' is already defined.

binaries/data/mods/public/simulation/components/UnitAI.js
|5572| »   for·(var·targ·of·targets)
|    | [NORMAL] JSHintBear:
|    | 'targ' is already defined.

binaries/data/mods/public/simulation/components/UnitAI.js
|5578| »   »   »   var·cmpIdentity·=·Engine.QueryInterface(targ,·IID_Identity);
|    | [NORMAL] JSHintBear:
|    | 'cmpIdentity' is already defined.

binaries/data/mods/public/simulation/components/UnitAI.js
|5579| »   »   »   var·targetClasses·=·this.order.data.targetClasses;
|    | [NORMAL] JSHintBear:
|    | 'targetClasses' is already defined.

binaries/data/mods/public/simulation/components/UnitAI.js
|5581| »   »   »   »   &&·!MatchesClassList(cmpIdentity.GetClassesList(),·targetClasses.attack))
|    | [NORMAL] JSHintBear:
|    | Misleading line break before '&&'; readers may interpret this as an expression boundary.

binaries/data/mods/public/simulation/components/UnitAI.js
|5584| »   »   »   »   &&·MatchesClassList(cmpIdentity.GetClassesList(),·targetClasses.avoid))
|    | [NORMAL] JSHintBear:
|    | Misleading line break before '&&'; readers may interpret this as an expression boundary.

binaries/data/mods/public/simulation/components/UnitAI.js
|5659| »   »   var·cmpVision·=·Engine.QueryInterface(this.entity,·IID_Vision);
|    | [NORMAL] JSHintBear:
|    | 'cmpVision' is already defined.

binaries/data/mods/public/simulation/components/UnitAI.js
|5662| »   »   var·range·=·cmpVision.GetRange();
|    | [NORMAL] JSHintBear:
|    | 'range' is already defined.

binaries/data/mods/public/simulation/components/UnitAI.js
|5667| »   »   var·cmpRanged·=·Engine.QueryInterface(this.entity,·iid);
|    | [NORMAL] JSHintBear:
|    | 'cmpRanged' is already defined.

binaries/data/mods/public/simulation/components/UnitAI.js
|5670| »   »   var·range·=·iid·!==·IID_Attack·?·cmpRanged.GetRange()·:·cmpRanged.GetFullAttackRange();
|    | [NORMAL] JSHintBear:
|    | 'range' is already defined.

binaries/data/mods/public/simulation/components/UnitAI.js
|5671| »   »   var·cmpVision·=·Engine.QueryInterface(this.entity,·IID_Vision);
|    | [NORMAL] JSHintBear:
|    | 'cmpVision' is already defined.

binaries/data/mods/public/simulation/components/UnitAI.js
|5681| »   »   var·cmpVision·=·Engine.QueryInterface(this.entity,·IID_Vision);
|    | [NORMAL] JSHintBear:
|    | 'cmpVision' is already defined.

binaries/data/mods/public/simulation/components/UnitAI.js
|5684| »   »   var·range·=·cmpVision.GetRange();
|    | [NORMAL] JSHintBear:
|    | 'range' is already defined.

binaries/data/mods/public/simulation/components/UnitAI.js
|5977| »   »   &&·this.GetCurrentState()·==·"FORMATIONCONTROLLER.COMBAT.ATTACKING";
|    | [NORMAL] JSHintBear:
|    | Misleading line break before '&&'; readers may interpret this as an expression boundary.
Executing section cli...

Link to build: https://jenkins.wildfiregames.com/job/docker-differential/1339/display/redirect

Stan added a subscriber: Stan.Sat, Dec 21, 12:23 PM
Stan added inline comments.
binaries/data/mods/public/simulation/components/tests/test_UnitAI.js
317

Missing spaces?

Nescio added a subscriber: Nescio.Sat, Dec 21, 1:21 PM

Is “debonus” a decrease or a bonus (or a typo)?
It might become useful in the future for a fantasy mod with flying melee units (e.g. pegasi) or perhaps for pikemen on walls (right now they can't attack).