playMaker

Author Topic: WWW Sprite not loading from "Application.persistentDataPath"  (Read 2377 times)

deathknight72

  • Playmaker Newbie
  • *
  • Posts: 3
WWW Sprite not loading from "Application.persistentDataPath"
« on: November 27, 2017, 08:49:44 AM »
Hello,

I'm having trouble creating a string that loads files from "Application.persistentDataPath" with playmaker.

I'm saving a screenshot to the persistent path and its working fine but I cant load it when using the "WWW Sprite" action when I use "File:///Application.persistentDataPath/IMAGE.png" in the "URL" field.

I can load the image just fine if I put the full directory path ("File:///Users/user/...") so I know I am able to load but for some reason it doesn't recognize "Application.persistentDataPath" as being a path.

Does anyone know a way to possibly call the persistentDataPath and save it to a string variable so I can build a string to call using that variable directly instead of relying on "Application.persistentDataPath"?

I spent literally all Sunday trying different paths and nothing worked. I tried "File://" as well as "File:///". I've tried with "+" to see if I could combine strings in the "URL" field(I know about building strings but I was trying anything at this point). I dont know what else I could try.

EDIT:
Something like this would definitely be helpful but it doesnt appear to actually be on the Ecosystem http://hutonggames.com/playmakerforum/index.php?topic=11861.msg55420#msg55420

EDIT 2:
I think I just answered my own question . . . I didn't notice the script was attached to the comment linked above. I'm able to pop that into the project and get the path and save it to a string. This should work fine but it still doesn't change the fact that I cant use "application.persistentdatapath" in the "URL" of the WWW actions. I'd still like advice for this for future projects.
« Last Edit: November 27, 2017, 09:12:45 AM by deathknight72 »