Blog Post 8 – Feelings that come with a deadline

i have written a couple times about deadlines and the panic that comes with them. i thought back to all the times i had deadlines at work, and i can’t think of a time where i felt more nervous there than at school. there’s just something special about the panic that i get over not completing something on time for a good grade.

talking to my team about it, i noticed that i didn’t feel all that stressed. i’m actually not sure how polished this project will be, but yet i am not all that worried about it. i thought about it a lot today, and i get the feeling that it has something to do with group projects.

in high school and in the beginning of college i would put a lot of effort into finishing and perfecting a group project, even if i had to put in way more work than my teammates. i have since changed that approach, and even if the end result wasn’t the best, i would still get a good grade. and i didn’t need to stress to get it.

so now, on the biggest project i have worked on in school, i trust my team to do good work. but if we don’t live up to the high goals that we set, which might be likely given how little time we have left, i know that my grade will be fine, and that i will be proud of the effort i put in. i came in to this project having no experience with any of it, so i’m happy with what we have accomplished.

Blog Post 7 – Fun with Spanish voice recognition

oh boy. i saw the date today and i panicked a little. there’s around 3 weeks left before our vr project needs to be done, and i feel like we have a lot more than 3 weeks of work to do.

i know we’ll get it done, but it’s more a matter of how well done it will be by the time we turn it in. we want to live up to our vision as much as possible, and that seems hard when we have other responsibilities that take time away from this.

back to my main focus right now though. our game will have the user say phrases in spanish to various characters in the world in order to complete quests. i created the script for our game and sent it off to some translators a couple of weeks ago.

up to this point i had been writing the storyline code using english voice recognition, and it had been going well enough. but we just got back the translated script and i needed to start testing the phrases with spanish voice recognition.

i tried to keep the phrases as simple as possible while still fitting into the flow of an actual conversation that could occur, which was hard since we want this to be beginner-friendly. some of the translated phrases ended up being longer than i expected, but it turns out that’s not a problem. what is a problem is that voice recognition returns strings that have questionable punctuation compared to what the phrase should look like.

for example, when asking for a cookbook, you say “Necesito un libro de recetas.” but no matter how i say it into my microphone it always adds questions marks like i am asking that. “¿Necesito un libro de recetas?”

so when i am checking what the user says i am going to have to use the responses i get during testing as a comparison, rather than the correct way it would be written. strange, but it will work.

Blog Post 6 – Dealing with Deadlines: VR Project

i have dealt with deadlines before, and i have dealt with deadlines while working with other people, but there was something unique about trying to make a game with other people and panicking before a deadline to show the first iteration of that game and what it will be like.

we wanted to have the first character you can talk to as a way to demo what the game will be like. i was in charge of the game’s story script and the voice recognition script, and that went somewhat smoothly for not having any experience with either. but then we needed to redo the how the ui is called so that it fits with the other scripts. like i said, we don’t have much game dev experience.

this was the first time i have ever applied async and await and that actually caused issues with the ui. we spent many hours trying to fix that. then right before we were getting ready to turn in the apk we tested it on ours quests. the voice recognition wasn’t working.

the whole time we were making this project we had been testing it in unity, not by putting the apk directly on the quest. so we never ran into this issue, and i was under the impression that my script was ready to go. since this issue was only happening when we played it this way, i couldn’t look at any debug logs to see how far the code was getting.

my panic levels were high, and so were my team’s. we had less than two hours before our deadline and the most important part of our game wasn’t working. i sat there and thought through why that might happen, and the first obvious thing was an issue with the api key. i have it reading from a file, and that works fine when testing the game on a computer, but maybe that doesn’t work when the game is on the quest. so i directly input the api key and it worked.

so we turned in what we wanted, and a big part of our project is figured out. now we have 4 weeks to iterate and make it as good as it can be. i’m excited to see how it turns out.

Blog Post 5 – A noob’s confusion with async and await

the sample code that microsoft supplies with their speech recognition unity example has asynchronous methods in a class that uses a button to call the voice record method and displays what the user says in a text ui element.

for someone who has not worked with async methods besides one week in my web dev class, it makes sense when it is working. “sure sure, call that method and it changes the text once it gathers what the user says in the microphone.” but what if i want to return a value instead of modifying a variable?

at first i didn’t think you could return a value, but then i found a video that did a pretty good job of explaining it abstractly and with an example. you can return tasks i guess, and then using await is how you can get the value out of that.

startasync calls voicerecord in my script, but the idea still holds. in my example, i’m trying to send the voice recognition script a string, compare it to what the user said, and return true or false based on that comparison. without await in the statement, i was getting an error that task<bool> could not be converted to bool.

it’s a bit confusing at first, but once i got it working it seemed fine, and can be called from any script without any button or text connected to it. now i just need to see if it works in our game.