Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. We have updated the language to the Editor Terms based on feedback from our employees and community. Learn more.
    Dismiss Notice
  3. Join us on November 16th, 2023, between 1 pm and 9 pm CET for Ask the Experts Online on Discord and on Unity Discussions.
    Dismiss Notice

Help with Pointer Events 2D Game

Discussion in 'Scripting' started by mikkel1156, Nov 6, 2015.

  1. mikkel1156

    mikkel1156

    Joined:
    Oct 29, 2015
    Posts:
    2
    So i'm working on a 2D platformer, but got a problem with the mobile controls, i'm using the OnPointerUp and OnPointerDown evnts, but the player won't jump and walk at the same time, so my question is, is there a way to have the two events run at the same time? Right now i got scripts for every button with the event handler. Thanks.
     
  2. Okto247

    Okto247

    Joined:
    Jun 26, 2015
    Posts:
    7
  3. mikkel1156

    mikkel1156

    Joined:
    Oct 29, 2015
    Posts:
    2
    I looked at this and its not what i'm looking for, i think i have a solid understanding about how the functions end and the other functions. My problem is that when i press down the Ex. walk left key on my UI and while still walking hit the jump button it does nothing, i'm trying to find a solution to this problem, any suggestions would be great.