Question by
kwalt95 · Apr 19, 2019 at 03:35 AM ·
scripting problemportalportals
What is wrong with my 2D portal code?
I'm new to Unity and I'm trying to implement a portal system to a 2D game. I want the player to teleport upon collision with the portal while pressing the "Fire2" button. Currently, the player teleports immediately upon hitting the portal's collision box without pressing the Fire2 button. What am I doing wrong? I've posted a link to an image of my code below. https://gyazo.com/ef84c23310702ef1d4a9e5553df52c3d
Comment
Your answer
Follow this Question
Related Questions
Scripting Portal 0 Answers
How to create a portal/teleport. 2 Answers
How to make VR Seamless Portals 0 Answers
Occlusion Portals Not Working in 5.5.0f3 0 Answers
Rendering portal like in Portal 2 0 Answers