Question by
dynamoo21 · Jan 13, 2016 at 09:43 AM ·
unity 5camerainstantiatescreenparticleeffect
Instantiate Object in camera View
Expected Behavior: particle Effects to occur where I Click on the Screen
What's Happening: Effects on the pixel position and they are out of camera view.
Vector3 here;
public Gameobject Effects;
void Update(){
if (Input.GetKey(KeyCode.Mouse0)) {
here=Input.mousePosition;
Instantiate(Effects,here,Quaternion.identity);
}
}
Comment
Your answer
Follow this Question
Related Questions
Set screen resolution not working with C# 0 Answers
SPACE SHOOTER SHOOTING SHOTS TUTORIAL HELP (UNITY 5 C#) 3 Answers
Destroy an INDIVIDUAL instantiated object 0 Answers
how to make forward relative to the view of the camera 0 Answers
Navigation in VR Mode?!! 0 Answers