修改水
This commit is contained in:
@@ -1,34 +0,0 @@
|
||||
using UnityEngine;
|
||||
|
||||
namespace Obi.Samples
|
||||
{
|
||||
public class TangledPegSlot : MonoBehaviour
|
||||
{
|
||||
public TangledPeg currentPeg;
|
||||
public Color tintColor;
|
||||
|
||||
private Material instance;
|
||||
private Color normalColor;
|
||||
|
||||
public void Awake()
|
||||
{
|
||||
instance = GetComponent<Renderer>().material;
|
||||
normalColor = instance.color;
|
||||
}
|
||||
|
||||
public void Tint()
|
||||
{
|
||||
instance.color = tintColor;
|
||||
}
|
||||
|
||||
public void ResetColor()
|
||||
{
|
||||
instance.color = normalColor;
|
||||
}
|
||||
|
||||
public void OnDestroy()
|
||||
{
|
||||
Destroy(instance);
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user