Use lists, not text. You need a list property called card list, and the numbers for it are 01, 02, … 52, and its better using leading zeroes. And the cardlist is not empty, make a random number genorate from 1 to the length of the cardlist. And use remove from list at index (random number) block to take out a card. If deckleft has less than 26 items, add the taken out card to deckleft, if its else, add the taken out card to the deckright, and keep doing this until card list is empty.
edit: @some_kid should be able to help you
Gng what in tarnation is a list property ![]()
Unfortunately, we’re not working with scratch, and we don’t get lists because Josh doesn’t feel like it.
I’ve been helping him brother.
I got it to work with this code:
I’m not sure exactly what is wrong with your code, because pretty much the only thing I changed was using the fird and last letter settings and making rand a variable.
Also, I just put it all into 52 cards, but your check to split it into two hands of 26 should work fine.
Example of a test (I added periods so my eyes could see better):
yay!
Gkc has no lists T-T.
Oh yeah I’ve done stuff like that before (monopoly and checkers used them) but that’s still not a list it’s just a bunch of properties and this simple system doesn’t need that. A string works amazingly well without using 52 properties hahaha.
You can make lists by using multiple properties, (item 0, item1), and use a trigger to connect them, with a number variable to get specific items. I have always used lists for my games like bedwars.
That could work as well
Your error is originating from where you try to get the substring starting from letter 0. Starting at a letter number less than the length of the string causes the string to wrap back around.
For example when getting the substring of Hello, world! from letter # 0 to the last letter, the output is !, and when getting the substring of Hello, world! from letter # -1 to the last letter, the output is d! However this only happens until the length of the string has been passed by the absolute of the first input. Trying to get the substring of Hello, world! from letter # -13, -14, etc to the last letter all output Hello, world!
HTH’s is almost right. However, making the substring start from the first letter is not enough. If the rand value ends up being 2, then the substring will be from the first letter to letter # 0 which obviously doesn’t work. Because of this, we don’t want to get the first substring if that is the case. With that, I give you the fully functional code:
Thanks for the challenge, it’s been a while since I’ve seen a solid problem like this!
It actually is enough. Javascript (which Gimkit blocks run on) counts letter 0 as the first letter (eg letter 0 of “hello” returns “h” in javascript). Here’s proof:
And I ran it as the first number and it worked. I did the same with 1 and it also worked.
But nice to see you back Fulcrum!
Part of my card guide has a section on “shuffling” the cards if that’s what you’re looking for, although the pictures are gone so I’ll have to check my maps for all the images.
W I found it, hold up I’ll post the images soon.

If you go through my guide in order the images should make sense, now if you’re wondering why the images I have is not the same amount as the ones in my guide that’s because I did this on a chromebook (w memory on that thing) and this was before I figured out how to zoom so I had to take multiple screenshots. This should be cleaner to understand. Any further questions you can ask me.
Okay then, I’m even more confused now. It was not working for me previously whenever I did your setup, and now it magically fixed itself. Even though letter number 0 doesn’t actually return the first letter (I tested it using get letter # block), if it’s not broken, don’t fix it.
That’s odd, that’s how JS is supposed to work, so it must just be a Gimkit thing. Either way, it’s nice that the system works hahaha.
Sorry there’s been a lot of replies since I last checked this. Has a solution been found?
I think they’re still working on it. Also, welcome back! (even if it’s only temporary)
Uh I cross checked it starts at index 1 I believe.
Wholeheartedly agree.
I think the whole idea was a misinterpretation of indexes and where they actually start.
Ok this is what I currently have
(The Unshuffled property now has an X appended at the beginning and end)
What do I need to change? Or is @Fulcrum-19’s solution good and I should just use that?
You should decrease the last parameter in the first Unshuffled substring by 1, and increase the second parameter in the second substring by 1. As it is right now, it just splits the whole string into 2 substrings, and then glues them back together without removing anything. This is because the substring block is inclusive of both letter numbers.
So in the Unshuffled substrings: (rand * 2) - 1 should become (rand * 2) - 2, and rand * 2 should become (rand * 2) + 1
Fulcrum’s blocks should work.
Ohhhhhh I didn’t realize they are inclusive ok
So I did that and got this:

Which um if you look near the end of the 2nd one I think it has the number 40 twice. Was there something else I needed to change?
Karl read this:
You can also remove the period insertion (to help my eyes) and this should work with the two deck system you have set up.
Ok I will try that when I get a chance
It works, thank you all so much!
This topic was automatically closed 3 hours after the last reply. New replies are no longer allowed.












