Jump to content
Android Forum - A Community For Android Users and Enthusiasts

[libgdx]implement new parameters for the touchDown() function


Recommended Posts

Hi there,            

 

I would like to launch an sql request when we press a button :

 

public boolean touchDown (InputEvent event, float x, float y, int pointer, int button) {
           
        db = new Database();
            scores = db.UpdateScore(entryId, types[type]);                 return true;
                
            }

I need to pass these 2 parameters "int entryId" and "int type" inside the listener.

 

I tryied this :

public boolean touchDown (InputEvent event, float x, float y, int pointer, int button, int entryId, int type)

 

but the problème is that the touchDown function is a native function and then I can't add extra params.

 

Could someone please help ? thanks :)
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

×
×
  • Create New...