playMaker

Author Topic: Problem adding 'PlayMakerUGuiDragEventsProxy' during run-time [SOVLED]  (Read 946 times)

omgitstri

  • Playmaker Newbie
  • *
  • Posts: 46
    • View Profile
    • My Prototypes
Hello,

I am currently messing around with Playmaker Template and I am trying to create a small drag & drop inventory system. I try to make it so I'd use the action 'Add Component' at the beginning of the template to make it so things would work with just the template alone and not having to worry about adding the required components each time I want to recycle the template.

The problem I'm running to right now is that the 'PlayMakerUGuiDragEventsProxy.cs' does not work very well during run-time. I add the component to the GameObject but the script does not work until I select the GameObject in the Hierarchy.

I tried [Adding the component] > [Deactivate GameObject] > [Activate GameObject] but that did not seems to help

I ran a few other tests with playmaker UGui scripts and I manage to get components like 'PlayMakerUGuiCanvasRaycastFilterEventsProxy.cs' to be added during run-time.

Tri Nguyen
« Last Edit: October 02, 2017, 07:03:07 AM by djaydino »
Tri Nguyen
Game Designer at Nvizzio Creations

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15082
  • Official Playmaker Support
    • View Profile
Re: Problem adding 'PlayMakerUGuiDragEventsProxy' during run-time
« Reply #1 on: June 01, 2017, 01:24:43 AM »
Hi,

 indeed these proxies where not design to be added at runtime.

I checked and there is a way for me to create actions for each system events, so let me work on them and I'll push a new versions, and you'll be able to catch any Unity UI events without any proxy which will be better for templates that runs on any object.

however the solution is also to simply compose your proxy by adding it to all objects potentially running your template and your template catches the default event setup on that proxy, this should work too ( but nonetheless, I like what I found on the doc on 5.6 so I'll implement it anyway)



 Bye,

 Jean

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15082
  • Official Playmaker Support
    • View Profile
Re: Problem adding 'PlayMakerUGuiDragEventsProxy' during run-time
« Reply #2 on: June 29, 2017, 02:22:05 AM »
Hi,

 ok, I have done all system evens as actions, so you don't have to use proxies.

https://twitter.com/JeanAtPlayMaker/status/880354132628041728

let me know how it goes, but know it should be ok to achieve what you want.

 Bye,

 Jean


omgitstri

  • Playmaker Newbie
  • *
  • Posts: 46
    • View Profile
    • My Prototypes
Re: Problem adding 'PlayMakerUGuiDragEventsProxy' during run-time
« Reply #3 on: October 02, 2017, 06:54:15 AM »
Hello,

Sorry it took me almost half a year to test this out.
This is working great! Thank you for helping out.
I apologize again for taking this long to test this

Tri Nguyen
Tri Nguyen
Game Designer at Nvizzio Creations

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15082
  • Official Playmaker Support
    • View Profile
Re: Problem adding 'PlayMakerUGuiDragEventsProxy' during run-time [SOVLED]
« Reply #4 on: October 12, 2017, 12:56:56 AM »
Hi,

 no worries at all!

Bye,

 Jean