47 lines
1.2 KiB
C#
47 lines
1.2 KiB
C#
using System;
|
|
using System.Collections;
|
|
using System.Collections.Generic;
|
|
using DefaultNamespace;
|
|
using DefaultNamespace.ProcessMode;
|
|
using MotionFramework;
|
|
using TMPro;
|
|
using UnityEngine;
|
|
|
|
public class CompleteOverComponent : MonoBehaviour
|
|
{
|
|
|
|
public GameObject overGame;
|
|
public TMP_Text text;
|
|
void Start()
|
|
{
|
|
MotionEngine.GetModule<AnimationProcessManager>().OnCompleteEvent += CompleteEvent;
|
|
|
|
}
|
|
|
|
private void CompleteEvent(int score)
|
|
{
|
|
overGame.SetActive(true);
|
|
|
|
switch (MotionEngine.GetModule<DataConfigManager>().GetProcessMode())
|
|
{
|
|
case ProcessMode.Teaching:
|
|
text.text = "本次教学实训总分:" + score.ToString();
|
|
break;
|
|
case ProcessMode.Training:
|
|
text.text = "本次培训实训总分:" + score.ToString();
|
|
break;
|
|
case ProcessMode.Practice:
|
|
text.text = "本次练习实训总分:" + score.ToString();
|
|
break;
|
|
case ProcessMode.Assessment:
|
|
text.text = "本次考核模式总分:" + score.ToString();
|
|
break;
|
|
default:
|
|
throw new ArgumentOutOfRangeException();
|
|
}
|
|
|
|
|
|
}
|
|
|
|
}
|