Week 8 – Amsterdam trip and trash picking

APRIL 8 → APRIL 11 – 2024

Tasks

Amsterdam Trip

  • We met up with Abner at the trainstation of Amsterdam Amstel after which we had a busy day, filled with meetings with employees from various museums as well as the museum our installation will be placed in.
  • Learned more about consumer engagement in museums by observing the inner workings at Tellarts, Micropia and JCK.

Technical Developments

  • Managing version control
    • Taught another team member the proper way of working with Git through Pull Requests, Code Reviews and Merging.
  • Assisted on a UI issue
  • Rewrote script to keep track of the amount of trash collected in the scene three interaction

Miscellaneous

  • Mid term peer review (see image below)
    • Filled in the peer review spreadsheet to identify areas of improvement.
  • Procedural Art redo

Double Diamond

The majority of this week was spent outside of development but I still managed to do some work. Most of this was to do with the rewriting of a previously made script for trash collecting, more specifically the score tracking for it.

Discover

I came up with a more flexible solution that would lower the number of lines in the script as well as providing a more efficient solution in general. (see code below)

Define

The trash progress script showed a pop up with specific type and scoring for every object that was picked up. We decided that that was not necessary and so I rewrote the script to set it up more scalable and future proof.

Develop

I threw out the previous code that went through a Dictionary of trash types with their respective scores and instead simply added the score to the current score. This should see some more improvements later.

Deliver

As the development made this week was not visually different there was no specific deliverable.

Plan

Next week I will focus on finishing up scene three as far as possible to create a sort of vertical slice. I will also research how to set up the various scene in terms of functionality.


Research

This week my research was mainly conducted in person with several employees from aforementioned museums. Next to that we observed and learned from the existing interactions in these museums.


Reflection

This week was a hectic one, from Amsterdam to Enschede and finally Veenendaal. I moved around a lot and was also distracted by my redo for Procedural Art. Looking back at it, I could have done more this week but in the end I am not unhappy with the results I achieved and moreso the experience gained from the trip to Amsterdam.

We learned quite a lot and got to experience really cool installations too, which is always very valuable.

Looking at the peer review my main areas of improvement would be arriving on time and being more vocal about providing feedback and motivating my fellow team members.

Media & code

public void SetTotalScore(int score)
    {
        List<Trash.TrashType> trashTypes = new List<Trash.TrashType>();

        foreach(TrashItem trashItem in trashItems)
        {
            if (trashTypePair.ContainsKey(trashItem.trash.trashType))
            {
                trashTypePair[trashItem.trash.trashType] += 1;
            }
            else
            {
                trashTypePair.Add(trashItem.trash.trashType, 1);
            }

            if (!trashTypes.Contains(trashItem.trash.trashType))
            {
                trashTypes.Add(trashItem.trash.trashType);

                GameObject item = Instantiate(itemPrefab, itemParent);

                ItemData itemData = item.GetComponent<ItemData>();
                itemData.icon.sprite = trashItem.icon;
                itemData.scoreText.text = trashTypePair[trashItem.trash.trashType].ToString();
            }

            totalScore += trashItem.trash.Score;
        }

        Debug.Log(totalScore);
        totalScore += score;

        RefreshUI();
    }
Our filled in peer reviews.

Week 7 – Flower power and meeting with client

APRIL 1 → APRIL 4 – 2024

Tasks

Client Meeting

  • Met with the client to discuss details of an upcoming trip to Amsterdam to meet his client(s).

Technical Developments

  • Finished implementing a seed throw mechanic
    • Finalised calculations for the seed throwing.
    • Succesfully detected swipes and swipe speed.
  • Implemented a flower spawn based on previous mechanic

Double Diamond

The majority of this week was spent on further advancing the seed throwing mechanic as well as adding a flower that spawns where the seed collides with the ground.

Discover

To be able to finalise the seed throwing I did some more research into the pokemon throw to combine my current knowledge and see if a final solution can be found.

Define

The objective remained the same as last week, implementing a pokemon like throw to allow the player to swipe a certain direction at a certain speed and achieve coherent results.

Develop

I started with two new tutorials, these provided new insights and led me to a more final solution. The biggest part was tweaking the variables until it felt responsive and intuitive to use. (see code below) After that, the only thing left for this week was implementing a flower spawn.

Deliver

Nearing the end of the week I managed to finish the seed throwing and also implement the flower spawning. Both of these were then recorded and sent to the client in video format. He was positive about the development. I also made another release on GitHub to go with the development.

Plan

Next week will start with a trip to Amsterdam, where we will meet the Museum’s representatives as well as going to a few other museums for inspiration. The rest of the week’s focus will primarily be on Procedural Art for me personally.


Research

After an unsuccesful week last week, I decided to do one final dive into the pokemon ball throwing and stumbled upon these two tutorials. They gave me the last insight needed to finish the mechanic.

How to Add Force to Gameobject with Swipe to Throw It In 3D Android Unity Game? SImple Tutorial https://www.youtube.com/watch?v=7O9bAFyGvH8&t=1s

Pokemon Go Throwing Mechanic in Unity https://www.youtube.com/watch?v=eKhmcPa_Fjg&t=5s


Reflection

This week was, in contrary to the previous one, a really succesfull week. I managed to finish the throwing mechanic, as well as implementing the flower spawning. This means that all interactions are done for scene three, which in turn means that based on the art the scene can be finished soon.

Next to that we had a good meeting with our client regarding next week’s trip to Amsterdam and he was positive about my work this week.

Media & code

Showcasing seed collision in AR.
Showcasing the seed throwing mechanic and flower spawn.
Vector2 xyForceDirection = new Vector2(-direction.x, -direction.y);

                    Vector3 force = new Vector3(xyForceDirection.x * throwForceX, xyForceDirection.y * throwForceY, 0) +
                                Camera.main.transform.forward * (timeInterval * throwForceZ);

                    // Add force to objects rigidbody in 3D space depending on swipe time, direction and throw forces
                    rb.isKinematic = false;
                    rb.AddForce(-direction.x * throwForceXY, -direction.y * throwForceXY, throwForceZ / timeInterval);
                    rb.AddRelativeForce(force);1
  1. By removing the previous line and instead making the force relative, I achieved way better results. ↩︎

Week 6 – Physics are hard

MARCH 25 → MARCH 28 – 2024

Tasks

Technical Developments

  • Tried to implement a Pokémon like throw for the seeds
    • Struggled with using physics to create a trajectory for the seed.
    • Detecting swiping proved to be more difficult than expected.

Miscellaneous

  • Attended one Applied Research class
  • Procedural Art redo

Double Diamond

The whole week was spent on researching and developing a pokemon like throw to allow the player to throw and plant seeds. This proved to be more difficult than expected at first as I had never worked with physics like this before.

Discover

To discover what method to use and how to implement the throw, I conducted some research into the topic and found interesting tutorials. I also looked at Pokémon Go to see what they used there, as it was one of my main inspirations. (Research can be found below)

Define

The objective is to create a modular solution that detects a players swipe input and throws the seed accordingly. This is dependent on a few factors that are difficult to implement, mainly converting the 2D swipe to a 3D movement.

Develop

I started with following a tutorial that covered basic swipe detection, this was not very intuitive and so it took me longer than expected. After finalising the swipe detection for now I dove deeper into the throwable object and how to calculate it’s trajectory.

Deliver

The progress I had at the end of the week was not in a presentable state and honestly, still was not good enough or even close to my set target. However we did make a release on Github, where the art was combined with the latest stable version of the technical side.

Plan

Next week will revolve around finishing the seed throwing as well as implementing flower spawning. We will also have a meeting with our client to discuss details for an upcoming trip to Amsterdam (where our client’s client is based).


Research

As most of the week was spent on developing a solution for the seed throwing, that was also my main point of research this week.

Next to that I did some research into general detection of swipes in Unity, which I was also quite unfamiliar with.

Recreating Pokemon Go in Unity3D #9 Pokemon catching 1/2! https://www.youtube.com/watch?v=a4ts4dZ_12I

Recreating Pokemon Go’s camera in Unity3D #4 Pokeball throwing! https://www.youtube.com/watch?v=wavvtztVK3c

Unity3D Recreating Pokemon Go : Part 1 / The Basics https://www.youtube.com/watch?v=XH942mANiv4

Pokemon Go Throwing Mechanic in Unity https://www.youtube.com/watch?v=eKhmcPa_Fjg&t=5s

Unity Swipe Controls – Easy Tutorial https://www.youtube.com/watch?v=Pca9LMd8WsM


Reflection

At the end I am not too happy with the overall progress I made this week. It proved to be more than I could do, in hindsight I could have known as both physics and swipe detection are topics I am entirely unfamiliar with.

Hopefully I can manage to finish this early next week so that I can catch up on my other tasks.

Media & code

// Add force to objects rigidbody in 3D space depending on swipe time, direction and throw forces
                    rb.isKinematic = false;
                    rb.AddForce(-direction.x * throwForceXY, -direction.y * throwForceXY, throwForceZ / timeInterval);

Week 5 – Refactoring and other responsibilities

MARCH 18 → MARCH 21 – 2024

Tasks

Meetings

  • Meeting with Hester van der Ent
    • Catching up on our progress.
    • Discussing a previously brough up issue regarding copyright.
  • Meeting with Harry Sanderink
    • Catching up on our progress regarding our learning outcomes.

Technical Developments

  • Refactoring our codebase
    • Introduced a GameManager working with the GameScene created last week, this also included an active/inactive state to control whether or not to show the scene’s environment. (see code below)
    • Reviewing my previously written scripts to see if there is any space for improvements.
  • Managing version control
    • Merged two new branches made by Alejandra.
  • Designing a scalable system to allow multiple people to play simultaneously (see video below)
    • Person 1 can start at pillar A and continue in sequence ABCDE, while person 2 can start at C and continue in sequence CDEAB.
    • Allowing multiple people to play at the same time by customizing their starting pillar.

Miscellaneous

  • Attended the Reality Check Festival
  • Attended two Applied Research classes
  • Decided on a weekly stand-up with the team

Double Diamond

Most of this week was spent on improving existing scripts as well as removing unnecessary ones to replace them with a more flexible solution.

Define

The main issue that persisted from last week was the fact that it was really difficult to create content without it taking a long time. This could be prevented by offering a modular solution (like Scriptable Objects) to do most of the work and having it pass through the needed methods when necessary.

Develop

I continued where I left off last week and added another improvement to the GameScene script. From now on, the GameManager has the ability to see if a scene is already active, if it is, there is no need to go through the rest of the processing. This saves performance and makes it easier to track what scene is being played out.

Deliver

This prototype was not released anywhere as it has become clear that our client needs clear visuals to explain what is happening and I did not find that feasible for a technical solution like this.

Plan

For next week, my most important point is to finish the refactoring. After that I will start to work on the next interaction for our chosen scene: throwing flower seeds. I have never before worked with physics in Unity so I expect this to take more time than the previous interaction.


Research

After a suggestion from Alejandra, I did some research into rebasing for Git. Currently we are using a classic Pull Request > Review > Merge construction. However, it was suggested that rebasing can be used too. Ultimately we decided against it but it was interesting to note the various ways of achieving a solid grip on version control.

Rebasing and pull requests in comparison.

Reflection

While the refactoring takes a little longer than I had hoped, I am still satisfied with my current progress. Especially considering this week was full of distractions with Reality Check and Applied Research.

I did begin to see some possible issues with the client, as communication is not always smooth and there have been some instances where I felt we weren’t really listened too.

Media & code

public void StartGame()
    {
        SetPlayerIndex(playerIndexDropdown.value);

        Destroy(mainMenuUI);

        SetSpawnablePrefabs();

        imageTracking.SetSpawnablePrefabs();
    }

    public void SetActiveScene(GameObject scenePrefab)
    {
        foreach(GameScene scene in modifiableScenes)
        {
            SceneState.State state = scene.sceneState.state;

            if (scenePrefab.name == scene.sceneEnvironmentPrefab.name)
            {
                if(scene.sceneState.state == SceneState.State.Active)
                {
                    break;
                }

                scene.sceneState.state = SceneState.State.Active;

                Debug.Log(scene.sceneName + scene.sceneIndex + " state was changed from " + state + " to " + scene.sceneState.state);
            }
            else
            {
                if(scene.sceneState.state is SceneState.State.Active)
                {
                    scene.sceneState.state = SceneState.State.Inactive;

                    Debug.Log(scene.sceneName + scene.sceneIndex + " state was changed from " + state + " to " + scene.sceneState.state);
                }
            }
        }
    }1public void StartGame()
    {
        SetPlayerIndex(playerIndexDropdown.value);

        Destroy(mainMenuUI);

        SetSpawnablePrefabs();

        imageTracking.SetSpawnablePrefabs();
    }

    public void SetActiveScene(GameObject scenePrefab)
    {
        foreach(GameScene scene in modifiableScenes)
        {
            SceneState.State state = scene.sceneState.state;

            if (scenePrefab.name == scene.sceneEnvironmentPrefab.name)
            {
                if(scene.sceneState.state == SceneState.State.Active)
                {
                    break;
                }

                scene.sceneState.state = SceneState.State.Active;

                Debug.Log(scene.sceneName + scene.sceneIndex + " state was changed from " + state + " to " + scene.sceneState.state);
            }
            else
            {
                if(scene.sceneState.state is SceneState.State.Active)
                {
                    scene.sceneState.state = SceneState.State.Inactive;

                    Debug.Log(scene.sceneName + scene.sceneIndex + " state was changed from " + state + " to " + scene.sceneState.state);
                }
            }
        }
    }
  1. GameManager script ↩︎

Week 4 – Interaction and refactoring for scalability

MARCH 11 → MARCH 14 – 2024

Tasks

Technical Developments

  • Setting up interaction (see video below)
    • We decided to start with scene three as it was most interaction heavy so we wanted to get that out of the way while also having our setup fit a scene like this.
    • Added a ‘Trash’ class that is tagged as an Interactable and can be clicked. After which the InputManager handles the further proceedings.
    • Added a custom score per ‘Trash’ object. This is to ensure it can be used for the actual implementation later on.
    • Implemented dummy objects from a Synty asset pack to function as trash until an artist makes the actual models.
  • Starting refactoring process
    • Began with the foundation, creating a Scriptable Object pipeline.
      • The first scriptable object, GameScene, holds all necessary data per scene. Such as name, index, referenced object and a method for cloning. (code below)
      • Figured out I had to clone the scenes as to not change them permanently from code. As they are Scriptable Objects.

Miscellaneous

  • Driving exam (I passed yay)

Double Diamond

During this week I mainly focused on the interaction and started researching and planning the refactoring towards the end of the week.

Discover

Researched good solutions for my scalability problem while still being able to develop for Android and keeping the project clean and transparent.

Define

After gathering all the facts I decided to work with a Scriptable Object solution that would hold all data per scene. This would then be read by the needed scripts (mainly the GameManager) to process its data and work with the scenes as intended. This ensures scalability and ease of use as Scriptable Objects work wonders for setting up a small project like this.

Develop

Created the first working prototype that does as described above, the models are placed according to the images detected. This also works in real life but we don’t have access to a phone capable of AR at this moment in time.

Finished a simple prototype that includes interaction at the beginning of the week and later merged it with Emma’s (artist) work, to have it be more of a forest environment. This prototype implemented an InputManager handling the clicking of Interactable objects by accessing their scripts to call the needed method.

Deliver

This prototype was not posted as a release on Github but was instead sent to our client in video format. After which he provided feedback.

Plan

Next week’s plan is to further lay out the foundation of a scalable and performant framework. Based on Scriptable Objects and script inheritation. This should hopefully not take more than a week and in return, provide me with a solid base on which I can then more easily add features and improvements.

There will also be a Reality Check Festival, which is a festival hosted by our studies which we will all attend.


Research

The research conducted this week mainly revolved around trying to find a good solution for our scalability issues. Everything I found pointed towards using Scriptable Objects and while I do have experience with those already, I still decided to do some more digging into the subject.


Reflection

This fourth week started really well, I managed to implement the interaction quite quickly and it immediately was in a solid state.

Unfortunately I also learned the repercussions of not setting up the project in a scalable manner and found that I now had to work on refactoring and starting (almost) from scratch again to allow the project to remain possible in a clean manner. This was a major learning point for me and in hindsight, I am glad that it happened here.

Media & code

First iteration of the interaction system working.
Combining Emma’s work with my interaction.
[Serializable]
[CreateAssetMenu(fileName = "New Scene", menuName = "Eden/Scene", order = 1)]
public class GameScene : ScriptableObject
{
    public string sceneName;
    public int sceneIndex;

    public GameObject sceneUIPrefab;
    public GameObject sceneEnvironmentPrefab;
    public SceneState sceneState;

    public List<GameSceneAdditionalObject> additionalObjects;

    public GameScene Clone()
    {
        GameScene clone = ScriptableObject.CreateInstance<GameScene>();
        clone.name = sceneName;
        clone.sceneName = this.sceneName;
        clone.sceneIndex = this.sceneIndex;
        clone.sceneUIPrefab = this.sceneUIPrefab;
        clone.sceneEnvironmentPrefab = this.sceneEnvironmentPrefab;
        clone.sceneState = new SceneState { state = this.sceneState.state };
        clone.additionalObjects = this.additionalObjects;
        return clone;
    }
}

[Serializable]
public class SceneState
{
    public State state;

    public enum State
    {
        Active,
        Inactive,
        Hidden
    }
}

Week 3 – Improving tracking and research

MARCH 4 → MARCH 7 – 2024

Tasks

Client Meetings

  • Meeting with our client on Monday
    • Presenting him with a new feature

Technical Developments

  • Implementing custom panel per client’s request (see video below)
    • Allowing user to control scale and vertical offset from the marker
    • Received positive feedback from the client
  • Second prototype (multiple markers and moving models, see video below)
    • Implementing multiple marker tracking
    • Implementing a constantly moving object to showcase spatial capabilities. (code below)

Miscellaneous

  • Catching up on weekly blogs.

Double Diamond

This week was primarily focused on further developing the first prototype by adding in several new features such as moving objects, multiple object tracking and modifying their scale and offset.

At the end of the week I also researched Geo Location to see if that was feasible for our project.

Discover

Did research into Geo Location and modifying instantiated models that follow the marker. This was necessary to fullfil the client’s request.

Geo Location looked like a solid solution for our project as we could set a ‘hard’ location for the markers and would therefor not need the images anymore.

Define

Eventually research showed that Geo Location was not feasible due to the precision that is necessary for it to work on small distances, something that is simply not possible at this moment in time.

I decided on a simple (dirty) method of implementing the features requested by the client. This ultimately would not lead to scalability and would have to be redone later, but for now it showcased the AR capability quite well.

Develop

Further advanced the first prototype as described above. Now including a changeable scale and offset, offering multiple markers being tracked as well as showcasing the spatial capabilities.

Deliver

The prototype was posted as a release on our GitHub. It contains all features mentioned previously.

Plan

Next week’s plan is to work on basic interaction, first of which will be ‘trash picking’. This should simply be basic shapes that can be clicked to see them be collected and award a score.


Research

This week I did some research into Geo Location, but ultimately decided it was not feasible.


Reflection

This third week went by in rapid fashion, I am very happy with the progress I made and managing to add all requested features quite quickly.

I have started to notice that the way the project is currently set up is not scalable at all and will need some rework done. Sooner rather than later.

Media & code

Showing the testpanel capabilities, modifying scale and offset.
Showcasing multiple models being tracked on screen.
Adding constant movement and rotation to a sample object.
protected void FixedUpdate()
    {
        float verticalMovement = Mathf.Sin(Time.time * 1f) / moveSpeed;
        float rotation = Time.time * rotationSpeed;

        Transform child = transform.GetChild(0).transform;

        child.localPosition = new Vector3(0, verticalMovement, 0);
        child.localRotation = Quaternion.Euler(0, rotation, 0);
    }

Week 2 – Learning goals and first prototype

FEBRUARY 26 → MARCH 1 – 2024

Tasks

Client Meetings

  • Meeting with our client on Monday
    • Learning about the Museum’s setup.
    • Learning about the pre-made script, concept and characters.
    • Another studio is developing the interaction.
    • Minor issues
      • Primarily related to proper roles and missing knowledge the client had of our studies.
    • Identifying the client’s goals; Teamwork, stepping out of our comfort zone and creating something new.
  • Meeting with our client on Friday
    • Agreed upon a direction for the project
    • Presented my first prototype for feedback

Technical Developments

  • Setting up Git
    • Set up protected branches to ensure safe use of version control.
    • Inviting all members and explaining the way of working with git.
      • Pull Request > Review > Merge with develop
  • First prototype (see video below)
    • Learning about Unity AR Foundation
    • Custom images for markers
    • Image tracking for markers

Miscellaneous

  • Writing up my learning goals by finding a balance between personal and client goals.

Double Diamond

This week was primarily focused on the development of our first prototype in Unity. For this I needed to do some research.

Discover

Did research into a feasible AR framework to use, this had to take into account several factors such as: a young audience, scalability, reliability and performance.

Define

Combining all these factors lead me to the use of image tracking, the so-called process where images (markers) are used to identify locations where an object can be placed. This ensures scalability, takes into account that a young audience can use it as it is very visible and easy to distinguish, and it is not too performance heavy, which is necessary for developing for tablets.

Develop

Created the first working prototype that does as described above, the models are placed according to the images detected. This also works in real life but we don’t have access to a phone capable of AR at this moment in time.

Deliver

The prototype was posted as a release on our GitHub. It contains a basic form of image tracking and shows a solid base for the rest of this project.

Plan

For the next week the plan is to implement a panel with rescaling and repositioning capabilities as well as getting our hands on an AR capable device as soon as possible to test the prototype. As well as generally advancing the prototype and improving it.


Research

During this week I mainly did research into AR development within Unity. For the development I used some tutorials to gain more insight into specific features.


Reflection

The second week went by quickly as I was very focused on the first prototype. I managed to get quite some things done and learned a lot about development in AR already. The client was happy with my progress and the teams as well so I can only be satisfied with this week.

Media

Initial prototype that shows objects being placed on corresponding images in a simulated AR environment.

Week 1 – Getting to know the project

FEBRUARY 12 → MARCH 15 – 2024


Tasks

  • Attending the project introduction
    • Filling in survey to form studios and generate project leads.
    • Assigning studio members to projects.
  • Preparing for project briefing
    • Researching the Golden Rule.
    • Researching previous Abner Preis Studios projects.
  • Attending the introductory meeting for our project
    • Meeting Abner Preis (our client).
    • Noting down important parts of the vision for the project.

Double Diamond

As we will be working in sprints and my role will mostly be a technical developer, more so than a designer, I have decided to use the following agile development framework.

Discover

Define

Develop

Deliver


Research

During this first starting week, we did research into the golden rule as well as projects previously made by our client to gain some insight.


Reflection

The first week was a slow start but definitely sparked some interest in each of us and we are eager to get to our hands dirty in the coming weeks.