Lighting in 2D games can be achieved by different means. In Unity you can find nice assets in the asset store or use the 3D classic lights by changing your sprite shader from default to diffuse. What I want to achieve here is a very simple light effect by addding a sprite mask on top of my scene and modify the resulting color in a shader to emulate light like the image below:
If you need to calculate the trajectory of a projectile launched by your character or by a NPC, or if you need to find the velocity you need to apply to your character to make him jump to a specific point in your 2D Unity game and you don't know anything about it, this article is for you!
With Unity4 came a nice feature : Property drawers.
They allow you to customize the appearance and behavior of your class property and thus create a nice and robust interface in Unity's editor.
One thing I needed when coding my classes was the ability to show a basic popup select list. It allowed me to choose the right behavior for the gameObject depending on this particular field value.
After fighting with Unity's mouse detection functions I decided it was time to implement a better mouse management class that works with 2D projects.