The Beginning
|
In this, the first blog post, I will describe my work around the construction of what will become the ”Critter” in ”CritterFlux”. This critter is supposed to receive input in the form of touching it, feeding it, and other interactions. The plan the team had with the critter is to give people a reason to love it and the feeling of responsibility towards it. To accomplish this the different interactions would have to ”mean” something, and here is were I went to work. I am, for this project programming in ”Unity”, with the language C#, this was a joint choice of the team since Unity is an easy to use game development tool. Since the critter is supposed to experience some form of emotion i had to create a database of different stats, i call it the ”Critter save”. This was the first script to enter Unity. The meaning of this script was to hold all the different values for the experiences the critter could have, for example hunger, age, happiness and the sensation of cold. All these stats where simply integers that range between 0 and 100, where 0 is bad and 100 is good. It also possesses different non-permanent states which is represented by simple booleans. This was supposed to lay the ground for the future feelings that would be given as feedback to the player in the form of animation- and sound changes. When i had all these stats, i needed some way to change these through a manager of sort. To do this, I created a public function for each stat, that could change the value for that stat. The entity that changes these values would be, what i call ”The manager”, the job of the manager is to get input from the visual representation of the critter (Critter object), and then send it through to the critter save. This information path also goes backwards since the game will use time as a variable. The stats and sates in the critter save will be in constant change when time is introduced, this is the reason why I added the states. So for example the critter save sees that its hunger is beneath the value of 30, when this happens the bool for ”hunger” is true. The manager will then be reminded that the critter is hungry and in turn, let the critter object know that it is time to change animation from Idle, to Hungry. |
