External Data Extension [2.0.0]

Jo3m

  • Posts: 13
Hello, I'm confused. I'm trying to use the "save data" block. I want to save the contents of a previously defined value to a "test.txt" file and it does not work. I work under Windows 10 as administrator with all file write permissions. Of course, I created the directory "extras", but nothing to do, it does not work.

The block is used not in the main loop, but in an "actor" object. For the moment, I do not have an answer to this problem.

I tell you what I'm trying to do because maybe I'm not using the right method. I created a parser able to read xml format and naturally, I would like to save the result in a file. Maybe there is another method than this extension to save xml data, for now I'm doing just that.

Thanks for reading me.


« Last Edit: February 01, 2018, 08:53:27 am by Jo3m »

yoplalala

  • Posts: 1453
- put a print in the save data.  Do you see it in the logs ?
(Met un print à l'intérieur du bloc save data et check si tu le vois qui s'imprime dans le log)
- create you text.txt in the files extras and check it has been modified
( Créé le fichier text.txt dans le dossier extras que tu as crée et vérifie s'il a été modifié)

Jo3m

  • Posts: 13
Yes, do it but don't work !
Merci de me répondre en français.
J'ai bien réalisé ce test et dans le log pas de souci, c'est "Sauvegarde réussie" qui apparait lorsque j'effectue cette action. Par contre, dans le répertoire "extras", rien... J'ai créé un fichier txt vierge pour voir au préalable, mais toujours rien. Bien sûr je me suis assuré que ma valeur contient bien quelque chose, c'est à dire du texte, et oui pas de soucis la valeur Page contient bien le texte voulu. Donc, pour le moment je sèche complet...

I realized this test and in the log no problem, it is "Backup successful" that appears when I perform this action. By cons, in the directory "extras", nothing ... I created a blank txt file to see beforehand, but still nothing. Of course I made sure that my value contains something, that is to say text, and yes no worries the value Page contains the correct text. So, for the moment I'm dry ...

Edit :

Nothing to do with Stencyl, it is a problem of authorization in writing under windows 10.

« Last Edit: February 01, 2018, 01:43:41 pm by Jo3m »

Jo3m

  • Posts: 13
Hello,
No. Don't work. Don't understand.
I go to the "extras" directory. I right click> property> attributes> I uncheck "drive only"> I do "apply" then "ok" ...

It still does not work.

The actions print well in the log that indicates the "success" of saving the data in the file, but in reality nothing happens. I am very fussed.


yoplalala

  • Posts: 1453
Did you check in the game generated folder ?

Dincicode

  • *
  • Posts: 203
Love love love the txtension its enabled me to do so much more with Stencyl. However there is some things that jsut wont work with Stencyl 3.5. I found solutions to some problems but the get audio file I can only disable that block. Any fixes for 3.5?

yoplalala

  • Posts: 1453
try to find " var stencylSound "  and modify like this

Code: [Select]
#if (openfl>="6.0.0")
var stencylSound = new com.stencyl.models.Sound(-1, filename, true, false, 0.0, 1.0, ext, 0);
#else
var stencylSound = new com.stencyl.models.Sound(-1, filename, true, false, 0.0, 1.0, ext);
#end

or you can try this

Code: [Select]
var stencylSound = new com.stencyl.models.Sound(-1, filename, true, false, 0.0, 1.0, ext #if (openfl>="6.0.0") , 0 #end);

Dincicode

  • *
  • Posts: 203
Second one works fine.