Skip to content

Commit

Permalink
Fixed some characters that couldn't be resolved by the sprite font; F…
Browse files Browse the repository at this point in the history
…ixed comment texts for opening / closing baton with string.
  • Loading branch information
jonas committed Mar 1, 2019
1 parent 24d3763 commit 60d3e22
Show file tree
Hide file tree
Showing 5 changed files with 25 additions and 20 deletions.
2 changes: 1 addition & 1 deletion src/Game/GameLogic/Properties/Basement.Resources.es.resx
Original file line number Diff line number Diff line change
Expand Up @@ -487,7 +487,7 @@
<value>No quiero llevar eso ahora.</value>
</data>
<data name="Its_my_old_guitar_I_used_to_play_every_night_as_Landon_was_going_to_bed" xml:space="preserve">
<value>Es mi vieja guitarra. Solía ​​tocar todas las noches cuando Landon se iba a la cama.</value>
<value>Es mi vieja guitarra. Solía tocar todas las noches cuando Landon se iba a la cama.</value>
</data>
<data name="I_didnt_know_it_was_down_here_now" xml:space="preserve">
<value>No sabía que estaba aquí abajo ahora.</value>
Expand Down
4 changes: 2 additions & 2 deletions src/Game/GameLogic/Properties/Resources.Designer.cs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions src/Game/GameLogic/Properties/Resources.resx
Original file line number Diff line number Diff line change
Expand Up @@ -302,15 +302,15 @@
<value>rooms/letter/scene</value>
</data>
<data name="Letter_Text" xml:space="preserve">
<value>Hanover School Headmasters Office
<value>Hanover School Headmaster's Office
January the 13th, 2017

Dear Mr. and Mrs. Schmidt,

I am writing to inform you of an incident in which Landon was involved today at school.
Around 10:45 this morning, He was brought into my office by another teacher, who was
approached about him after class by a very distressed female student. The student claims
to have been cornered by Landon in the girls lavatory before school this morning. He
to have been cornered by Landon in the girls' lavatory before school this morning. He
told me that he was just trying to ask her to formal, which the female student corroborated,
but she also claims that he would not let her leave the washroom until she accepted the
invitation. She claims that she told him she would go with him, because she feared for her safety.
Expand Down
4 changes: 2 additions & 2 deletions src/Game/GameLogic/items/BatonWithString.cs
Original file line number Diff line number Diff line change
Expand Up @@ -32,15 +32,15 @@ IEnumerator PullScript()
{
using (Game.CutsceneBlock())
{
yield return Game.Ego.Say(Items_Res.Cant_reduce_it_with_the_string_tied_to_it);
yield return Game.Ego.Say(Items_Res.Cant_expand_it_any_further);
}
}

IEnumerator PushScript()
{
using (Game.CutsceneBlock())
{
yield return Game.Ego.Say(Items_Res.Cant_expand_it_any_further);
yield return Game.Ego.Say(Items_Res.Cant_reduce_it_with_the_string_tied_to_it);
}
}

Expand Down
31 changes: 18 additions & 13 deletions src/Tests/SessionSeven.Functional.Test/Resources.cs
Original file line number Diff line number Diff line change
Expand Up @@ -42,23 +42,28 @@ public class Resources
[TestMethod]
public void AllResourceCharactersCanBeResolvedBySpriteFont()
{
var GameSettings = new GameSettings()
{
Culture = "en-US"
};
var SupportedLanguages = new[] { "en-US", "de-DE", "es-ES" };

using (var GraphicsDevice = Mock.CreateGraphicsDevice())
using (var Runner = new SessionSevenTestEngine(new TestGame(), Mock.Wrap(GraphicsDevice), Mock.Input, GameSettings))
foreach (var Language in SupportedLanguages)
{
Runner.StartGame();
Runner.AdvanceToInteractive();

var Text = Runner.Game.World.GetScene(TestGame.SCENE_ID).GetObject(TestGame.ENTITY_ID).Get<Text>();
var GameSettings = new GameSettings()
{
Culture = Language
};

foreach (var ResourceString in GetResourceStrings())
using (var GraphicsDevice = Mock.CreateGraphicsDevice())
using (var Runner = new SessionSevenTestEngine(new TestGame(), Mock.Wrap(GraphicsDevice), Mock.Input, GameSettings))
{
// this throws if the sprite font cannot resolve a character
Text.Set(ResourceString, TextDuration.Persistent, Vector2.Zero);
Runner.StartGame();
Runner.AdvanceToInteractive();

var Text = Runner.Game.World.GetScene(TestGame.SCENE_ID).GetObject(TestGame.ENTITY_ID).Get<Text>();

foreach (var ResourceString in GetResourceStrings())
{
// this throws if the sprite font cannot resolve a character
Text.Set(ResourceString, TextDuration.Persistent, Vector2.Zero);
}
}
}
}
Expand Down

0 comments on commit 60d3e22

Please sign in to comment.