playMaker

Author Topic: Twitter?  (Read 15214 times)

dudebxl

  • Hero Member
  • *****
  • Posts: 602
Re: Twitter?
« Reply #30 on: March 23, 2016, 09:01:07 PM »
Try with this in your query: since_id  && result_type=recent

For me, it refresh result when I use this..
« Last Edit: March 23, 2016, 09:08:36 PM by dudebxl »

laynardo

  • Junior Playmaker
  • **
  • Posts: 54
Re: Twitter?
« Reply #31 on: March 24, 2016, 12:22:08 PM »
yea, i tried that. i think it just something simple in FSM that I am doing wrong. I am going to attach it here.

dudebxl

  • Hero Member
  • *****
  • Posts: 602
Re: Twitter?
« Reply #32 on: March 24, 2016, 12:39:52 PM »
Yeah can you upload a picture. i don't like opening packages as they always mess up my projects... and my computer is very slow so each time i open unity, i have to wait ages.

laynardo

  • Junior Playmaker
  • **
  • Posts: 54
Re: Twitter?
« Reply #33 on: March 24, 2016, 06:35:21 PM »
here you go. i can add some more shots if that helps

dudebxl

  • Hero Member
  • *****
  • Posts: 602
Re: Twitter?
« Reply #34 on: March 25, 2016, 09:19:58 AM »
I have an extremely similar fsm setup in my project and I am able to refresh the data so I think it is the query.

- Have you tried with a diffrent and very popular q=?
- Are you using since_id with your new timestamp on each request?
- are you result_type=recent?

laynardo

  • Junior Playmaker
  • **
  • Posts: 54
Re: Twitter?
« Reply #35 on: March 25, 2016, 11:30:46 AM »
In the datamaker xml proxy, I actually see the xml getting updated. But for some reason it's not populating the hashtable with the updated nodes. I am even clearing the hashtable at the last state of the FSM, and it just populates the old tweets again.

I am wondering if i just move the Xml Select Nodes to a new state, if it will just work.

dudebxl

  • Hero Member
  • *****
  • Posts: 602
Re: Twitter?
« Reply #36 on: March 25, 2016, 11:38:49 AM »
ah.. ok i can't help. i only used datamaker once. I can help with the twitter api action but for datamaker you should ask JeanFabre or mdotstrange (if willing).

Maybe the variable is not correct. Do a frame by frame debug in playmaker and check each variable at each state.

sorry

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: Twitter?
« Reply #37 on: March 25, 2016, 02:30:49 PM »
Hi,

 uhm, maybe you need to wait one frame for sure once you parsed it. try this and get back to me if that doesn't work.

Bye,

 Jean

laynardo

  • Junior Playmaker
  • **
  • Posts: 54
Re: Twitter?
« Reply #38 on: March 25, 2016, 04:48:47 PM »
yea. tried that. you mean one blank state, or a wait for like one second?

laynardo

  • Junior Playmaker
  • **
  • Posts: 54
Re: Twitter?
« Reply #39 on: March 25, 2016, 05:25:48 PM »
the hashtable data doesn't get populated with new data. Even when I can see the xml data being updated in the proxy. It just re-adds the same data from when I hit Build. It's like it's being stored somewhere after the first run through or something.

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: Twitter?
« Reply #40 on: March 28, 2016, 02:08:58 AM »
Hi,

 I'll have a go at all this, and let you know how it goes.

 Bye,

 Jean

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: Twitter?
« Reply #41 on: March 29, 2016, 02:59:26 AM »
Hi,

 ok, I tested and it all works properly, here's few tips to debug this on your end.

-- ALWAYS implement all events from xml actions ( Found, Not Found, Error), it's critical to keep sanity in your project and mind... so the first thing to do is to route each xml actions with proper transitions for each potential outcome.

once you have done this, run it, and see if indeed xml is being parsed properly and that your xpath queries lead to valid searches within the xml.

then if all of this works, try the following:

1: get the twitter result
2: use ConvertJsonStringToXml and save it into your proxy
3: use XmlGetNodeProperties using that proxy as the source with the following property: "/search_metadata/count" save that value into a Fsmstring called "Count".

run this, you should have a value inside "Count".

 no need to wait one frame or anything weird, just go from state to state as per usual.

Let me know how it goes.

Bye,

 Jean

laynardo

  • Junior Playmaker
  • **
  • Posts: 54
Re: Twitter?
« Reply #42 on: April 24, 2016, 08:24:38 PM »
I get the right value inside my count. My proxy live updates with new content every time I loop back to start- it's my hashtable that isn't updating after the first loop.

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: Twitter?
« Reply #43 on: April 25, 2016, 01:23:51 AM »
Hi.

 Why looping back?

Bye,

 Jean

laynardo

  • Junior Playmaker
  • **
  • Posts: 54
Re: Twitter?
« Reply #44 on: April 25, 2016, 10:01:02 AM »
I want to live update the tweets, so they aren't the same six for the entire time. so i loop back to start to refresh everything.