Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/scriptsengineer/openknife

Game made in unity for a jam, using the best software engineering approaches.
https://github.com/scriptsengineer/openknife

game jam mobile unity

Last synced: 3 months ago
JSON representation

Game made in unity for a jam, using the best software engineering approaches.

Awesome Lists containing this project

README

        

# Welcome to Open Knife 👋 [🇧🇷](https://github.com/ScriptsEngineer/OpenKnife/wiki/README_PT_BR)
![Version](https://img.shields.io/badge/version-0.2.5-blue.svg?cacheSeconds=2592000&style=flat-square)
[![Documentation](https://img.shields.io/badge/Documentation-yes-brightgreen.svg?&style=flat-square)](todo-doc)
[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg?&style=flat-square)](MIT)
[![Twitter: ScriptsEngineer](https://img.shields.io/twitter/follow/ScriptsEngineer.svg?style=flat-square)](https://twitter.com/ScriptsEngineer)
![GitHub issues](https://img.shields.io/github/issues/scriptsengineer/openknife?style=flat-square)
![GitHub closed issues](https://img.shields.io/github/issues-closed-raw/scriptsengineer/openknife?style=flat-square)
![GitHub language count](https://img.shields.io/github/languages/count/scriptsengineer/openknife?style=flat-square)

## 🔨 Features

✔ī¸ Just a scene to make it easier to loading on your phone.

✔ī¸ Use of 3 game states (Menu, InGame, GameOver)

✔ī¸ _GameManager_ is a **singleton** with all managers instantiated using interface.
```csharp
GameStates[] internStates = GetComponents();
gameStates.AddRange(internStates);

```
✔ī¸ _UnityEvents_ for easy use of designers in the editor *Unity*.

✔ī¸ Design with split structure with [Assembly Definitions](https://docs.unity3d.com/Manual/ScriptCompilationAssemblyDefinitionFiles.html), helping in times of smaller compilations, obliging the use of [SOLID](https://en.wikipedia.org/wiki/SOLID_(object-oriented_design)) and split of tests.

✔ī¸ Full separation of game logic with UI, nothing depends on the user interface and its logic.

✔ī¸ Use [URP](https://github.com/Unity-Technologies/Graphics/tree/7.x.x/release/com.unity.render-pipelines.universal) with quick and easy rendering for mobile platform.

✔ī¸ Simple UI animations using triggers.

✔ī¸ Boss mode [Pull Request #7](https://github.com/ScriptsEngineer/OpenKnife/pull/7).

✔ī¸ Use of [Test Framework](https://docs.unity3d.com/Packages/[email protected]/manual/index.html) for procedure testing.
- Runtime tests.
- Editor tests.

## Managers
Certain managers have been created to use logic and data easily and cleanly.

🚨 _GameManager_: A class **singleton**. with game states, It is important to note here the use of an interface for all components that want to receive event notifications from the game states.

🚨 _LevelManager_: Obviously responsible for the stages and their shipments.

🚨 _UIManager_: In addition to being the parent of the entire User Interface, it stores _Canvas_ as well.

## Actors

⛹ī¸ Player with _Shooter_,_Scorer_

⛹ī¸ Wood with _Rotator_,_CurveRotator_

⛹ī¸ Knife with _Knife_,_RigidBody2D_

⛹ī¸ Fruit with _Rigidbody2D_

## Stages

✔ī¸ _ScriptableObjects_ to separate data from scenes.

✔ī¸ _AnimationCurves_ for time interpolation of wood speed.

✔ī¸ _AngleObject_ is a list that keeps object items with an angle.

## 📈 Challenges

### Physics or Triggers?
One of the biggest problems seen in this production was the doubt that one should use physics or not. Problems using Unity physics can be seen here:

![Physic problem](https://github.com/ScriptsEngineer/OpenKnife/blob/main/Docs/Images/GxxPtxn8Cu.gif)

### Where the stage ❓

For a designer it is very easy to just edit a file, in this way it was used the
[_ScriptableObject_](https://docs.unity3d.com/Manual/class-ScriptableObject.html).

![Stage Object](https://github.com/ScriptsEngineer/OpenKnife/blob/main/Docs/Images/Code_rDrUJHE2CC.png)

### 👨‍đŸ’ģ Shouldn't a designer use a code editor ?

Obviously a designer who wants to exchange an effect sound or choose when to instantiate a particle in the scene should create easily and quickly, so 'UnityEvent' was used extensively.

![UnityEvents](https://github.com/ScriptsEngineer/OpenKnife/blob/main/Docs/Images/Unity_tZZV1mtPlL.png)

## Assembly Definition Use

Use of assembly packages for each namespace of the project, thus dividing the use of resources helping in the use of tests.

## Production time
⏰ 12 hours

## Author

👤 **Rafael Correa**
(Script)
* Twitter: [@ScriptsEngineer](https://twitter.com/ScriptsEngineer)
* Github: [@scriptsengineer](https://github.com/scriptsengineer)

## 🤝 Contributing

Contributions, issues and feature requests are welcome!

Feel free to check [issues page](https://github.com/ExpressoBits/EBConsole/issues).

## Show your support

Give a ⭐ī¸ if this project helped you!

## Assets used

🎨 [FREE Casual Game SFX Pack](https://assetstore.unity.com/packages/audio/sound-fx/free-casual-game-sfx-pack-54116)

🎨 [20 Evolving Fantasy RPG Weapons](https://assetstore.unity.com/packages/2d/textures-materials/20-evolving-fantasy-rpg-weapons-61204)

🎨 [Free Pixel Font - Thaleah](https://assetstore.unity.com/packages/2d/fonts/free-pixel-font-thaleah-140059)

🎨 [Free Pixel Food](https://assetstore.unity.com/packages/2d/environments/free-pixel-food-113523)

## 📝 License

This project is [MIT](MIT) licensed.