Skip to content

IvanMurzak/Unity-Mouse-Parallax

Repository files navigation

Unity-Mouse-Parallax

npm License Stand With Ukraine

Unity Parallax based on mouse input. Alternative version to Unity-Gyroscope-Parallax.

Features

  • ✔️ support legacy Input System
  • ✔️ support new Input System
  • ✔️ move/rotate objects based on mouse input
  • ✔️ ability to add custom controllers

Short Demo

Full demo video
Unity_93T6QlZNhC.mp4

MouseMover2D

Moves list of objects using mouse input.

Unity_2OiBF8IwNI

MouseRotator2D

Rotates list of objects using mouse input.

Unity_uWbnrUEaR2

How to install - Option 1 (RECOMMENDED)

  • Install OpenUPM-CLI
  • Open command line in Unity project folder
  • openupm --registry https://registry.npmjs.org add extensions.unity.mouse.parallax

How to install - Option 2

  • Add this code to /Packages/manifest.json
{ "dependencies": { "extensions.unity.mouse.parallax": "1.0.3", }, "scopedRegistries": [ { "name": "Unity Extensions", "url": "https://registry.npmjs.org", "scopes": [ "extensions.unity" ] }, { "name": "NPM", "url": "https://registry.npmjs.org", "scopes": [ "com.cysharp", "com.neuecc" ] } ] }

How to use

  • add needed Mouse...2D component to any GameObject
  • link Targets to list of targets
  • press 'Play' button in Unity Editor

Sponsor this project