Savvy001's Recent Forum Activity

  • septeven

    Is it possible to add a expression so we can set a textbox to " the amount downloaded/uploaded".

    That way the user can see the downloading/uploading process.

    At this point i can only show them: is uploading/downloading.

    And download/upload complete.

    Is it possible?

    Kind Regards.

    Savvy001

  • NRABrazil

    My app is on my own hosted site.

    cvp

    Thanx, your answers are correct. <img src="smileys/smiley32.gif" border="0" align="middle" />

    Ps: having the user of your app upload more images later on gives a problem as the app must know the image names.

    As in wich ones to load as URL.

    How would u overcome this using the Dropbox plugin?

    Kind Regards.

    Savvy001

  • cvp

    Well that will only work if the user would upload his images first via your app.

    But as that is not the way u need it, i think its a dead end "for now".

    Kind Regards.

    Savvy001

  • NRABrazil

    Thats correct.

    When a user starts my app, the app connects to "their" dropbox, not mine.

    Once they have logged in, they are asked for permission to connect this app to their dropbox account.

    When they click "allow" the app restarts and now the dropbox plugin is connected.

    From that point on the plugin stores information in the users own dropbox.

    This makes it possible for players or app users to store their complete savegame online, and vice versa to download it anywhere else.

    So anything u put into the webstorage, u can save/backup and do all kinds of fancy stuff with.

    In my current understanding, this plugin combined with the webstorage is the best option to give players/users truly a savegame.

    Its a relief to know i can simply delete my browser cashe, knowing that 2 clicks later im downloading my savegame again!

    Ps: thanx for your tip to towards cvp

    That is indeed the best option for him.

    Kind Regards.

    Savvy001

  • cvp

    Could u explain what the exact thing is u want to do.

    "using the images already in the dropbox" is a bit vague.

    To speak clearly: is it your intention to enable user content.

    Or do u, as the developer want to store all images in a dropbox yourself?

    Kind Regards.

    Savvy001

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • cvp

    The thing is that any normal image that is in the dropbox can't be displayed in your app.

    Construct2 gives u the possibility to load an image from a URL or URI.

    That being said: Dropbox needs permission from the user side to enable u to download.

    So just pointing the "Load from URL" (which is build in action in the event editor) to dropbox will not work.

    Correct me if im wrong on this matter.

    So if u want any image to be loaded into your game.

    Then u have to A: Put a premade .txt AsJSON with all your images in it in your dropbox.

    Or B: Go with the method i presented in the .capx

    Method B: is in short, load image into game/then upload webstorage to dropbox.

    Then later on u can download it again from dropbox back into the game.

    Thats 1-up for multi platform gaming ;-)

    But this method is based on user content for games.

    However u could also use it to build your base64 image collection.

    Which u can then download in other games.

    Hope this clarifies it a bit ;-)

    Kind Regards.

    Savvy001

  • Ashley

    Its not about smart use.

    Its about user content. (loading the face's of friends and all kinds of stuff)

    The users can upload their own images into the sprite instances using the Drag&DropZone plugin provided by Pode.

    Then with the dropbox plugin provided by septeven they can upload/download their complete webstorage: wich is growing bigger with more images each time they add new ones.

    For each image they upload, a new sprite is spawned and the image is set.

    But because of the fact that i cant spawn clone's of sprites, i am limited to instance frames for setting the uploaded image per sprite.

    So if i would give the main sprite 200 image frame "slots", but the amount of sprites eventualy reaches above 200.

    Then there wont be anymore frames left for the user to upload his images to.

    And i just dont want to limit the users because of a "estimated" pre-set amount of animation frames.

    I hope i explained it well?

    Kind Regards.

    Savvy001

  • cvp septeven

    Here u go. <img src="smileys/smiley20.gif" border="0" align="middle">

    Dropbox Image Example

    All the logic is in the capx.

    If there are any questions i'l help gladly.

    Ps: In the Capx The Sprite has a variable called Name.

    That is important if u want to save images under different names for different sprites or sprite instances.

    This way u get a nice list in the webstorage easy to retrieve.

    The image variable in the webstorage is always saved as "custom image".

    But saved under the name of the sprite.

    So u could have;

    Sprite name = John

    Webstorage = John & "custom Image"

    Sprite name = Pete

    Webstorage = Pete & "Custom Image"

    Etc

    In the end your dropbox will have a .txt file with the complete webstorage in it, including the images.

    This makes it super for games with user content.

    The nice thing about the dropbox plugin, is that when your app is approved by dropbox.

    The player of the game uses their own dropbox to save the data!

    The plugin just uses your dropbox secrect, letting dropbox know its your app that has connected with the players own dropbox.

    Kind Regards.

    Savvy001

  • cvp

    You could use the base64 technique that Pode has already build plugins for.

    Meaning.

    In my app i use the "drag & drop zone" plugin to get images into the frame of a sprite via the load from URI event.

    Then at the same time i save that base64 image string into the webstorage under a custom key.

    I upload the contents of the webstorage via the dropbox plugin to dropbox.

    Then i can get that same "savegame" with the images on any other computer.

    I simply download the savegame with the dropbox plugin again.

    And on download i set the base64 images back to the sprites.

    If u want images from dropbox, then base64 is the way to go.

    Combining the dropbox plugin septeven build with the plugins Pode build is key.

    And very simple to set up.

    Hope this helps

    Kind Regards.

    Savvy001

  • Ashley

    I have a new issue with this.

    The method above is fine if i would have a "known" amount of sprite instances i need to use.

    Then i would just give the main sprite enough frames.

    In my case i cant predict the amount of frames the user is going to fill with their own image's.

    So as they progress in the game, they add more sprite instances.

    But when the frame amount runs out it would mean that the user could no longer insert their own images.

    Simply because all the "set" frames are already filled.

    It would look like.

    Amount of sprites: 200

    Amount of instance frames: 200

    = 200 frames can be filled with user images

    (This setting is good for static games)

    My case is:

    Amount of sprites: 200 & growing by user

    Amount of instance frames: 200

    = 200 frames can be filled with user images, but sprite amount will exceed this limit.

    (Here i have a problem because i cant "grow" the frame amount)

    Do u have a solution?

    Kind Regards

    Savvy001

  • Thanx for the advise! <img src="smileys/smiley32.gif" border="0" align="middle" />

  • I'd love to use this.

    But i need it with webgl.

    Is that possible to implement?

    Kind Regards.

    Savvy

Savvy001's avatar

Savvy001

Member since 22 Jan, 2012

None one is following Savvy001 yet!

Trophy Case

  • 12-Year Club
  • x2
    Coach One of your tutorials has over 1,000 readers
  • Email Verified

Progress

14/44
How to earn trophies