playMaker

Author Topic: how to click on text  (Read 2099 times)

9TOFRIDAY

  • Playmaker Newbie
  • *
  • Posts: 39
how to click on text
« on: May 20, 2015, 09:31:05 AM »
Hey peeps

i have a game where i mix up words and out put the value to text objects. can i have direct interaction on them or must it be a fake button?

the problem is that i want the touch to happen immediately not when the button is released.

help anyone please
« Last Edit: May 20, 2015, 09:43:33 AM by 9TOFRIDAY »

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: how to click on text
« Reply #1 on: May 21, 2015, 04:46:33 AM »
Hi,

 the uGui package from PlayMaker has a proxy for raw pointers, it works on ALL UI components.

1: drop the "PlayMaker  Ugui" prefab in the scene
2: drop the "PlayMakerUGuiPointerEventsProxy" onto the Text GameObject
3: have an fsm on the text GameObject wich implements the event "UGUI / ON POINTER DOWN" ( you'll see the proxy warning if it did not find implementations)

and then you'll get that event sent everytime the use mouse down ( or touch ) the text

Tell me if you have problem implementing this, I'll do a sample if necessary. but before that, make sure you go over all the existing samples available on the Ecosystem, they use this proxy ( on the drag sample for sure).

Bye,

 Jean

9TOFRIDAY

  • Playmaker Newbie
  • *
  • Posts: 39
Re: how to click on text
« Reply #2 on: June 02, 2015, 04:45:02 AM »
Hi,

 the uGui package from PlayMaker has a proxy for raw pointers, it works on ALL UI components.

1: drop the "PlayMaker  Ugui" prefab in the scene
2: drop the "PlayMakerUGuiPointerEventsProxy" onto the Text GameObject
3: have an fsm on the text GameObject wich implements the event "UGUI / ON POINTER DOWN" ( you'll see the proxy warning if it did not find implementations)

and then you'll get that event sent everytime the use mouse down ( or touch ) the text

Tell me if you have problem implementing this, I'll do a sample if necessary. but before that, make sure you go over all the existing samples available on the Ecosystem, they use this proxy ( on the drag sample for sure).

Bye,

 Jean

Thank for getting back to me.
I'm sorry for replying so late i just saw this.
when i get a chance i will check, thank you so much