void UpdateUI(BindKey bindKey) { if (bindKey.beatObjectData != null) { string str = bindKey.beatObjectData.objectTag.ToString(); _objectTagText.text = LevelDataManager.PropertyNameToString(bindKey.beatObjectData.objectTag); } if (bindKey.key != KeyCode.None) { _text.text = bindKey.key.ToString(); } }
public void KeyBind(int layer, KeyCode key) { if (_bind.ContainsKey(layer)) { BindKey bindKey = _bind[layer]; bindKey.key = key; _bind[layer] = bindKey; } else { _bind.Add(layer, new BindKey { key = key, beatObjectData = null }); } }
public void ObjectBind(int layer, BeatObjectData beatObjectData) { if (_bind.ContainsKey(layer)) { if (ObjectProperties.instance.selectedObject != null && ObjectProperties.instance.selectedObject.id == _bind[layer].beatObjectData.id) { ObjectProperties.instance.WipeSelections(); } BindKey bindKey = _bind[layer]; bindKey.beatObjectData = beatObjectData; _bind[layer] = bindKey; } else { _bind.Add(layer, new BindKey { key = KeyCode.None, beatObjectData = beatObjectData }); } }