Discuss Scratch

ViNTAGE_ViBESs
Scratcher
13 posts

How to make a cloud variable for a Highscore

Hello, thank you for coming here. My question was how I should make/code a cloud variable for my game https://scratch.mit.edu/projects/954000052/ for some reason the high score only tracks the biggest/largest amount of time, but I want it to record the lowest amount of time, also, it only saves the time for only my account, not other accounts and it also doesn't stop counting on the “last costume”, I'm not exactly sure how to code it.
bobopicklemaniac
Scratcher
46 posts

How to make a cloud variable for a Highscore

ViNTAGE_ViBESs wrote:

Hello, thank you for coming here. My question was how I should make/code a cloud variable for my game https://scratch.mit.edu/projects/954000052/ for some reason the high score only tracks the biggest/largest amount of time, but I want it to record the lowest amount of time, also, it only saves the time for only my account, not other accounts and it also doesn't stop counting on the “last costume”, I'm not exactly sure how to code it.
give me a moment to look at the code ill give you a response in a few minutes
bobopicklemaniac
Scratcher
46 posts

How to make a cloud variable for a Highscore

ViNTAGE_ViBESs wrote:

Hello, thank you for coming here. My question was how I should make/code a cloud variable for my game https://scratch.mit.edu/projects/954000052/ for some reason the high score only tracks the biggest/largest amount of time, but I want it to record the lowest amount of time, also, it only saves the time for only my account, not other accounts and it also doesn't stop counting on the “last costume”, I'm not exactly sure how to code it.
just switch the two variables
whenclickediftimer>highscore>then
should help i may be wrong
ViNTAGE_ViBESs
Scratcher
13 posts

How to make a cloud variable for a Highscore

I tried but it didn't work- what I mean is that it does “work” but it only tracks the highest amount of time it took but I need it to track the lowest amount of time.

Last edited by ViNTAGE_ViBESs (Jan. 24, 2024 04:18:22)

bobopicklemaniac
Scratcher
46 posts

How to make a cloud variable for a Highscore

your probably going to have to rely on someone else sorry
ViNTAGE_ViBESs
Scratcher
13 posts

How to make a cloud variable for a Highscore

nahh its fine thank u anyway
Potahtoe_
Scratcher
13 posts

How to make a cloud variable for a Highscore

just compare the user score and the cloud score, if the user score is higher, set the cloud score to the current user score.
deck26
Scratcher
1000+ posts

How to make a cloud variable for a Highscore

Are you wanting to store the largest value or the smallest value - sounds like the latter to me? In that case you update the cloud variable at the end of the game if the new score is less than the cloud variable.
ViNTAGE_ViBESs
Scratcher
13 posts

How to make a cloud variable for a Highscore

@deck26 that makes sense but im not sure exactly how to code it same for @Potahtoe
samet737372727
Scratcher
10 posts

How to make a cloud variable for a Highscore

whenthisspriteclicked
change scoreby1



whenclicked
foreverifscore>scorethenchange☁ scorebyscore

Last edited by samet737372727 (March 14, 2024 18:32:32)

TheDoogieMasters1234
Scratcher
5 posts

How to make a cloud variable for a Highscore

whenclicked
foreverifscore>scorethenset(☁ score)toscore
TheDoogieMasters1234
Scratcher
5 posts

How to make a cloud variable for a Highscore

Potahtoe_ wrote:

just compare the user score and the cloud score, if the user score is higher, set the cloud score to the current user score.
when spacekeypressedbroadcast Scratch was opened

Powered by DjangoBB