Skip to content

Instantly share code, notes, and snippets.

@anchan828
Created March 13, 2012 10:53
Show Gist options
  • Save anchan828/2028108 to your computer and use it in GitHub Desktop.
Save anchan828/2028108 to your computer and use it in GitHub Desktop.
using UnityEngine;
using System.Collections;
public class Example : MonoBehaviour
{
long time = 5000;
void Start ()
{
AndroidJNI.AttachCurrentThread ();
AndroidJavaObject clazz = new AndroidJavaObject ("android.os.Vibrator");
clazz.Call ("vibrate", new object[]{time});
}
void DontCallMethod ()
{
Handheld.Vibrate ();
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment