How to create a shop


#1

While most people know this, some don't. So, if you don't, here is how to make a shop.

first, create a text object that is a $ (or whatever sign of the currency you use)

After that, make a blank text object and name it "amount of money"

then enter the code.

after that, add a when 7 = 7 when block

the next step is adding a set text block.


You see those lines? Tap them.

next, create a new value. Call it "money"

now, set the color to whatever you want! I did random.

but look! You only have $0!

Let's pay you for your har.d wor.k. First, create a new object. A blank text is easiest, but anything will work as long as you use set invisibility to 100

add a when the game starts when block.

and then, add the pay machine thing, a set value block. Set the value money to whatever you want. I did 100

now you have money, but nothing to buy! Add a text object that says the price of the object, and the object itself.


Overpriced chips. Yummy.

now go back to the object that gave you money. Add a when (button you just made) is tapped when block.

then, increase value money by -price and increase value (object) by 1 (or more, it depends)(Check once if money is greater than price - one is ESSENTIAL)

you can add as many options as you want.

You can end up with shops like these!

Old Poll
  • This helped me
  • This helped me a little
  • I already knew this
  • OMG @THEMASTEROFAIRJITZU IS THE BEST AT STUFF LIKE THIS AND THIS IS AMAZZZZZZIIING!!

0voters

Votes are public.

Be honest. Idc.

MobCraft's Topic Portal
Hi I am new here! :D
THE BIGGEST CONTEST I HAVE EVER HAD! Winner gets a nomination for featured and a nomination for game changers!
The Newbies Guide to Hopscotch
THE BIGGEST CONTEST I HAVE EVER HAD! Winner gets a nomination for featured and a nomination for game changers!
Cost of things and buy menu (need help for a game)
Keio's 'General Topic'
The how-to portal (official)
The how-to portal (official)
How to learn basic values
I'm new and I need help with code
ICMLC ICMLC ICMLC, is cool
How to do Bold Text
Exchanging opinions about our games
How to do basic variables - HWC topic remake
#2

This is awesome! I haven't even read the whole thing yet, but it seems cool.


#3

Great tutorial! Shops are fun to make and customize in Hopscotch. You can even have a "job" of some sort (a mini-game) to earn money so you can buy items. :smiley:


#4

Awesome tutorial!! :DDD

overpriced chips are the best. XD


#5

yes, yes they are.


#6

NICE I LIKE IT ALOT!
Great Job, Keep Doing More Of These Tutorials! :smile:


#7

Great tutorial! I already knew this, but this will be helpful for novices!
Great job, @Themasterofairjitzu! :smiley:


#8

This is a really basic shop, and also great tutorial. Do another tutorial on advanced shops with more objects and maybe one how you can have multipliers and make it were it adds money slowly to your current amount


Petrichor I (Am)
#9

Ok.


#10

Ok lol. When do you think you will finish it and no I don't need it I'm pretty sure I'm more advanced for that stuff


#11

When I stop procrastinating. I said I would teach my self sin and cos in the middle of August and did it yesterday. So mabye week mabye less.


#12

Lol I would love to learn sin and cos, I guess I know a little but I need to know more


#13

Cool! Adding a background to look like a shop, or having chips trail art would make this so much cooler!


#14

Your script makes it so that you can buy the overpriced chips without enough money and go into negative amounts of money. Usually people won't want that. You have to add
check once if
money > 19
if so, increase value money by -20


#15

Didn't make sense. I'm dum so don't take offense


#16

wow this really helped me thanks


#17

Omg I totally forgot that. Oops.


#18

ovurpriced chips are da best, thxs for saying that. because ima potato.


#19

Gonna add this to the topic portal because this will be useful for beginners!


#20

It's done. Sorry it took so long. I totally forgot the check once if at first. Oops