Resolve WES-144 "Feedback justsign"

This commit is contained in:
Helena Van Breugel
2023-04-08 20:28:42 +00:00
parent 73c4756f19
commit 2b71bde592
56 changed files with 2966 additions and 1262 deletions

View File

@@ -35,7 +35,7 @@ public class GameEndedPanelTests
GameEndedPanel gameEndedPanel = (GameEndedPanel)GameObject.FindObjectOfType(typeof(GameEndedPanel));
Assert.NotNull(gameEndedPanel);
Assert.AreEqual("Score: 6", gameEndedPanel.scoreText.text);
Assert.AreEqual("Score: 0", gameEndedPanel.scoreText.text);
Assert.AreEqual("1", gameEndedPanel.lettersRightText.text);
Assert.AreEqual("2", gameEndedPanel.lettersWrongText.text);
Assert.AreEqual("3", gameEndedPanel.lettersTotalText.text);

View File

@@ -27,9 +27,9 @@ public class SpellingBeeControllerTests
yield return new WaitForSeconds(0.2f);
Assert.AreEqual(0, spellingBeeController.CalculateScore());
spellingBeeController.NextWord();
Assert.AreEqual(5, spellingBeeController.CalculateScore());
Assert.AreEqual(0, spellingBeeController.CalculateScore());
spellingBeeController.NextLetter(true);
Assert.AreEqual(6, spellingBeeController.CalculateScore());
Assert.AreEqual(10, spellingBeeController.CalculateScore());
}
[UnityTest]

View File

@@ -326,6 +326,82 @@ Transform:
m_Father: {fileID: 0}
m_RootOrder: 1
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!1 &160423966
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 160423967}
- component: {fileID: 160423969}
- component: {fileID: 160423968}
m_Layer: 5
m_Name: Image
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!224 &160423967
RectTransform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 160423966}
m_LocalRotation: {x: 0, y: -1, z: 0, w: 0}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 906197777}
m_RootOrder: 0
m_LocalEulerAnglesHint: {x: 180, y: 0, z: 180}
m_AnchorMin: {x: 0, y: 0}
m_AnchorMax: {x: 1, y: 1}
m_AnchoredPosition: {x: 0, y: 0}
m_SizeDelta: {x: 0, y: 0}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!114 &160423968
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 160423966}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3}
m_Name:
m_EditorClassIdentifier:
m_Material: {fileID: 0}
m_Color: {r: 1, g: 1, b: 1, a: 1}
m_RaycastTarget: 1
m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0}
m_Maskable: 1
m_OnCullStateChanged:
m_PersistentCalls:
m_Calls: []
m_Sprite: {fileID: 21300000, guid: b64232b71c9f17a4d9494ad951a74dfa, type: 3}
m_Type: 0
m_PreserveAspect: 0
m_FillCenter: 1
m_FillMethod: 4
m_FillAmount: 1
m_FillClockwise: 1
m_FillOrigin: 0
m_UseSpriteMesh: 0
m_PixelsPerUnitMultiplier: 1
--- !u!222 &160423969
CanvasRenderer:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 160423966}
m_CullTransparentMesh: 1
--- !u!1 &229512365
GameObject:
m_ObjectHideFlags: 0
@@ -343,7 +419,7 @@ GameObject:
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
m_IsActive: 0
--- !u!224 &229512366
RectTransform:
m_ObjectHideFlags: 0
@@ -357,7 +433,7 @@ RectTransform:
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 906197777}
m_RootOrder: 0
m_RootOrder: 1
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0.5, y: 1}
m_AnchorMax: {x: 0.5, y: 1}
@@ -386,15 +462,15 @@ MonoBehaviour:
m_Calls: []
m_text: Spelling Bee
m_isRightToLeft: 0
m_fontAsset: {fileID: 11400000, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2}
m_sharedMaterial: {fileID: 2180264, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2}
m_fontAsset: {fileID: 11400000, guid: 3602bedf0ebe5b64596873f09eddf57b, type: 2}
m_sharedMaterial: {fileID: -1030930060397404263, guid: 3602bedf0ebe5b64596873f09eddf57b, type: 2}
m_fontSharedMaterials: []
m_fontMaterial: {fileID: 0}
m_fontMaterials: []
m_fontColor32:
serializedVersion: 2
rgba: 4279242768
m_fontColor: {r: 0.0627451, g: 0.0627451, b: 0.0627451, a: 1}
rgba: 4284235525
m_fontColor: {r: 0.019607844, g: 0.24705882, b: 0.36078432, a: 1}
m_enableVertexGradient: 0
m_colorMode: 3
m_fontColorGradient:
@@ -411,13 +487,13 @@ MonoBehaviour:
m_faceColor:
serializedVersion: 2
rgba: 4294967295
m_fontSize: 64
m_fontSizeBase: 64
m_fontSize: 90
m_fontSizeBase: 90
m_fontWeight: 400
m_enableAutoSizing: 0
m_fontSizeMin: 18
m_fontSizeMax: 72
m_fontStyle: 1
m_fontStyle: 0
m_HorizontalAlignment: 2
m_VerticalAlignment: 512
m_textAlignment: 65535
@@ -1299,7 +1375,7 @@ RectTransform:
- {fileID: 1761838460}
- {fileID: 862382568}
m_Father: {fileID: 906197777}
m_RootOrder: 7
m_RootOrder: 9
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 0}
m_AnchorMax: {x: 1, y: 1}
@@ -1709,15 +1785,16 @@ RectTransform:
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children:
- {fileID: 160423967}
- {fileID: 229512366}
- {fileID: 1843239269}
- {fileID: 1985911005}
- {fileID: 1743003086}
- {fileID: 1338727893}
- {fileID: 1346005056}
- {fileID: 1843239269}
- {fileID: 1812475781}
- {fileID: 967164044}
- {fileID: 757133118}
- {fileID: 667202413}
- {fileID: 757133118}
m_Father: {fileID: 1768150806}
m_RootOrder: 0
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
@@ -1773,31 +1850,31 @@ PrefabInstance:
m_Modifications:
- target: {fileID: 4318122119930585316, guid: 7c71c65ecb5fe0449a8b0d178987f016, type: 3}
propertyPath: m_Pivot.x
value: 1
value: 0
objectReference: {fileID: 0}
- target: {fileID: 4318122119930585316, guid: 7c71c65ecb5fe0449a8b0d178987f016, type: 3}
propertyPath: m_Pivot.y
value: 1
value: 0.5
objectReference: {fileID: 0}
- target: {fileID: 4318122119930585316, guid: 7c71c65ecb5fe0449a8b0d178987f016, type: 3}
propertyPath: m_RootOrder
value: 6
value: 7
objectReference: {fileID: 0}
- target: {fileID: 4318122119930585316, guid: 7c71c65ecb5fe0449a8b0d178987f016, type: 3}
propertyPath: m_AnchorMax.x
value: 1
value: 0.5
objectReference: {fileID: 0}
- target: {fileID: 4318122119930585316, guid: 7c71c65ecb5fe0449a8b0d178987f016, type: 3}
propertyPath: m_AnchorMax.y
value: 1
value: 0.5
objectReference: {fileID: 0}
- target: {fileID: 4318122119930585316, guid: 7c71c65ecb5fe0449a8b0d178987f016, type: 3}
propertyPath: m_AnchorMin.x
value: 1
value: 0.5
objectReference: {fileID: 0}
- target: {fileID: 4318122119930585316, guid: 7c71c65ecb5fe0449a8b0d178987f016, type: 3}
propertyPath: m_AnchorMin.y
value: 1
value: 0.5
objectReference: {fileID: 0}
- target: {fileID: 4318122119930585316, guid: 7c71c65ecb5fe0449a8b0d178987f016, type: 3}
propertyPath: m_SizeDelta.x
@@ -1837,11 +1914,11 @@ PrefabInstance:
objectReference: {fileID: 0}
- target: {fileID: 4318122119930585316, guid: 7c71c65ecb5fe0449a8b0d178987f016, type: 3}
propertyPath: m_AnchoredPosition.x
value: -298
value: 71
objectReference: {fileID: 0}
- target: {fileID: 4318122119930585316, guid: 7c71c65ecb5fe0449a8b0d178987f016, type: 3}
propertyPath: m_AnchoredPosition.y
value: -644
value: -200
objectReference: {fileID: 0}
- target: {fileID: 4318122119930585316, guid: 7c71c65ecb5fe0449a8b0d178987f016, type: 3}
propertyPath: m_LocalEulerAnglesHint.x
@@ -2418,6 +2495,141 @@ MonoBehaviour:
m_hasFontAssetChanged: 0
m_baseMaterial: {fileID: 0}
m_maskOffset: {x: 0, y: 0, z: 0, w: 0}
--- !u!1 &1130901868
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 1130901869}
- component: {fileID: 1130901871}
- component: {fileID: 1130901870}
m_Layer: 5
m_Name: Timing Feedback
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!224 &1130901869
RectTransform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1130901868}
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 1985911005}
m_RootOrder: 0
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0.5, y: 0}
m_AnchorMax: {x: 0.5, y: 0}
m_AnchoredPosition: {x: 0, y: 75}
m_SizeDelta: {x: 100, y: 100}
m_Pivot: {x: 0.5, y: 0}
--- !u!114 &1130901870
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1130901868}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: f4688fdb7df04437aeb418b961361dc5, type: 3}
m_Name:
m_EditorClassIdentifier:
m_Material: {fileID: 0}
m_Color: {r: 1, g: 1, b: 1, a: 1}
m_RaycastTarget: 1
m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0}
m_Maskable: 1
m_OnCullStateChanged:
m_PersistentCalls:
m_Calls: []
m_text: +10
m_isRightToLeft: 0
m_fontAsset: {fileID: 11400000, guid: 3602bedf0ebe5b64596873f09eddf57b, type: 2}
m_sharedMaterial: {fileID: -1030930060397404263, guid: 3602bedf0ebe5b64596873f09eddf57b, type: 2}
m_fontSharedMaterials: []
m_fontMaterial: {fileID: 0}
m_fontMaterials: []
m_fontColor32:
serializedVersion: 2
rgba: 4284404875
m_fontColor: {r: 0.54509807, g: 0.83137256, b: 0.36862746, a: 1}
m_enableVertexGradient: 0
m_colorMode: 3
m_fontColorGradient:
topLeft: {r: 1, g: 1, b: 1, a: 1}
topRight: {r: 1, g: 1, b: 1, a: 1}
bottomLeft: {r: 1, g: 1, b: 1, a: 1}
bottomRight: {r: 1, g: 1, b: 1, a: 1}
m_fontColorGradientPreset: {fileID: 0}
m_spriteAsset: {fileID: 0}
m_tintAllSprites: 0
m_StyleSheet: {fileID: 0}
m_TextStyleHashCode: -1183493901
m_overrideHtmlColors: 0
m_faceColor:
serializedVersion: 2
rgba: 4294967295
m_fontSize: 60
m_fontSizeBase: 60
m_fontWeight: 400
m_enableAutoSizing: 0
m_fontSizeMin: 18
m_fontSizeMax: 72
m_fontStyle: 0
m_HorizontalAlignment: 2
m_VerticalAlignment: 512
m_textAlignment: 65535
m_characterSpacing: 0
m_wordSpacing: 0
m_lineSpacing: 0
m_lineSpacingMax: 0
m_paragraphSpacing: 0
m_charWidthMaxAdj: 0
m_enableWordWrapping: 1
m_wordWrappingRatios: 0.4
m_overflowMode: 0
m_linkedTextComponent: {fileID: 0}
parentLinkedComponent: {fileID: 0}
m_enableKerning: 1
m_enableExtraPadding: 0
checkPaddingRequired: 0
m_isRichText: 1
m_parseCtrlCharacters: 1
m_isOrthographic: 1
m_isCullingEnabled: 0
m_horizontalMapping: 0
m_verticalMapping: 0
m_uvLineOffset: 0
m_geometrySortingOrder: 0
m_IsTextObjectScaleStatic: 0
m_VertexBufferAutoSizeReduction: 0
m_useMaxVisibleDescender: 1
m_pageToDisplay: 1
m_margin: {x: 0, y: 0, z: 0, w: 0}
m_isUsingLegacyAnimationComponent: 0
m_isVolumetricText: 0
m_hasFontAssetChanged: 0
m_baseMaterial: {fileID: 0}
m_maskOffset: {x: 0, y: 0, z: 0, w: 0}
--- !u!222 &1130901871
CanvasRenderer:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1130901868}
m_CullTransparentMesh: 1
--- !u!1 &1172084826
GameObject:
m_ObjectHideFlags: 0
@@ -3175,13 +3387,13 @@ RectTransform:
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 906197777}
m_RootOrder: 2
m_RootOrder: 5
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 1, y: 1}
m_AnchorMax: {x: 1, y: 1}
m_AnchoredPosition: {x: -1200, y: -400}
m_SizeDelta: {x: 400, y: 400}
m_Pivot: {x: 1, y: 1}
m_AnchorMin: {x: 0.5, y: 0.5}
m_AnchorMax: {x: 0.5, y: 0.5}
m_AnchoredPosition: {x: -123, y: 110}
m_SizeDelta: {x: 450, y: 450}
m_Pivot: {x: 1, y: 0.5}
--- !u!1 &1346005055
GameObject:
m_ObjectHideFlags: 0
@@ -3212,7 +3424,7 @@ RectTransform:
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 906197777}
m_RootOrder: 3
m_RootOrder: 6
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0.5, y: 0}
m_AnchorMax: {x: 0.5, y: 0}
@@ -3785,6 +3997,8 @@ MonoBehaviour:
feedbackProgress: {fileID: 967164046}
feedbackProgressImage: {fileID: 967164045}
webcamScreen: {fileID: 1743003084}
scoreDisplay: {fileID: 1985911006}
scoreBonus: {fileID: 1130901870}
--- !u!1 &1499197558
GameObject:
m_ObjectHideFlags: 0
@@ -4365,13 +4579,13 @@ RectTransform:
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 906197777}
m_RootOrder: 1
m_RootOrder: 4
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0.5, y: 0.5}
m_AnchorMax: {x: 0.5, y: 0.5}
m_AnchoredPosition: {x: 53, y: 382}
m_AnchoredPosition: {x: 71, y: 110}
m_SizeDelta: {x: 900, y: 600}
m_Pivot: {x: 0, y: 1}
m_Pivot: {x: 0, y: 0.5}
--- !u!1 &1754130535
GameObject:
m_ObjectHideFlags: 0
@@ -4813,14 +5027,14 @@ RectTransform:
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 906197777}
m_RootOrder: 5
m_Father: {fileID: 1843239269}
m_RootOrder: 0
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0.5, y: 1}
m_AnchorMax: {x: 0.5, y: 1}
m_AnchoredPosition: {x: -458, y: -153}
m_AnchorMin: {x: 0.5, y: 0}
m_AnchorMax: {x: 0.5, y: 0}
m_AnchoredPosition: {x: 66, y: 75}
m_SizeDelta: {x: 100, y: 100}
m_Pivot: {x: 0.5, y: 1}
m_Pivot: {x: 0.5, y: 0}
--- !u!114 &1812475782
MonoBehaviour:
m_ObjectHideFlags: 0
@@ -4868,14 +5082,14 @@ MonoBehaviour:
m_faceColor:
serializedVersion: 2
rgba: 4294967295
m_fontSize: 78
m_fontSizeBase: 78
m_fontSize: 60
m_fontSizeBase: 60
m_fontWeight: 400
m_enableAutoSizing: 0
m_fontSizeMin: 18
m_fontSizeMax: 72
m_fontStyle: 0
m_HorizontalAlignment: 4
m_HorizontalAlignment: 2
m_VerticalAlignment: 512
m_textAlignment: 65535
m_characterSpacing: 0
@@ -4990,7 +5204,7 @@ MonoBehaviour:
m_fontSizeMin: 18
m_fontSizeMax: 72
m_fontStyle: 0
m_HorizontalAlignment: 2
m_HorizontalAlignment: 4
m_VerticalAlignment: 512
m_textAlignment: 65535
m_characterSpacing: 0
@@ -5044,14 +5258,15 @@ RectTransform:
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children: []
m_Children:
- {fileID: 1812475781}
m_Father: {fileID: 906197777}
m_RootOrder: 4
m_RootOrder: 2
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0.5, y: 1}
m_AnchorMax: {x: 0.5, y: 1}
m_AnchoredPosition: {x: -458, y: -203}
m_SizeDelta: {x: 300, y: 150}
m_AnchoredPosition: {x: -252, y: -75}
m_SizeDelta: {x: 300, y: 100}
m_Pivot: {x: 0.5, y: 1}
--- !u!1 &1898716846
GameObject:
@@ -5323,3 +5538,139 @@ CanvasRenderer:
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1984101844}
m_CullTransparentMesh: 1
--- !u!1 &1985911004
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 1985911005}
- component: {fileID: 1985911007}
- component: {fileID: 1985911006}
m_Layer: 5
m_Name: Score
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!224 &1985911005
RectTransform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1985911004}
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children:
- {fileID: 1130901869}
m_Father: {fileID: 906197777}
m_RootOrder: 3
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0.5, y: 1}
m_AnchorMax: {x: 0.5, y: 1}
m_AnchoredPosition: {x: 275, y: -75}
m_SizeDelta: {x: 450, y: 100}
m_Pivot: {x: 0.5, y: 1}
--- !u!114 &1985911006
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1985911004}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: f4688fdb7df04437aeb418b961361dc5, type: 3}
m_Name:
m_EditorClassIdentifier:
m_Material: {fileID: 0}
m_Color: {r: 1, g: 1, b: 1, a: 1}
m_RaycastTarget: 1
m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0}
m_Maskable: 1
m_OnCullStateChanged:
m_PersistentCalls:
m_Calls: []
m_text: 'Score: XXX'
m_isRightToLeft: 0
m_fontAsset: {fileID: 11400000, guid: 3602bedf0ebe5b64596873f09eddf57b, type: 2}
m_sharedMaterial: {fileID: -1030930060397404263, guid: 3602bedf0ebe5b64596873f09eddf57b, type: 2}
m_fontSharedMaterials: []
m_fontMaterial: {fileID: 0}
m_fontMaterials: []
m_fontColor32:
serializedVersion: 2
rgba: 4284235525
m_fontColor: {r: 0.019607844, g: 0.24705882, b: 0.36078432, a: 1}
m_enableVertexGradient: 0
m_colorMode: 3
m_fontColorGradient:
topLeft: {r: 1, g: 1, b: 1, a: 1}
topRight: {r: 1, g: 1, b: 1, a: 1}
bottomLeft: {r: 1, g: 1, b: 1, a: 1}
bottomRight: {r: 1, g: 1, b: 1, a: 1}
m_fontColorGradientPreset: {fileID: 0}
m_spriteAsset: {fileID: 0}
m_tintAllSprites: 0
m_StyleSheet: {fileID: 0}
m_TextStyleHashCode: -1183493901
m_overrideHtmlColors: 0
m_faceColor:
serializedVersion: 2
rgba: 4294967295
m_fontSize: 78
m_fontSizeBase: 78
m_fontWeight: 400
m_enableAutoSizing: 0
m_fontSizeMin: 18
m_fontSizeMax: 72
m_fontStyle: 0
m_HorizontalAlignment: 1
m_VerticalAlignment: 512
m_textAlignment: 65535
m_characterSpacing: 0
m_wordSpacing: 0
m_lineSpacing: 0
m_lineSpacingMax: 0
m_paragraphSpacing: 0
m_charWidthMaxAdj: 0
m_enableWordWrapping: 1
m_wordWrappingRatios: 0.4
m_overflowMode: 0
m_linkedTextComponent: {fileID: 0}
parentLinkedComponent: {fileID: 0}
m_enableKerning: 1
m_enableExtraPadding: 0
checkPaddingRequired: 0
m_isRichText: 1
m_parseCtrlCharacters: 1
m_isOrthographic: 1
m_isCullingEnabled: 0
m_horizontalMapping: 0
m_verticalMapping: 0
m_uvLineOffset: 0
m_geometrySortingOrder: 0
m_IsTextObjectScaleStatic: 0
m_VertexBufferAutoSizeReduction: 0
m_useMaxVisibleDescender: 1
m_pageToDisplay: 1
m_margin: {x: 0, y: 0, z: 0, w: 0}
m_isUsingLegacyAnimationComponent: 0
m_isVolumetricText: 0
m_hasFontAssetChanged: 0
m_baseMaterial: {fileID: 0}
m_maskOffset: {x: 0, y: 0, z: 0, w: 0}
--- !u!222 &1985911007
CanvasRenderer:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1985911004}
m_CullTransparentMesh: 1

View File

@@ -14,11 +14,9 @@ MonoBehaviour:
m_EditorClassIdentifier:
index: 0
title: Spelling Bee
description: In deze minigame krijg je verschillende woorden voorgeschoteld die
je zo snel mogelijk moet spellen met behulp van het vingeralfabet
description: Leer spellen als een pro
themeList: {fileID: 11400000, guid: a247e2ce790f0f746a3bc521e6ab7d58, type: 2}
thumbnail: {fileID: 21300000, guid: 99ff017f7243eeb4db0c08a6b832d744, type: 3}
minigameEntryPoint: SpellingBee/Scenes/SpellingBeeGame
controls: Je begint dit spel met 5 seconden tijd, voor elk juist antwoord krijg
je extra tijd. Hoe sneller je het spel uitspeelt, hoe meer punten je scoort.
Verloopt de timer, dan heb je het spelletje verloren
controls: Een spelletje tegen de tijd. Spel zoveel mogelijk woorden binnen de tijd!
Voor elke juiste letter krijg je extra tijd, hou het zo lang mogelijk uit.

View File

@@ -172,8 +172,31 @@ public partial class SpellingBeeController : AbstractFeedback
/// </summary>
protected string previousIncorrectSign = null;
/// <summary>
/// Reference used to set the webcam for the SignPredictor
/// </summary>
public RawImage webcamScreen;
/// <summary>
/// Reference to display the score
/// </summary>
public TMP_Text scoreDisplay;
/// <summary>
/// Reference to display the points lost/won
/// </summary>
public TMP_Text scoreBonus;
/// <summary>
/// Score obtained when spelling a letter
/// </summary>
private int correctLettersScore = 10;
/// <summary>
/// Score obtained when spelling the wrong letter :o
/// </summary>
private int incorrectLettersScore = -5;
/// <summary>
/// Start is called before the first frame update
/// </summary>
@@ -223,6 +246,9 @@ public partial class SpellingBeeController : AbstractFeedback
words.AddRange(currentTheme.learnables);
ShuffleWords();
NextWord();
scoreDisplay.text = $"Score: {CalculateScore()}";
scoreBonus.text = "";
}
/// <summary>
@@ -236,6 +262,7 @@ public partial class SpellingBeeController : AbstractFeedback
if (bonusActiveRemaining <= 0.0 && bonusTimeText.activeSelf)
{
bonusTimeText.SetActive(false);
scoreBonus.text = "";
}
else
{
@@ -277,7 +304,7 @@ public partial class SpellingBeeController : AbstractFeedback
/// <returns>The calculated score</returns>
public int CalculateScore()
{
return spelledWords * 5 + correctLetters;
return correctLetters * correctLettersScore + incorrectLetters * incorrectLettersScore;
}
/// <summary>
@@ -378,7 +405,7 @@ public partial class SpellingBeeController : AbstractFeedback
{
timerValue += (float)seconds;
bonusTimeText.SetActive(true);
bonusActiveRemaining = 2.0f;
bonusActiveRemaining = 1.0f;
}
/// <summary>
@@ -394,11 +421,17 @@ public partial class SpellingBeeController : AbstractFeedback
{
correctLetters++;
letters[letterIndex].GetComponent<Image>().color = new Color(0x8b / 255.0f, 0xd4 / 255.0f, 0x5e / 255.0f);
scoreDisplay.text = $"Score: {CalculateScore()}";
scoreBonus.text = $"+{correctLettersScore}";
scoreBonus.color = new Color(0x8b / 255.0f, 0xd4 / 255.0f, 0x5e / 255.0f);
}
else
{
incorrectLetters++;
letters[letterIndex].GetComponent<Image>().color = new Color(0xf5 / 255.0f, 0x49 / 255.0f, 0x3d / 255.0f);
scoreDisplay.text = $"Score: {CalculateScore()}";
scoreBonus.text = $"{incorrectLettersScore}";
scoreBonus.color = new Color(0xf5 / 255.0f, 0x49 / 255.0f, 0x3d / 255.0f);
}
do
@@ -532,7 +565,7 @@ public partial class SpellingBeeController : AbstractFeedback
float oldValue = feedbackProgress.value;
// use an exponential scale
float newValue = Mathf.Exp(4 * (accCurrentSign - 1.0f));
float newValue = Mathf.Exp(4 * (Mathf.Clamp(accCurrentSign / thresholdCurrentSign, 0.0f, 1.0f) - 1.0f));
feedbackProgress.gameObject.Tween("FeedbackUpdate", oldValue, newValue, 0.2f, TweenScaleFunctions.CubicEaseInOut, (t) =>
{
if (feedbackProgress != null)
@@ -548,7 +581,6 @@ public partial class SpellingBeeController : AbstractFeedback
// Correct sign
if (predictedSign == currentSign)
{
yield return new WaitForSeconds(1.0f);
PredictSign(predictedSign);
timer = DateTime.Now;
predictedSign = null;