This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| timer0 = Timer.New() | |
| Controls.OFF.EventHandler = function (valueChange) | |
| if (Controls.OFF.Boolean) then | |
| Controls.OFF.Color = "#F00" | |
| timer0:Stop() | |
| --Controls['Peak Out'].RampTime = 0.3 | |
| Controls['Peak Out'].Value = -100 | |
| --Controls['RMS Out'].RampTime = 1 | |
| Controls['RMS Out'].Value = -100 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| using System.Collections; | |
| using UnityEngine; | |
| public static class Fade | |
| { | |
| public static IEnumerator In (AudioSource audioSource, float fadeTime) | |
| { | |
| const float startTime = 0f; | |
| var currentTime = 0f; | |
| audioSource.Play(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // LinearDecibelConverter.cs | |
| // Author: Made Indrayana | |
| // MIT License | |
| // Small utilities to convert Linear value (0-1) to dB and vice versa | |
| public class LinearDecibelConverter | |
| { | |
| public float LinearToDecibel(float linear) | |
| { | |
| float dB; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // main.cpp | |
| // Reference and Co. | |
| // Author: Made Indrayana | |
| // MIT License | |
| // This program is created to display the usage of pass-by-value, pass-by-reference and pointer in C++. | |
| #include <iostream> | |
| using namespace std; | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // MonoBehaviour Singleton Template | |
| // Author: Made Indrayana | |
| // MIT License | |
| using UnityEngine; | |
| public class Singleton<T> : MonoBehaviour | |
| where T : Component | |
| { | |
| public static T Instance { get; private set; } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Google Resonance Audio Location Bug Fix | |
| // Author: Made Indrayana | |
| // MIT License | |
| // Location fix by forcing an AudioSource to continually stop and play to force localization update on Google Resonance | |
| // Use a 100ms empty WAV | |
| public class ResonanceLocationBugFix : MonoBehaviour | |
| { | |
| [SerializeField] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| using System.Collections; | |
| using System.Collections.Generic; | |
| using UnityEngine; | |
| public class IEnumTest : MonoBehaviour | |
| { | |
| public bool isTracking = false; | |
| // Trigger to start, can be whatever | |
| void Start() |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // FMOD Output Setter - Editor script | |
| // Author: Made Indrayana | |
| // MIT License | |
| // Create a window in Unity to be able to explicitly select FMOD's audio output and auto enable it on every Play Mode. | |
| using System; | |
| using System.Collections.Generic; | |
| using UnityEngine; | |
| using UnityEditor; | |
| using FMODUnity; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Copyright 2017 Google Inc. All rights reserved. | |
| // | |
| // Licensed under the Apache License, Version 2.0 (the "License"); | |
| // you may not use this file except in compliance with the License. | |
| // You may obtain a copy of the License at | |
| // | |
| // http://www.apache.org/licenses/LICENSE-2.0 | |
| // | |
| // Unless required by applicable law or agreed to in writing, software | |
| // distributed under the License is distributed on an "AS IS" BASIS, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // FMOD Crash Course for Programmer | |
| // written by Made Indrayana | |
| // MIT License | |
| using UnityEngine; | |
| public class FMODCrashCourse : MonoBehaviour | |
| { | |
| // String as reference with FMOD Picker | |
| [FMODUnity.EventRef] public string eventName; |
NewerOlder