效果预览:
花海(带移动方向)
VFX 实例
脚本示例 使用TouchScript,计算玩家是否移动,且计算移动方向
using System.Collections;
using System.Collections.Generic;
using TouchScript;
using TouchScript.Pointers;
using UnityEngine;
using UnityEngine.VFX;public class UpdateTouchsParticle : MonoBehaviour
{public GameObject ParticlePrefab;Dictionary<Pointer, GameObject> ParticleDic;void Awake(){//Application.targetFrameRate = 30;}private void OnEnable(){ParticleDic = new Dictionary<Pointer, GameObject>();if (TouchManager.Instance