diff --git a/bruno/neon-sprawl-server/ability-definitions/Get ability definitions.bru b/bruno/neon-sprawl-server/ability-definitions/Get ability definitions.bru index f851f56..dd6ccb1 100644 --- a/bruno/neon-sprawl-server/ability-definitions/Get ability definitions.bru +++ b/bruno/neon-sprawl-server/ability-definitions/Get ability definitions.bru @@ -17,7 +17,7 @@ tests { const body = res.getBody(); expect(body.schemaVersion).to.equal(1); expect(body.abilities).to.be.an("array"); - expect(body.abilities.length).to.equal(4); + expect(body.abilities.length).to.equal(7); }); test("abilities are ascending by id (ordinal)", function () { @@ -27,13 +27,16 @@ tests { expect(ids).to.eql(sorted); }); - test("frozen prototype four matches registry id order", function () { + test("frozen prototype seven matches registry id order", function () { const body = res.getBody(); const ids = body.abilities.map((x) => x.id); expect(ids).to.eql([ "prototype_burst", "prototype_dash", "prototype_guard", + "prototype_npc_elite_slam", + "prototype_npc_melee_strike", + "prototype_npc_ranged_shot", "prototype_pulse", ]); }); @@ -44,6 +47,7 @@ tests { expect(row).to.be.an("object"); expect(row.displayName).to.equal("Prototype Pulse"); expect(row.baseDamage).to.equal(25); + expect(row.maxRange).to.equal(6); expect(row.cooldownSeconds).to.equal(3); expect(row.abilityKind).to.equal("attack"); }); @@ -54,6 +58,7 @@ tests { expect(row).to.be.an("object"); expect(row.displayName).to.equal("Prototype Burst"); expect(row.baseDamage).to.equal(40); + expect(row.maxRange).to.equal(6); expect(row.cooldownSeconds).to.equal(5); expect(row.abilityKind).to.equal("attack"); }); @@ -64,6 +69,7 @@ tests { expect(row).to.be.an("object"); expect(row.abilityKind).to.equal("utility"); expect(row.baseDamage).to.equal(0); + expect(row.maxRange).to.equal(6); expect(row.cooldownSeconds).to.equal(6); }); @@ -73,6 +79,37 @@ tests { expect(row).to.be.an("object"); expect(row.abilityKind).to.equal("movement"); expect(row.baseDamage).to.equal(0); + expect(row.maxRange).to.equal(6); expect(row.cooldownSeconds).to.equal(4); }); + + test("prototype_npc_melee_strike row matches catalog", function () { + const body = res.getBody(); + const row = body.abilities.find((x) => x.id === "prototype_npc_melee_strike"); + expect(row).to.be.an("object"); + expect(row.baseDamage).to.equal(15); + expect(row.maxRange).to.equal(2); + expect(row.cooldownSeconds).to.equal(3); + expect(row.abilityKind).to.equal("attack"); + }); + + test("prototype_npc_ranged_shot row matches catalog", function () { + const body = res.getBody(); + const row = body.abilities.find((x) => x.id === "prototype_npc_ranged_shot"); + expect(row).to.be.an("object"); + expect(row.baseDamage).to.equal(12); + expect(row.maxRange).to.equal(10); + expect(row.cooldownSeconds).to.equal(4); + expect(row.abilityKind).to.equal("attack"); + }); + + test("prototype_npc_elite_slam row matches catalog", function () { + const body = res.getBody(); + const row = body.abilities.find((x) => x.id === "prototype_npc_elite_slam"); + expect(row).to.be.an("object"); + expect(row.baseDamage).to.equal(25); + expect(row.maxRange).to.equal(4); + expect(row.cooldownSeconds).to.equal(5); + expect(row.abilityKind).to.equal("attack"); + }); } diff --git a/bruno/neon-sprawl-server/npc-behavior-definitions/Get npc behavior definitions.bru b/bruno/neon-sprawl-server/npc-behavior-definitions/Get npc behavior definitions.bru index 0358b1e..60e7c74 100644 --- a/bruno/neon-sprawl-server/npc-behavior-definitions/Get npc behavior definitions.bru +++ b/bruno/neon-sprawl-server/npc-behavior-definitions/Get npc behavior definitions.bru @@ -49,6 +49,22 @@ tests { expect(row.telegraphWindupSeconds).to.equal(1.5); expect(row.attackDamage).to.equal(15); expect(row.attackCooldownSeconds).to.equal(3); + expect(row.attackAbilityId).to.equal("prototype_npc_melee_strike"); + }); + + test("prototype_ranged_control row matches catalog", function () { + const body = res.getBody(); + const row = body.npcBehaviors.find((x) => x.id === "prototype_ranged_control"); + expect(row).to.be.an("object"); + expect(row.displayName).to.equal("Ranged Control"); + expect(row.archetypeKind).to.equal("ranged_control"); + expect(row.maxHp).to.equal(80); + expect(row.aggroRadius).to.equal(10); + expect(row.leashRadius).to.equal(20); + expect(row.telegraphWindupSeconds).to.equal(2); + expect(row.attackDamage).to.equal(12); + expect(row.attackCooldownSeconds).to.equal(4); + expect(row.attackAbilityId).to.equal("prototype_npc_ranged_shot"); }); test("prototype_elite_mini_boss row matches catalog", function () { @@ -63,5 +79,6 @@ tests { expect(row.telegraphWindupSeconds).to.equal(2.5); expect(row.attackDamage).to.equal(25); expect(row.attackCooldownSeconds).to.equal(5); + expect(row.attackAbilityId).to.equal("prototype_npc_elite_slam"); }); } diff --git a/server/NeonSprawl.Server.Tests/Game/Npc/NpcBehaviorDefinitionsWorldApiTests.cs b/server/NeonSprawl.Server.Tests/Game/Npc/NpcBehaviorDefinitionsWorldApiTests.cs index 1b8b01c..142bda1 100644 --- a/server/NeonSprawl.Server.Tests/Game/Npc/NpcBehaviorDefinitionsWorldApiTests.cs +++ b/server/NeonSprawl.Server.Tests/Game/Npc/NpcBehaviorDefinitionsWorldApiTests.cs @@ -43,6 +43,7 @@ public class NpcBehaviorDefinitionsWorldApiTests Assert.Equal(1.5, melee.TelegraphWindupSeconds); Assert.Equal(15, melee.AttackDamage); Assert.Equal(3.0, melee.AttackCooldownSeconds); + Assert.Equal("prototype_npc_melee_strike", melee.AttackAbilityId); var elite = body.NpcBehaviors.Single(b => b.Id == PrototypeNpcBehaviorRegistry.PrototypeEliteMiniBoss); Assert.Equal("Elite Mini-Boss", elite.DisplayName); @@ -53,5 +54,6 @@ public class NpcBehaviorDefinitionsWorldApiTests Assert.Equal(2.5, elite.TelegraphWindupSeconds); Assert.Equal(25, elite.AttackDamage); Assert.Equal(5.0, elite.AttackCooldownSeconds); + Assert.Equal("prototype_npc_elite_slam", elite.AttackAbilityId); } }