hiyorin / SystemVolumePlugin-for-Unity

A set of tools for Unity to allow handling system volume for Android and iOS.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

SystemVolumePlugin-for-Unity

A set of tools for Unity to allow handling system volume for Android and iOS.

Install

SystemVolumePlugin-for-Unity.unitypackage

Usage

using SystemVolume;

Example: Get/Set

public void Example()
{
  var controller = new SystemVolumeController();
  controller.Volume = 0.5f;
  Debug.Log(controller.Volume);
}

Example: Callback when the volume buttons is pressed

public void Example()
{
  var controller = new SystemVolumeController();
  controller.OnChangeVolume = volume => {
    Debug.Log(volume);
  };
}

About

A set of tools for Unity to allow handling system volume for Android and iOS.

License:MIT License


Languages

Language:C# 62.8%Language:Java 19.3%Language:Objective-C 14.1%Language:Objective-C++ 3.9%