2021-02-22 18:43:17 +00:00
|
|
|
|
using UnityEngine;
|
2020-05-31 17:07:22 +00:00
|
|
|
|
|
2019-07-05 22:52:22 +00:00
|
|
|
|
namespace SanAndreasUnity.Behaviours
|
2020-05-31 17:07:22 +00:00
|
|
|
|
{
|
|
|
|
|
|
2019-07-05 22:52:22 +00:00
|
|
|
|
public class CharacterModelChanger : MonoBehaviour
|
2020-05-31 17:07:22 +00:00
|
|
|
|
{
|
2019-07-05 22:52:22 +00:00
|
|
|
|
public KeyCode actionKey = KeyCode.P;
|
2020-05-31 17:07:22 +00:00
|
|
|
|
|
|
|
|
|
|
2019-07-05 22:52:22 +00:00
|
|
|
|
private void Update()
|
2020-05-31 17:07:22 +00:00
|
|
|
|
{
|
2020-04-20 20:31:56 +00:00
|
|
|
|
if (Input.GetKeyDown(actionKey) && GameManager.CanPlayerReadInput())
|
2019-07-05 22:52:22 +00:00
|
|
|
|
{
|
2021-02-22 18:43:17 +00:00
|
|
|
|
if (Ped.Instance != null)
|
|
|
|
|
{
|
|
|
|
|
Chat.ChatManager.SendChatMessageToAllPlayersAsLocalPlayer("/skin");
|
|
|
|
|
}
|
2019-07-05 22:52:22 +00:00
|
|
|
|
}
|
2020-05-31 17:07:22 +00:00
|
|
|
|
}
|
|
|
|
|
}
|
2019-07-05 22:52:22 +00:00
|
|
|
|
|
|
|
|
|
}
|