Help with Tamagotchi

not yet. Thanks tho!

So, my Tamagotchi script pic (12) block keeps stopping midway, and I don't know why. I've tried again and again to find the bug, but I just can't.

Here is the link.

(Protip: Do not pause the project, because for some reason, it will create an annoying beep when you unpause it.)

Guys we still need to decide what the Tamagotchi eats for a snack

Edit: I decided it should be cake. If you guys want something else for the snack, I will be happy to change it!

Update: I have added the save code system, and even made it so then it can autosave, storing the data in the browser. Since there is only one Tamagotchi, which is the baby, the save codes don't really have much of a visible impact right now, but it will when I implement the ability for a Tamagotchi to grow up!

sorry but how do you do that because I forgot how to do the thing where you press the arrow and it shows a checklist

Do you mean like this?

option 1
option 2
option 3

You have to type in something like this:


[details="Do you mean like this?"]
[] option 1
[] option 2
[] option 3
[/details]

You probably should have asked this in a new topic.

Thanks exactly what I needed!

I was just looking at old-ish topics on snap and i tink maybe we can try and finish this one if you are up for it?

I ordered Tamagotchi art on the Scratch forums. I am currently waiting for it to begin working on the Tamagotchi again

So you are doing it on scratch now? Or just the art then you will put it in snap?

I will put the art into Snap! when it is finished.

Okay! And i can work on anything right now. But i can at 3:15 my time. 6:15 your time. Becuse well school is a thing.

that’s a pretty interesting concept

i’m probably not going to contribute much, or at all, but i like the idea

i was thinking about mentioning a sort of way to “calculate” events that should’ve happened while the project was inactive when you run it again, you know, as opposed to using save codes, but i feel like it’d be too complicated for a tamagotchi game (unless the event handling is really simple and there aren’t too many events)

however, if you think you’d be able to implement that, i’d love to see how you do it

i like how it looks right now though!

I would be interested in hearing your ideas!

Now that I think about it, I am planning on making one using the save codes. The save code will save the time, and the project will calculate the events that should have happened during the time you were gone.
Also, to make it less of a hassle, the project uses the Database library to save the save code onto your browser, and can detect if you have a file saved so it can load it up. Of course, you can turn off auto-save and/or use a save code you copied.

I mean the only events are the meters going down, needing attention/discipline, getting sick, pooing, and dying.

Thank you very much!

that’s actually exactly what i was thinking, my thought process came from my time playing antimatter dimensions though (when you open the game, it takes some time to calculate all the ticks that should have occurred while you were offline, since it heavily relies on math)

also a good idea, how does the project create the save codes/files?

It’s simple, but complicated. It takes a lot of numbers (like the meters and time until it changes) and joins them while separating them with commas.

When it reads a save code, the program:

  1. Creates 2 script variable (let’s call them “text” and “num” in this example)
  2. It increments (num ::variables) by 1 and set (text ::variables) to (join (text) (letter (num) of (save code)::operators)::operators) , which basically adds the next letter of the save code to (text ::variables) . It repeats this until it reaches a separator, which is the comma.
  3. When it reaches the comma, it sets a corresponding variable, like (Happy Meter ::variables) to the value of (text ::variables) . The variable (text ::variables) is then reset, making it an empty string, while (num ::variables) is incremented by 1 so it doesn’t stay stuck on the comma.
  4. The program then repeats this process for the rest of the save code, setting a different variable each time.

I haven’t touched or even seen the code for the Tamagotchi for three months, so some information may be slightly inaccurate.

not a problem, i don’t mind checking for myself

i’ve thought about making games with a save code function many times before and i’ve had this recurring idea of making a special sort of encoding/decoding system where the project basically treats all valid ascii code points as a base-1114111 number system, which, theoretically, could result in super short codes that are able to hold a lot of data
if the save code data is mainly numerical, this could probably be useful

Guys the art I ordered on a Scratch forum shop is taking too long, so I decided that we should make our own art here.

I will start by modifying kingnico1133’s toddler art to make him look more like a robot, and I will add animations for different actions like eating and sleeping.

If you want to help, I will give you the very specific rule set for every single Tamagotchi and how they need to look.

I updated the save code system to use Base 256 for some items, using a custom block to do this. This allows numbers up to 65535 to be stored with only two symbols. I might make the save codes even more compact by increasing the base in the future.

Also, I received the Tamagotchi artwork from Scratch that I ordered from the Scratch shops.

Here it is:

We still need animations for them, which will be a bit difficult, considering some of them don’t even have eyes.

I’ll continue to help, but not right now.