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);