Skip to content

Instantly share code, notes, and snippets.

@ikoan310
Created October 11, 2018 06:40
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ikoan310/2a0395b1982ff2b75c1b19507f65d908 to your computer and use it in GitHub Desktop.
Save ikoan310/2a0395b1982ff2b75c1b19507f65d908 to your computer and use it in GitHub Desktop.
ParticleSystem.Emitを使って、パーティクルを放出する際に、放出位置をプログラムから指定したい場合、ParticleSystemのtransformのpositionを変更するだけではいけないっぽい。
ParticleSystem.EmitParams emitParams = new ParticleSystem.EmitParams();
emitParams.position = "放出させたいワールド座標";
emitParams.applyShapeToPosition = true;
particleSystem.Emit(emitParams, 50);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment