summaryrefslogtreecommitdiff
path: root/src/LivingVillage.Desktop.Tests
diff options
context:
space:
mode:
Diffstat (limited to 'src/LivingVillage.Desktop.Tests')
-rw-r--r--src/LivingVillage.Desktop.Tests/PrototypeTests.fs18
1 files changed, 18 insertions, 0 deletions
diff --git a/src/LivingVillage.Desktop.Tests/PrototypeTests.fs b/src/LivingVillage.Desktop.Tests/PrototypeTests.fs
index 4d698ad..3e15272 100644
--- a/src/LivingVillage.Desktop.Tests/PrototypeTests.fs
+++ b/src/LivingVillage.Desktop.Tests/PrototypeTests.fs
@@ -223,6 +223,24 @@ type PrototypeTests () =
Assert.AreEqual<AnimationFrame>(FrameOne, (VillageArt.animationFrame 8L))
[<TestMethod>]
+ member _.VillagersUseFourDistinctVariantsDistinctFromTheAvatar () =
+ let npcVariants = [ 0 .. 63 ] |> List.map (fun id -> npcVisualVariant (NpcId id)) |> Set.ofList
+
+ Assert.AreEqual<int>(4, npcVariants.Count)
+ Assert.IsFalse(npcVariants.Contains StrawHat)
+ Assert.AreEqual<NpcVisualVariant>(StrawHat, (avatarSpriteSpec SouthFacing 0L).Variant)
+
+ let variantXes =
+ npcVariants
+ |> Set.toList
+ |> List.map (fun variant ->
+ let rect = characterSourceRectangle { Variant = variant; Direction = SouthFacing; Frame = FrameOne }
+ rect.X)
+ |> Set.ofList
+ Assert.AreEqual<int>(4, variantXes.Count)
+ Assert.AreEqual<int>(1280, VillageArt.characterAtlasWidth)
+
+ [<TestMethod>]
member _.ChineseCopyProvidesFormalSceneTimeMenuAndStatusLabels () =
let labels =
[ sceneLabel VillageScene