Save example

user_avatar
Made by: Murtaza developer hyperPad admin

PROJECT DESCRIPTION

Share this project:

This is an example game that shows a character select, and save. When you choose your character it saves your selection. So when you press continue it will keep the same character from before.

VERSION 1.0

Last Updated: January 23, 2016

COMMENTS

YOU MUST BE SIGNED IN TO LEAVE A COMMENT

April 09, 2019

Hey how do you get admin

February 24, 2018

So I’ve been working on a project for about 2 months. I posted it on the hub and of course only 1 person played it. So since you’re so good at giving feedback I was wondering if you could you could give me a suggestion on it. I don’t care if you rate at all or anything, but anyway it’s called Kid Emona. That’s a pun that nobody gets because it’s Greek.

September 20, 2017

Hi murtaza. It’s been 24 hours since I used the priority support, but I haven’t gotten any emails or notifications, and I am wondering why. I mainly want to ask, how does the hyperPad team get back to me. Also I’m not using the priority support right now for a reason. XD

September 21, 2017

Sorry for the delay. We’re wrapping up the latest update and we’re stretched a bit thin. I’ll make sure you get an answer ASAP!

Sorry again for the delay.

September 21, 2017

Oh, well thanks then, I got the email :)

May 17, 2017

How do up you not use keys and the save and load files are red not blue what's the loading default value

May 17, 2017

This example is no longer relevant. This used the old save system not the new system.

September 05, 2016

Is it possible for anyone to become an admin

April 02, 2016

Hey murtaza I'm working on a new app and I'm trying to figure out how to let the user type text that saves on the screen. I've tried the set text, but I can't seem to save the text that I type when the game is running. If you could help me that would be great!

April 03, 2016

After you use set text, you will need to use the Save behaviour. This will then save what ever is in set text. However, what you also need to do is use the LOAD behaviour, to load what ever you saved and make the label show that value. Depending on your game, this could be right when your game starts, or based on a certain event (touch a button etc.).

The trick with Save and Load, is loading at the right time, otherwise you can't use what you have saved.

April 03, 2016

What would be the right time to save then load? Also I was using the input text not set text (label). When I run my app I have a label and when I click on it it's supposed to bring up the alert to type text for example 45 as the text, but then it won't set the label to what I typed into the input text. Thanks for replying!

April 03, 2016

Right time to Save and load? well that depends heavily on your app, and what exactly you want to do.

For example, if you want a label to say "Hi ___" right when your game starts(where ____ is the entered name), then the first thing you would do is load. So have a LOAD behaviour before anything else actually happens. For saving, well in this exmaple you probably want to save right when the user enters text. So connect the save, to the same place where you have "Set Text" This way it saves after the user inputs something, and it sets the label to the users name.

For the issue you're having with the label not setting to the inputted text, are you sharing the value from the input txt behaviour to the set text behaviour? See our help docs on "sharing values" (https://hyperpad.zendesk.com/hc/en-us/articles/202467445-Sharing-Values-Between-Behaviors) on how to tell one behaviour to use a value from another.

April 03, 2016

Ok, so I finally got my user input text to set the label so that's good. Now my biggest trouble is the saving and loading. So in my app it starts on the home page. Then the user hits "my team" then there is a bunch of cards and they all have a 0 in the top right corner of the card. So the user taps on the 0 and enters the text for it. So I want to save that text they enter, so when they exit out of the app and they reload it they will have their text saved. Thanks for the help again!

April 03, 2016

In your case, you probably want to save as soon as they enter (so after the input the text and the label changes) And you want to use load right away when the scene starts. So just put a load value on any object, and have it not connected to any thing.

That will load once, right when the level starts. If you want it to load again, just use behaviour on and select that LOAD behaviour. It will execute again, and force it to load a new value if it has changed.

April 03, 2016

Ok so I did all of that, but it still won't work. My connected code goes in in order (started touching, text input, set label, save to file) then my load from file is just next to that and it's loading the save file. Can you see any mistakes in the coding?

April 03, 2016

Fill out the personal support form in the LEARN tab, and include your project. I'll try and see what's going on. I think I need to see what you're doing to help you better. :)

April 04, 2016

How do I add the project? And I accidentally sent that email sorry! Should I just post it to the hub so you can branch it?

April 04, 2016

Tap the "..." icon, and select email download link. Let it upload, then copy that link and paste it into the personal support form.

April 04, 2016

Sent it

March 09, 2016

Can I please branch this? Please answer as quick as you can!

March 09, 2016

I will branch this and then delete this if I cannot.

March 09, 2016

What I mean was delete from my projects...

March 09, 2016

You don't need to ask permission to branch. If a project is open-source and branchable then you automatically are allowed. If a project is created by the hyperPad team is it highly encouraged for you to branch and learn from it. That's why we make these projects and share them to the hub.

March 09, 2016

OK! Thank you for freeing me from being too nice to people!

January 24, 2016

Is it possible to save levels and make a saveable inventory?

January 24, 2016

Of course. You just need to make sure your saving the right things and at the right time.

Remember, your saving data.. So either text or numbers. You just need to have logic where these mean something. It all depends on exactly what you're trying to do, but it generally requires some thinking.

For example, you can create an inventory by having 2 save behaviours for each slot. The first behaviour is for the item, the second save for the amount of that type of item. Apples in the first save, 5 in the second.. This means 5 apples. .

You just need to have your project set up correctly and thing through everything logically.

January 23, 2016

Nice, I can use this for some games!

January 23, 2016

Thanks for the example

January 23, 2016

Nice example!

January 23, 2016

Every time I try to load this the app crashes

January 23, 2016

Are you running the latest version of hyperPad? It was created on 1.12 and will only work on that version (the hub should have complained telling you that, but there could be a bug with that popup)