AI learns to play 2048

Поділитися
Вставка
  • Опубліковано 16 лис 2024

КОМЕНТАРІ • 7 тис.

  • @xexpaguette
    @xexpaguette 4 роки тому +9960

    When I was a kid I didn't even know there was a strategy and thought it was a clicker game where you just swipe as fast as you can randomly.

    • @jasonhoward2613
      @jasonhoward2613 3 роки тому +300

      There’s a strategy?

    • @xexpaguette
      @xexpaguette 3 роки тому +112

      @@jasonhoward2613 yes

    • @Sereal5706
      @Sereal5706 3 роки тому +148

      @@jasonhoward2613 there are many actually

    • @jasonhoward2613
      @jasonhoward2613 3 роки тому +99

      @@Sereal5706 wtf is the strategy everything is random chance except the math which is partly random to

    • @mattsadventureswithart5764
      @mattsadventureswithart5764 3 роки тому +96

      I found always going clockwise (or anti) worked. Up, right, down, left (repeat)

  • @campbellyrc12
    @campbellyrc12 4 роки тому +9349

    Tommy looks five moves into the future.. he sees his failures coming and has no choice but to helplessly walk towards them

    • @infrences
      @infrences 4 роки тому +75

      Idk why this comment doesn’t have likes

    • @Hoghiderrr
      @Hoghiderrr 3 роки тому +67

      He must follow fate

    • @derek-182
      @derek-182 3 роки тому +87

      @@Hoghiderrr It is.... inevitable

    • @dylans2ndchannel981
      @dylans2ndchannel981 3 роки тому +15

      ㅤㅤㅤㅤㅤㅤㅤㅤㅤㅤㅤㅤ

    • @nolanfaught6974
      @nolanfaught6974 3 роки тому +52

      It seems like the algorithm wasn't able to account for where tiles will appear or their value, so looking 5 moves into the future isn't much better than just looking one move into the future

  • @ihasarax
    @ihasarax 4 роки тому +8573

    Do i understand: no
    Am i entertained: yes

    • @oxygen_is_my_drug4811
      @oxygen_is_my_drug4811 4 роки тому +33

      Did i ask:no

    • @Paulito-ym4qc
      @Paulito-ym4qc 4 роки тому +182

      @@oxygen_is_my_drug4811 Shut up:yes

    • @critrawkets
      @critrawkets 4 роки тому +15

      @Bergo 3L.Normie It's your opinion : yes.

    • @critrawkets
      @critrawkets 4 роки тому +13

      @Bergo 3L.Normie this is not a roast: yes.

    • @ihasarax
      @ihasarax 4 роки тому +44

      bro why did this chat get toxic for no reason

  • @nintendocaprimoon63
    @nintendocaprimoon63 4 роки тому +3734

    New favorite insult:
    "You're about as good as randomly pressing the left key"

    • @EurasianInvasion
      @EurasianInvasion 4 роки тому +16

      Oh, damn you right

    • @746yashkashwani3
      @746yashkashwani3 4 роки тому +6

      Right bro

    • @NoOne-wz2ht
      @NoOne-wz2ht 4 роки тому +14

      Repetitively*

    • @ZielAmerak
      @ZielAmerak 4 роки тому +11

      if you are lucky you'll get 2048 with just left and down over and over.

    • @NoOne-wz2ht
      @NoOne-wz2ht 4 роки тому +13

      @@ZielAmerak I start by randomly mashing buttons

  • @LazyLetifer
    @LazyLetifer 4 роки тому +8913

    “Every one has the right to an opinion but not everyone’s opinion is right”
    Best quote of the decade

    • @melonx5380
      @melonx5380 4 роки тому +28

      I agree with you

    • @thel0n3lytramp63
      @thel0n3lytramp63 4 роки тому +116

      That quote is an opinion, and it is wrong

    • @greasychickenugget4410
      @greasychickenugget4410 4 роки тому +34

      It's so true. Just like how my friend thinks dragon ball is the best anime. His opinion is wrong

    • @khalil7011
      @khalil7011 4 роки тому +66

      Opinions cannot be right or wrong, if there is evidence behind the opinion then it is called a substantiated assumption and can be correct or incorrect

    • @thel0n3lytramp63
      @thel0n3lytramp63 4 роки тому +44

      @@khalil7011 That opinion is also wrong IMO

  • @Sgtcrazyeyes235
    @Sgtcrazyeyes235 4 роки тому +1817

    Hearing you switch between calling the ai tommy and tomas when you’re frustrated is like a parent being upset at their child

  • @songbirdlover
    @songbirdlover 6 років тому +2815

    Wow. I was just impressed with you recreating the game..

    • @riseeuterpe2838
      @riseeuterpe2838 5 років тому +39

      I'm pretty sure the original creator allowed for its free distribution so idk if he rly had to do that tbh XD

    • @stargazingsprout
      @stargazingsprout 5 років тому +183

      Harasuke Amu I’m pretty sure he needs to remake the game so the AI can see the code and actually play the game

    • @natenobles4372
      @natenobles4372 5 років тому +59

      The guy who made 2048 did it for fun in a week so it’s no surprise that it was kind of easy to recreate

    • @songbirdlover
      @songbirdlover 5 років тому +4

      @@natenobles4372 wow.

    • @Deathmastertx
      @Deathmastertx 5 років тому +10

      Recreating the game in Java was the final project of my first computer science unit at university.

  • @АлексейГерасимов-т7ш
    @АлексейГерасимов-т7ш 4 роки тому +2202

    Code bullet is so brutal that he doesn't creates algorithm for game, He creates game for algorithm

    • @thebiggestthickestbean5232
      @thebiggestthickestbean5232 3 роки тому +34

      I’ve never thought about it like that but yea you’re right, that’s pretty funny lol

    • @LordMaliscence
      @LordMaliscence 3 роки тому +32

      @@Mightic exactly, with most simple games like this, it's much better to just code it yourself instead of trying to interface with an existing game

    • @puppergump4117
      @puppergump4117 2 роки тому +10

      @@Mightic Yeah I think he started creating the games after the Piano Tiles incident.

    • @oldwateristic
      @oldwateristic 2 роки тому +2

      its funny

    • @photonbee1932
      @photonbee1932 Рік тому +1

      @@puppergump4117 this video was created BEFORE that… incident…

  • @ryanantoine8457
    @ryanantoine8457 4 роки тому +6033

    "it keeps lower scoring tiles away from the highest score tiles"
    So the AI enforces aristocracy.

  • @gristlyscarab7938
    @gristlyscarab7938 4 роки тому +3455

    Plot twist: It was his friend actually named Thomas playing all along

    • @fredthespear4923
      @fredthespear4923 4 роки тому +59

      Gristly Scarab plot twist: Thomas was an ai

    • @Beanpolr
      @Beanpolr 4 роки тому +64

      @@fredthespear4923 plot twist: Thomas was an ai made by his friend Thomas

    • @thomasnolastname8734
      @thomasnolastname8734 4 роки тому +33

      *sips water*

    • @badutubezboi5050
      @badutubezboi5050 4 роки тому +17

      mega oof plot twist: Thomas made Thomas who was an AI who made Thomas who was an AI

    • @yellostarr
      @yellostarr 4 роки тому +4

      @ReTri 64 Ahh yes, a man of culture I see

  • @creeperx3sssboom347
    @creeperx3sssboom347 5 років тому +6063

    Tomas: "I've looked 5 Moves in the future"
    Code Bullet: "In what one do we get to 2048?"
    Tomas: "One"

  • @kympx8460
    @kympx8460 3 роки тому +306

    Being named Thomas, I felt quite called out through this

  • @axelandersson6314
    @axelandersson6314 6 років тому +575

    3:40. Well, that’s literally the strategy I’ve gone with for the past 2 years...

    • @enriquejunchaya5784
      @enriquejunchaya5784 6 років тому +29

      Axel Andersson same, but it doesn't always get you a 2048. There's the "luck" factor and that's why Thomas couldn't get it either.

    • @wthrwyz
      @wthrwyz 6 років тому +47

      This pretty much *is* the strategy for 2048; pick a corner and work toward it. It doesn't always work because the random placement of new tiles will occasionally put you in a state where it becomes impossible to win despite perfect play (as illustrated by the video), but that's the nature of any game that features a random element. Put simply, luck beats skill any day of the week.
      Whatever you do, never move your largest value tile out of that corner - the RNG *will* screw you by immediately spawning a 2 there.

    • @wwoods66
      @wwoods66 6 років тому +5

      @Nathan Williams -- "never move your largest value tile out of that corner"
      But sometimes that's the only move, alas.

    • @wthrwyz
      @wthrwyz 6 років тому +3

      Indeed, and the RNG gremlins are already chuckling.

    • @edde2429
      @edde2429 6 років тому

      Wouldn't a good way to make the AI develop better be to let each one do like 10 runs and see which one was the most consistant

  • @BrianJones01
    @BrianJones01 4 роки тому +732

    When I went down the rabbit hole with this game, my strategy revolved around one simple restiction: choose a direction (in my case, up) and never move in that direction. A consequence of this is that the largest tiles end up on one face, similar to your "top left for highest value block" strategy. I wonder how the AI would do with this restriction in direction.
    Edit: 2048 became an easy target, if I recall correctly, 8192 was the max I reached before throwing the game in my "NEVER TOUCH AGAIN" category.

    • @xocheee
      @xocheee 4 роки тому +14

      i could neverrrrr reach 8196 how long did that take???

    • @xocheee
      @xocheee 4 роки тому +26

      @Natsu Dragneel lol do you mean score or tile? because i doubt youre dating the world record holder lmaoooo

    • @xocheee
      @xocheee 4 роки тому +16

      @Natsu Dragneel probably on the app where undos are possible too...

    • @BrianJones01
      @BrianJones01 4 роки тому +32

      @Natsu Dragneel I don't know that it can be considered "low" against any reasonable standard, even if it's not a record. To put it into perspective, a 6x6 board offers 2.25 times as much play area as a 4x4 board, and with that extra area comes many options for storing large tiles while building smaller tiles needed for further advancement (at a point, the hardest problem becomes efficient use of space). But still, congratulations to your girlfriend, impressive work!

    • @NoOne-wz2ht
      @NoOne-wz2ht 4 роки тому +10

      My strategy is spam random buttons at the start then press random buttons

  • @LarryJL
    @LarryJL 4 роки тому +438

    You should've told it that in addition to having the highest possible number in the top left corner is good, it should also prefer having as much free slots as possible and get rid of small tiles as much as possible

    • @fakename7725
      @fakename7725 4 роки тому +9

      I would have thought that would be the one and only scoring method for future outcomes

    • @varmituofm
      @varmituofm 4 роки тому +9

      He also had that the 2nd highest scoring tile should be next to the highest scoring tile. This should continue on down, the 3rd should be next to the second, the 4th next to the third.

    • @Le_g3nd
      @Le_g3nd 4 роки тому +5

      The highest theoretical number is 131k but the biggest number achieved is 65k (I know person who’s done it but don’t know if anyone else has)

    • @garethbaus5471
      @garethbaus5471 4 роки тому +4

      @@Le_g3nd I struggle getting past 4092 and I have spent way too much time playing 2048.

    • @frederickfritzsche97
      @frederickfritzsche97 3 роки тому +7

      Yeah, I think the entire problem boils down to develop a better way to evaluate the "game state". Looking 5 steps into the future should be absolutely enough to win this game, probably even 3. But it's sort of useless if your definition of whether the game state is good or not is so bad. eg aligned values (along a sort of S-shape) are much better than a 15 / 6 / 13 / 1 / 7 etc. Would be a rather complex algorithm for a simple game but hey

  • @chizzicle
    @chizzicle 4 роки тому +143

    I like how even when "Thomas" finally succeeds, it's still less efficient than any even slightly smart human player, making Tommy sort of pointless, but he always was a problem child and it's the journey that matters, not the destination

  • @azrubs593
    @azrubs593 5 років тому +732

    I felt so sad for him when he said “The next improvement was at generation 227” that’s gotta be so depressing

    • @sergioarvizu2972
      @sergioarvizu2972 5 років тому +48

      humans probably on generation like a million yet we still don’t know how to live perfectly. Good job AI

    • @aaronstorey9712
      @aaronstorey9712 5 років тому +9

      *247*

    • @Subakak
      @Subakak 5 років тому

      Me too

    • @pancakes9648
      @pancakes9648 5 років тому

      247***

    • @ryanrising2237
      @ryanrising2237 5 років тому +14

      Sergio Arvizu According to Wikipedia, the earliest representative of what we’d call humans, Homo Habilis, first showed up around 2.8 million years ago. Assuming generations take 20 years, which is probably very uninformed, that would be 140,000 generations.
      Not as much as a million, but a bit more time to develop than 247 generations. That’d only get us to here from just before the Great Pyramids were built.

  • @theeliteeaglegamer5893
    @theeliteeaglegamer5893 6 років тому +5103

    Ai learns to code Ai

    • @dandanthedandan7558
      @dandanthedandan7558 6 років тому +579

      TheEliteEagleGamer Wow, wow, wow. Calm down. Are you trying to give birth to SkyNet?

    • @MyH3ntaiGirl
      @MyH3ntaiGirl 6 років тому +198

      TheEliteEagleGamer DESTROY HUMANITY

    • @Bestname_Ever
      @Bestname_Ever 6 років тому +86

      TheEliteEagleGamer so its.... AInception?

    • @ras862
      @ras862 6 років тому +54

      *i love this idea*

    • @Youmu_Konpaku_
      @Youmu_Konpaku_ 6 років тому +14

      We need that

  • @arpitranasaria4878
    @arpitranasaria4878 5 років тому +1447

    That moment at 9:08 where Tommy could have just gone up left left and reached 2048

    • @jdao1sm
      @jdao1sm 5 років тому +16

      Arpit Ranasaria YEAH

    • @saeber6630
      @saeber6630 5 років тому +60

      *GODDAMIT TOM*

    • @nightowl19god25
      @nightowl19god25 5 років тому +15

      Arpit Ranasaria right up left left

    • @mehregankbi
      @mehregankbi 5 років тому +41

      That’s where u see the value of human labeling. Simulating a human learning prespective is so hard that its better if a pro player of 2048 plays the game 500 times and we give the data to our neural network. Then AI can have a very good sense of what playing this game looks like. At this point AI knows how to play the game but there’s also room for improvement. so just like code bullet did, now we can use “choosing the best out of 5 moves” just like he did and it is gonna get better and better.
      The more complex the problem (self driving car) the more useful the human teaching

    • @Doctor_Straing_Strange
      @Doctor_Straing_Strange 5 років тому

      OMG

  • @ricegorm
    @ricegorm 4 роки тому +124

    As somebody who is named Thomas, this ai is basically a perfect recreation of anybody named Thomas. They fail at everything for a while, then somehow get it out of sheer luck.

    • @denisucuuu
      @denisucuuu 3 роки тому +3

      Definitely not Thomas Wayne, since he succeeded for a while until running out of luck in an alleyway

    • @divakarmenon5381
      @divakarmenon5381 Рік тому

      ​@@denisucuuu that's Bruce Wayne?

    • @visiblerat
      @visiblerat Рік тому +1

      i am also named thomas and can confirm

    • @nirorit
      @nirorit 7 місяців тому

      @@divakarmenon5381no

  • @Thomashorsman
    @Thomashorsman 5 років тому +3570

    Sorry I wasn’t performing well

    • @romanboi8834
      @romanboi8834 5 років тому +299

      Try fuckin harder next time Thomas

    • @cheesecake-ne2qh
      @cheesecake-ne2qh 5 років тому +80

      Hello police I'd like to report a murder, I think the suspects name was John Garst? Please come to my location immediately, thank you.

    • @Joseph_Drew_III
      @Joseph_Drew_III 5 років тому +17

      No hard feelings Nikolai.

    • @alphapicturesentertainment
      @alphapicturesentertainment 5 років тому +23

      @@romanboi8834wanna go bowling?

    • @lilithkramer6698
      @lilithkramer6698 5 років тому +16

      Thomas Horsman HOLY SHIT I'M DYING

  • @MJDev14
    @MJDev14 6 років тому +200

    I have no clue what youre saying half the time but your channel is amazing

  • @leonjefferson6783
    @leonjefferson6783 5 років тому +1753

    CB: Since the difference between random movements and intelligent movements is very small...
    Me: Yes! I'm almost intelligent!
    edit: 1.5k likes :O

    • @sheeloesreallycool
      @sheeloesreallycool 5 років тому +3

      100th like babyyyyy

    • @kosk-kosk2777
      @kosk-kosk2777 4 роки тому +2

      Lol

    • @whydoiexist1527
      @whydoiexist1527 4 роки тому +1

      881 like baby

    • @TheStoneBreak
      @TheStoneBreak 4 роки тому

      I don't know the first thing about coding but always thought it was interesting. Is something like this really difficult or is it kind of an "eh" thing to other coders and only impresses the ignorant

    • @losereye
      @losereye 4 роки тому +1

      @@TheStoneBreak Oh god these algorithms are pretty monserous, its very impressive depending on experiece/foucus in ur code, as coding styled progammers simmilar to him wouldn't vice virsa

  • @O_CABBAGE
    @O_CABBAGE 3 роки тому +49

    "Thomas kinda sucks" I hear enough of this normally, I don't need it to happen here too

  • @JStubblefield79391
    @JStubblefield79391 5 років тому +357

    Code Bullet: “Alright, I think I’ll go to bed.”
    Thomas: “You’ll go to bed when we’ve reached 2048.”

  • @Sod1ePop
    @Sod1ePop 5 років тому +749

    "failure is important for learning"
    so that's why my dad says I'm important

  • @Alex-dz8dm
    @Alex-dz8dm 6 років тому +1736

    AI learns to take over the world
    -Code Bullet Video 2019

    • @Souls_29
      @Souls_29 6 років тому +9

      Hyrule Warrior if AI robots take over the world we can just blame Code Bullet

    • @hyperion9934
      @hyperion9934 6 років тому +16

      "His name is Paul and he conquers nations"
      -Code Bullet 2020

    • @TheFantasticWarrior
      @TheFantasticWarrior 6 років тому +2

      ...of Minecraft

    • @davislast7891
      @davislast7891 6 років тому +2

      I feel like a civilization video would be cool actually

    • @captionato
      @captionato 6 років тому

      lmao

  • @melissaclaassen9707
    @melissaclaassen9707 4 роки тому +58

    I love how much "failure" you actually include in your videos. It's interesting to watch how many types of things can actually go wrong while programming, and hearing what your thought process is to overcome them.

    • @lillyp1652
      @lillyp1652 2 роки тому

      So basically avoiding the problem

  • @PandaFan2443
    @PandaFan2443 6 років тому +591

    The first generation is already better than me.

  • @sir_slimestone3797
    @sir_slimestone3797 5 років тому +507

    "Everyone has a right to an opinion, but not every opinion is right" I love it, I'm stealing it for future arguments!

    • @mcplumpkin6191
      @mcplumpkin6191 4 роки тому +4

      opinions aren't wrong or right

    • @sir_slimestone3797
      @sir_slimestone3797 4 роки тому +3

      @@mcplumpkin6191 whoosh that flew over your head

    • @mcplumpkin6191
      @mcplumpkin6191 4 роки тому +8

      @@sir_slimestone3797 woooosh*
      by the way, it's hard to tell if this was a joke because you don't know the tone of the text.

    • @geli95us
      @geli95us 4 роки тому +5

      @@mcplumpkin6191 yes they are, if your opinions collide with evidence, then they are wrong.

    • @mcplumpkin6191
      @mcplumpkin6191 4 роки тому +1

      @@geli95us they are based on thoughts and experiences.

  • @rasput1n6
    @rasput1n6 6 років тому +167

    *Make an AI learn to play Windows XP Pinball??*
    *I WOULD LOVE IT if it makes fancy combos continuously or see what he prefers to do lol*

  • @mr.mysteryjelly1532
    @mr.mysteryjelly1532 3 роки тому +61

    "I CAN GO TO BED"
    has to be the funniest/saddest thing I have ever heard

  • @rcoverc
    @rcoverc 6 років тому +1876

    My highest tile is 8192. Take that thomas.

    • @dragovern
      @dragovern 6 років тому +77

      One game where we are better... still

    • @thejman3489
      @thejman3489 6 років тому +84

      RCoverC one time I got a 4096 tile and 2 2048 tiles but they weren't next to each other and I lost because I couldn't combine then and free up space.

    • @rcoverc
      @rcoverc 6 років тому +59

      @@thejman3489 Nice job. That's still a great score. I haven't played 2048 for about 6 months but I can tell you that I was improving slowly. Once I had 2 8192 tiles and I couldn't combine them *FACEPALM* :(

    • @CavemanNo.12
      @CavemanNo.12 6 років тому +46

      I got to 512. Snake is more my game

    • @MichaelTwitt
      @MichaelTwitt 6 років тому +38

      I mean not trying to brag but...16384

  • @ocinnico2608
    @ocinnico2608 5 років тому +801

    "what's up guys, today's video is in 2048"
    -code bullet accidentally reveals his origins

    • @aang8026
      @aang8026 4 роки тому +4

      Flunkyvs Lacky well now it isn’t anymore, so let’s like it again to try and get 512

    • @c10v3r
      @c10v3r 4 роки тому +3

      **420 likes**
      :)
      **likes**

    • @evertree2133
      @evertree2133 4 роки тому

      @@c10v3r But why?

    • @dougthedonkey1805
      @dougthedonkey1805 4 роки тому

      I don’t get it

    • @dougthedonkey1805
      @dougthedonkey1805 4 роки тому

      @Buddy Christ oh, I see. But what does that have to do with code bullet’s origins? Are they saying he’s a time traveler?

  • @Crazy1793
    @Crazy1793 5 років тому +1775

    It's April 21 2019 still no part 2 of enigma machine

  • @mantistsai6457
    @mantistsai6457 3 роки тому +9

    Your second approach reminds me of the Othello algorithm I wrote for my introductory coding course a few semesters ago and I just wanted to say, I 100% understand watching said algorithm come *so close*

  • @tysonmay5522
    @tysonmay5522 5 років тому +887

    Code an Ai that can beat another Ai in chess

    • @yolkeggs
      @yolkeggs 5 років тому +31

      Wait wouldn’t it always be a tie or am I missing something

    • @tysonmay5522
      @tysonmay5522 5 років тому +7

      Good point

    • @InnocentC0
      @InnocentC0 5 років тому +20

      There's a chess match for AI, though. It's quite intense and surprisingly complex.

    • @BorkKillsOneLegMan
      @BorkKillsOneLegMan 5 років тому +26

      @@yolkeggs let both ai know it can't end in a tie

    • @diegocastro7434
      @diegocastro7434 5 років тому +26

      @@yolkeggs you're missing something! Chess matches between different engines (ai's) are very common and some are far superior to others. Google recently destroyed the previous benchmark for the strongest engine (Stockfish) with their deep mind ai. In fact, by changing the difficulty of the chess computer on your phone, you're essentially getting two different "AI's".

  • @RqtiOfficial
    @RqtiOfficial 6 років тому +7535

    ai learns to play agar.io

    • @bluue5756
      @bluue5756 6 років тому +334

      David Simon And?

    • @bluue5756
      @bluue5756 6 років тому +258

      @@legoguney but *everyone* had to love it for some reason

    • @art-oq1pi
      @art-oq1pi 6 років тому +108

      David Simon how is it trash

    • @mac1cam
      @mac1cam 6 років тому +33

      Someone allready made a bot for agar.io

    • @anton7591
      @anton7591 6 років тому +211

      @@legoguney just Because it's old does not mean that it is bad

  • @zephyromenix8755
    @zephyromenix8755 4 роки тому +175

    Every single AI video: It’s evolving, just backwards

  • @ethanhoward389
    @ethanhoward389 3 роки тому +29

    Plot twist: hell release the second enigma machine video in the year 2048..he's leaving us clues

  • @agentstache135
    @agentstache135 5 років тому +717

    AI learns to play threes. Threes is a much more interesting game that was released before 2048. It takes a lot more strategy and just looks better

    • @Shennzo
      @Shennzo 5 років тому +19

      @Wax Meatley Funny thing is 2048 is the one that ripped off threes and gave it better graphics, that's what made it more popular

    • @seven_chords
      @seven_chords 5 років тому +7

      also the system behind the tiles added is much more complex in threes

    • @dominickeijzer5844
      @dominickeijzer5844 5 років тому +2

      You're the Illuminati.

    • @Ferotiq
      @Ferotiq 5 років тому +18

      Of course it was released before 2048, it isn’t even 2048 yet! It’s only 2019!

    • @dominickeijzer5844
      @dominickeijzer5844 5 років тому +3

      Wooosh.
      Edit: I wooshed myself.

  • @VoVilliaCorp
    @VoVilliaCorp 5 років тому +157

    "Yes, I can go to bed!" the typical software engineer saying after a project XD

    • @ITAC85
      @ITAC85 4 роки тому +3

      "I CAN, I just don't WANT to." - Typical Software Engineer ( not me)

  • @SpeedySlothBoi
    @SpeedySlothBoi 4 роки тому +65

    CB: keep the highest tile in the top left
    Tommy: how about... no?

  • @nbabackcourtmedia
    @nbabackcourtmedia 3 роки тому +19

    I finally beat this game after so many years, I can die happy now

    • @nbabackcourtmedia
      @nbabackcourtmedia 3 роки тому +1

      @HelloThere nothing crazy it just says you won and you can keep going if you want

  • @XanderLuciano
    @XanderLuciano 6 років тому +14

    Your sense of humor in these is simply amazing! Love it, doesn't matter how successfully or not your creations are, your commentary makes these 10/10. It's pretty cool to see what challenges you run into and what solutions you come up with to them. Interesting to see your different approaches :)

  • @ryanzwe
    @ryanzwe 6 років тому +85

    I found your channel from the enigma video, would be great to see some more!

  • @kiweping5
    @kiweping5 5 років тому +369

    If there was no visuals this would be the title:
    Man screams at someone (presumably his son) for 11 minutes and 10 seconds

  • @dalvontah
    @dalvontah 3 роки тому +20

    You’re teaching me better than my professors did

  • @itsme.lucaaa
    @itsme.lucaaa 5 років тому +597

    1:36 “let’s see what happens when we press the up arrow - aaaand they’re gone” 😂😂😂

    • @jakobbarbian2893
      @jakobbarbian2893 5 років тому +33

      Let's see what happens when we deposit this money, and its gone

    • @yoak
      @yoak 5 років тому +14

      Welcome to standing up school. And you failed..

    • @gjk-arts5855
      @gjk-arts5855 5 років тому +2

      Helix Peli asdf movie....
      And I love it

    • @yoak
      @yoak 5 років тому

      GJKtale - Gacha and undertale have you watched #12?

    • @gjk-arts5855
      @gjk-arts5855 5 років тому

      Helix Peli only that 1-11 complitition

  • @simplistxc6649
    @simplistxc6649 6 років тому +158

    He will single handedly create an AI that will destroy the world.

    • @farisakmal2722
      @farisakmal2722 6 років тому +8

      * Tommy launches nukes *
      *TOMMY NOOOOOOOOO*

  • @unrealcactus8546
    @unrealcactus8546 6 років тому +2612

    **Instant click**

    • @ginters5389
      @ginters5389 6 років тому +6

      bro same

    • @sciencelover4079
      @sciencelover4079 6 років тому +2

      Видео наоборот Watch my UA-cam channel it's about artificial intelligent taking over the world m.ua-cam.com/video/04vDiPiPyMs/v-deo.html

    • @memes3620
      @memes3620 6 років тому

      Видео наоборотy

    • @shawnyewest6812
      @shawnyewest6812 6 років тому

      Видео наоборот yeah

    • @Ida-xe8pg
      @Ida-xe8pg 6 років тому +1

      is this guy a hacker???

  • @MetaLemonaide
    @MetaLemonaide 3 роки тому +5

    Hey! I actually made a 2048 ai in college. Takes me back. Mine performed okay, but the algorithm was definitely trash compared to the top tier algorithms. Was satisfying to see it all work though.

  • @judithjanneck1719
    @judithjanneck1719 5 років тому +46

    You should have added to Thomas points for not moving the biggest tile. What I learned from playing this game constantly is that you should never move the biggest tile from his corner except there is no other way.

    • @VandreBorba
      @VandreBorba 5 років тому

      I don't know.... Give more points to a right strategy moviment is not a bit cheating?

  • @gnaskar
    @gnaskar 5 років тому +92

    1: don't give points for having the same number next to each other; the value of the that is recorded in the next state, not this one.
    2: reduce point value of a tile by 40% if the tile to the left is smaller and by 40% the tile above is smaller (this is a generalization of of keeping the biggest in the top left). If both are true the remaining value is 20%.
    3: Award a sizeable bonus for empty tiles. Honestly, an AI that just tried to minimize the number of tiles with numbers on them with 5 states look ahead would probably be fairly good at this game.

  • @Zandros
    @Zandros 5 років тому +188

    At 9:07 your A.I. was within 5 moves of victory and it made the wrong move. Luckily he got there still anyway a few seconds later

    • @Zandros
      @Zandros 5 років тому +7

      @CoRE Pyroz Right, Up, Left, Left. You're probably not looking at the same board configuration I am since the video is moving so fast.

    • @achilleaustin
      @achilleaustin 5 років тому +3

      9:08 up left left

    • @fuckdatmf3144
      @fuckdatmf3144 5 років тому

      right, up, left, left( there are alot of other ways ive also seen to instantly solve it but whatever)

    • @jamesr7708
      @jamesr7708 4 роки тому

      Yeah ikr down, right, up, left, left

    • @hesohit
      @hesohit 4 роки тому

      Thomas seems to always wants to solve the block from top left to right so at 9:07 he wanted to solve the top far right block next??

  • @Arvyx0
    @Arvyx0 7 місяців тому +1

    I love how back when he posted this he wasn't so unhinged and actually seemed like a calm guy doing coding for fun

  • @jacoby6000
    @jacoby6000 6 років тому +45

    Could you retry the neural network approach, but where the goal is to have a high number + fewer tiles on screen? Like, "success" is determined by the average tile value over time. That should help a lot, I would think.

    • @entropyzero5588
      @entropyzero5588 6 років тому

      Alternatively, keep the current algorithm and use a nn to evolve the fitness function: Determine all the possible ways to score a game state (total score, highest tile, adjecency, position of highest tile, …) and have the nn change the weight of those data points.

  • @jerrygeorge4478
    @jerrygeorge4478 6 років тому +94

    YOU PROMISED US!

  • @BaoCypher0912
    @BaoCypher0912 6 років тому +719

    I love this, can you try more complicated game ?

    • @realdragon
      @realdragon 6 років тому +41

      Like Super meat boy? Or The End is nigh

    • @alexanderreichert2966
      @alexanderreichert2966 6 років тому +1

      Like enigma

    • @1erRadiant
      @1erRadiant 6 років тому +8

      @fabi Lindner a teacher of mine did it ^^ but she said it is not really simple...

    • @Bestname_Ever
      @Bestname_Ever 6 років тому +6

      Mathis DANO ugh... i can almost smells the insanely complicated logic, calculus and possibilities reeking...

    • @eccotellsya2983
      @eccotellsya2983 6 років тому +58

      You guys need to keep something in mind, its not just coding the AI, he also has to code the entire game, which is the most time consuming part. That's the main reason behind doing "simple games".

  • @maximthemagnificent
    @maximthemagnificent 3 роки тому +5

    Seems like using NEAT to evolve an evaluation metric for the lookahead approach would be a useful fusion of the two methods.

    • @noahtawil8793
      @noahtawil8793 3 роки тому

      that’s how really advanced AIs like alpha zero work, they use the neural network to learn which parts of the game tree to look into

    • @MEANLEANBEAN
      @MEANLEANBEAN 3 роки тому +1

      Wow thats neat

  • @jeffreythecow2392
    @jeffreythecow2392 5 років тому +193

    Thomas: Is an AI and within 5 tries reaches 2048
    Me: can’t even get to 512

    • @3_ormorecharacters
      @3_ormorecharacters 4 роки тому +3

      I can barely get to 64

    • @WistfuII
      @WistfuII 4 роки тому +10

      A computer pressing random keys has gotten farther than I ever have.

    • @alexandrubragari1537
      @alexandrubragari1537 4 роки тому +3

      Stop to pretend to be so dumb lmao, its actually impossible to not to reach 256 even moving completely random i guess, anyway back at school my record was 8192 (+ 2 2048,so i wasnt really close to the 16k)

    • @teraspeXt
      @teraspeXt 4 роки тому +4

      @@alexandrubragari1537 It's not impossible. You just have to intentionally be stupid.
      Edit: I think it might be near impossible to not get to 32.

    • @williamsomlai141
      @williamsomlai141 4 роки тому +1

      ATS Gaming you gave me challenge, im getting under 32 and i will never stop trying

  • @eing7025
    @eing7025 6 років тому +166

    I clicked the subscribe button twice.
    I was already subscribed tho

    • @lochuynh6615
      @lochuynh6615 6 років тому +3

      When you walk 😂

    • @wiredfpz
      @wiredfpz 6 років тому +1

      there was no point of commenting that
      well done

    • @Parker05
      @Parker05 6 років тому

      Eing subscribe-unsubscribe-subscribed again. Thanks Eing, Very cool!!

  • @zxt327
    @zxt327 6 років тому +297

    I wonder how long it would take thomas to get to the 131072 tile. It would require a large amount of luck with tiles and probably takes trillions or more trials

    • @fotwen
      @fotwen 6 років тому +1

      ZX T I wonder that too. I had the same game going for months. Of course I didn't play it everyday. But it took forever. Mainly cause I had to fix mistakes. And of course it wasn't 4X4.

    • @chinesebaloni
      @chinesebaloni 6 років тому +14

      thommy will just print a tile with 131072 on it and call it gg

    • @flabort
      @flabort 5 років тому

      @@fotwen Have you tried the 5D? 2x2x2x2x2? (2x2 grids layed out in two 2x2 grids, wasd within a grid, rf to go up, qe for within the two metagrids, and zx to swap between those). Since it's 32 empty tiles instead of 16, two tiles spawn with each move.

    • @xanderh2404
      @xanderh2404 5 років тому

      @@TheeCK1357 It can, it's the theoretical maximum possible with a 4x4 grid. It requires a perfect arrangement of tiles to reach, and a 4 MUST spawn in the empty tile.

    • @garrettbowes4878
      @garrettbowes4878 5 років тому

      It can fit that but I had that block in the bottom left corner and the 4 in the bottom right. All other tiles where occupied by their highest possible value

  • @owltactics5540
    @owltactics5540 3 роки тому

    I some how keep arriving at your videos late at night when I am searching for vids to watch and I always get so fascinated by you content.

  • @potatomanW
    @potatomanW 6 років тому +90

    Your videos are great and the new animations are awesome

    • @chasem8393
      @chasem8393 6 років тому

      potato man lol I remember seeing you in a video comment forever ago and was like “is that machamp-weedle fusion” 😂

  • @meh3277
    @meh3277 6 років тому +755

    This was even more hilarious to me because my real name is Thomas but I rarely go by that anymore.

    • @im_tlnor
      @im_tlnor 6 років тому +14

      TedDoesGaming then what the ham sandwich DO you go by

    • @vigorouspringle8962
      @vigorouspringle8962 6 років тому +15

      Probably Tom

    • @aa-hf7hd
      @aa-hf7hd 6 років тому +3

      Vigorous dingle exactly my thought

    • @dirtydan1887
      @dirtydan1887 6 років тому

      TedDoesGaming brother

    • @dirtydan1887
      @dirtydan1887 6 років тому

      Vigorous dingle I like your channel

  • @musashiaerostar4409
    @musashiaerostar4409 4 роки тому +67

    7:50 - 7:52
    That made me laugh harder than it should

  • @calebdeming5515
    @calebdeming5515 3 роки тому +1

    You are my favorite UA-cam channel man. Love this shit

  • @Fattycheese73
    @Fattycheese73 6 років тому +445

    I think there’s an issue with the algorithm. In the actual game, part of the challenge is not knowing whether a 2 or 4 is gonna spawn. This especially matters when the board is almost full. Since the algorithm calculates what the board is gonna look like after 5 moves, then it already knows whether a 4 or 2 is gonna spawn in every one of those moves.

    • @boggers
      @boggers 6 років тому +111

      i think if the AI knew what would spawn where ahead of time it would be solving for 2048 every time very easily. What he should be doing is calculating for every possibility over a couple of moves and playing the "safest" path. Treat the RNG as an adversary, and minimise the damage it can do.

    • @4xelchess905
      @4xelchess905 6 років тому +30

      yeah, he is probably doing a min max algo over the tree of all possible moves AND spawns. Alternatively, he may be computing probabilities and expected gains on that tree.
      A refinement would be making a Monte Carlo search, since we know the distribution of spawning.
      If the AI knew what would spawn where ahead of time, it would lead to spawn manipulation abuse, where the AI deliberately chooses an objectively subpaar move because he knows it will be lucky (the spawn location has to depend on its move, since available locations depend on its move).

    • @jsmunroe
      @jsmunroe 6 років тому +16

      This is they same way chess algorithms work. They calculate all possible next stages for each of the next possible moves. He claims he goes 5 layers deep with this. That's a fairly massive search tree, but I guess if he has the computational power and/or the time he could do it.

    • @danielfay8963
      @danielfay8963 6 років тому +3

      Additionally a 4 only spawns 10% of the time, meaning you need to account for the probability of a given outcome when considering the risk/reward

    • @daniellucas5522
      @daniellucas5522 6 років тому +9

      Not that massive for this game. Chess has far more moves available in a turn, this one has only 4 moves and then the number of empty locations on the board left * 2 for where the next block will spawn.

  • @aohtr
    @aohtr 5 років тому +289

    He's so skilled

    • @azadanzans5359
      @azadanzans5359 5 років тому +2

      Djce games, i totally agree

    • @angel-np9kp
      @angel-np9kp 5 років тому +2

      HeS nOt EvEn ThAt GoOd

    • @blurooster5220
      @blurooster5220 5 років тому

      Heds Gaming he’s joking

    • @yolkeggs
      @yolkeggs 5 років тому

      Well Thomas tried his best
      Oh and CB did stuff too

  • @sacobred8400
    @sacobred8400 5 років тому +32

    me: *hears over-dramatic royalty-free music*
    also me: yeah dis the one

  • @zeonos
    @zeonos Рік тому +1

    4 years later and i am still waiting for that enigma video.... you cant leave me hanging like this :(

  • @quietsamurai1998
    @quietsamurai1998 6 років тому +59

    Why not use the game *length* as the evaluation function for NEAT? After a certain point, you can't just make random moves if you want to keep making moves. Each merge increases the game length by another move, so eventually an AI with a goal of maximizing game length would be forced to make a 2048 tile.
    That should make the fitness function far more fine-grained. Heck, you could probably do fitness=moveCount+2*maxTile to get the best of both, as any improvement in maxTile would be far better than ignoring a maxTile merge in favor of squeezing in a few extra turns.

    • @bryan1972ca
      @bryan1972ca 5 років тому +17

      I was thinking he could do something similar with the Algorithm. Instead of looking for valuing large numbers are good, valuing solutions where there are less tiles on the screen. So the algorithm tries not to lose instead of trying to win. This might make the game go longer and thus giving larger numbers.

    • @mittfh
      @mittfh 5 років тому +1

      Perhaps also a higher bonus for keeping the highest numbers on the top row, or have an incentive that after merging on the top row, restrict moves to 'up' and 'left' until the top right position is filled.

    • @gabrielgarcia9822
      @gabrielgarcia9822 5 років тому +2

      but then ones that do not move at all will win

    • @ninjafaceify
      @ninjafaceify 5 років тому +2

      @@gabrielgarcia9822 no, because it's not about length of time but number of moves, that's the length, not actual time

  • @Youmu_Konpaku_
    @Youmu_Konpaku_ 6 років тому +59

    _Ai learns how to take control of humanity_

  • @quack420
    @quack420 5 років тому +787

    2048... should have gone for at least 4096 or 8192

    • @MYcool1111
      @MYcool1111 5 років тому +44

      The game is called 2048 you win by getting the 2048

    • @quack420
      @quack420 5 років тому +62

      @@MYcool1111 yeah but you can continue afterwards just getting 2048 is sort of easy-mode

    • @MYcool1111
      @MYcool1111 5 років тому +9

      @@quack420 well yeah but maybe cb was just too lazy

    • @asticlol
      @asticlol 5 років тому +19

      My highscore is the 32k one

    • @Kdrews-tn8oy
      @Kdrews-tn8oy 5 років тому +6

      @@quack420 uh hell no it's ain't easy at all

  • @shawnsimons418
    @shawnsimons418 3 роки тому +17

    coding is just "if" statements
    - a wise man 2021

  • @Midnight-zq5op
    @Midnight-zq5op 6 років тому +612

    thOMaS

  • @prespickle9260
    @prespickle9260 6 років тому +563

    Do you *condone* the abuse of subscribe buttons?

    • @matthewbromley2956
      @matthewbromley2956 6 років тому +6

      PresPickle well maybe he doesn't. But I do so go abuse mine 😏

    • @SoggyCoffeeAddict
      @SoggyCoffeeAddict 6 років тому +11

      better question is, does he condone the abuse of ai

    • @FriskyD.
      @FriskyD. 6 років тому +5

      No, they're very delicate, they should be treated with utmost care

    • @ravenkhor
      @ravenkhor 6 років тому +2

      Chase Bishop unless you want it to create an uprising

    • @melon4249
      @melon4249 6 років тому +2

      PresPickle yes some have even been *ATTACKED* over 50,000,000 times

  • @ShashankPinchaG
    @ShashankPinchaG 6 років тому +233

    Enigma!!! Gimme me Enigma!

  • @Mothuzad
    @Mothuzad 3 роки тому +1

    Perhaps a better scoring algorithm would reward keeping tiles of the same value adjacent, and also somewhat reward keeping tiles of almost-the-same values adjacent.
    Also reward empty space, because that's your distance from the loss condition.

  • @juliloafers
    @juliloafers 6 років тому +5

    1:19 "They do a quick fusion dance..." Instantly subbed

  • @KaranBulani
    @KaranBulani 6 років тому +72

    I like this one but I'd love Enigma one

    • @C0reCoding
      @C0reCoding 6 років тому

      Karan Bulani Check my Channel...

  • @Julius-Ver
    @Julius-Ver 5 років тому +68

    7:55 watch the 128 tile Tommy using hacks exposed???

  • @geezus7152
    @geezus7152 4 роки тому +21

    Bullet here explains the definition of camping “TOMMY KEEP TOP LEFT”

  • @sturban7464
    @sturban7464 6 років тому +829

    Makes copys of games from scratch... Not a game designer.

    • @Mr.Fun-Gi
      @Mr.Fun-Gi 6 років тому +60

      Copies

    • @jazz4dayz543
      @jazz4dayz543 6 років тому +10

      WHOOSH

    • @TakingItCasual
      @TakingItCasual 5 років тому +84

      The design part has already been finished by the original. He's just reimplementing it.

    • @h1nkle
      @h1nkle 5 років тому +76

      That’s like saying someone who traces coloring books onto paper should be an artist

    • @nothingkayo3220
      @nothingkayo3220 5 років тому +13

      U guys can't even draw wimpy kid so get ur ugly as outta here.

  • @Lumiere_
    @Lumiere_ 5 років тому +30

    The future : If you can’t do something, program a robot to do it for you instead

  • @Snowiiwastaken
    @Snowiiwastaken 5 років тому +17

    „It‘s like Steroid Baby Steps“
    -Code Bullet 2018

  • @zimne5212
    @zimne5212 Рік тому +2

    I think you could add multiple things for improvement:
    1. moving the big tile ever out of a corner should be nearly as punished as losing
    2. you should also harshly punish not having some line from highest to smallest.
    With that and 5 steps in the future you should easily get 4096 consistently.

    • @jakerussell135
      @jakerussell135 Рік тому +1

      That wouldn't actually do very much. The best strategy that human players are able to use consistently is keeping your six largest tiles in a 2x3 rectangle on a corner. The order of the tiles within the rectangle doesn't matter, only the location of the smallest of the 6

    • @zimne5212
      @zimne5212 Рік тому +1

      @@jakerussell135 I think you are wrong, I was really competitive with a friend in school on this, and we both got to the 8192 tile (no redo button). And I can still do the 2048 tile without really thinking >90%.
      If you have the highest 4 from one side to the other small to high, you got 3 possible directions that won’t destroy your setup. If you go 2*3 you often only got 2. This might be enough for 2048, but not much more.
      If you don't have a correct order, you will have to make awkward moves at some point.
      I might be wrong though, if you got a more specific strategy and good success I would be interested.

    • @jakerussell135
      @jakerussell135 Рік тому

      @@zimne5212 try searching "839952" here on UA-cam. A game of 2048 by Stefan Popescu should show up. L That's the fourth highest known human score ever. It uses that 2x3 method as well. The benefit of the 2x3 method is that it actually allows you to use all four directions much of the time

  • @Raff-mu5qc
    @Raff-mu5qc 5 років тому +14

    "my man thomas looks 5 moves into the future" This is King Crimsons ability

  • @somerandomweeb1531
    @somerandomweeb1531 4 роки тому +43

    Watching this i thought "I thought the Ai was supposed to play the smartest move" Thomas proved me wrong.

  • @nicjansen230
    @nicjansen230 6 років тому +84

    program thOMaS to get 16384, because i only got to 8192 playing manually :P
    you should score gamestates with a 2 or a 4 in between of 16+ tiles very, very low
    the best way to die in this game is to get a newly spawned tile in between of your higher numbers

    • @nikoyochum6974
      @nikoyochum6974 6 років тому +2

      Nic Jansen I got the 16k tile a few years back on a stroke of luck. That was when I was in high school and literally played 2048 in all of my free time

    • @filipslatkovsky1657
      @filipslatkovsky1657 6 років тому

      Its actually not that hard to get 16k just takes a lot of time to get there

    • @jignaciocfnt
      @jignaciocfnt 6 років тому

      I got the 8192 too, not even try de 16k, i didn't think that was possible in the time i got the 8k xD get the 2048 is so easy, even now, its a little bit harder get the 4k, but still possible and easy... xD

    • @gurkensohn7807
      @gurkensohn7807 6 років тому

      my sister somehow managed to get to the 32k tile manually a few times (and she almost reached 65k once), but don't ask me how she did it, I can only get to 2048... she plays this game in every second of her free time though and the games in which she got 32k usually lasted a few weeks or so

    • @peenis8423
      @peenis8423 5 років тому

      One time I was playing on a the back of a plane seat after my phone ran out of battery and I was one 128 away from getting the 16k and the plane landed and my game got ended

  • @eyesak387
    @eyesak387 2 роки тому +2

    Crazy how much calmer and happier he sounded in his old videos

  • @THEcrosby
    @THEcrosby 5 років тому +19

    Code bullet: what starts with n and ends with o
    Everyone:no
    Code bullet :the real answer is yes

  • @frankweiler7121
    @frankweiler7121 5 років тому +7

    At 8:09 when you scream "Tommy, noo!" The video stops and the Google assistant pops up. Great feature 👍

  • @millo5014
    @millo5014 6 років тому +603

    AI learns Geometry Dash

    • @ginters5389
      @ginters5389 6 років тому +4

      I think someone did that, but he still should do that

    • @liam3491
      @liam3491 6 років тому +1

      Oh yes that would be fun

    • @unrealcactus8546
      @unrealcactus8546 6 років тому +10

      It sounds stupid, but I would like to watch

    • @thelenny2772
      @thelenny2772 6 років тому +4

      DutchDragonGames
      Also known as GD bot xddd.
      Maar alsnog een redelijk idee.

    • @maddixlabbe6787
      @maddixlabbe6787 6 років тому

      PLEEEEAAAAASSSSEEEEEE

  • @reubenransfield7914
    @reubenransfield7914 3 роки тому +1

    oh god.. 8:22 feels like when you’re on the last mission of a game and a slowed down instrumental version of the main theme plays…

  • @hyperionrobit3090
    @hyperionrobit3090 6 років тому +54

    E N I G M A D E C O D I N G V I D E O

  • @MaksKCS
    @MaksKCS 6 років тому +29

    In the year 2048 people are like "what?"

  • @sparkks1
    @sparkks1 4 роки тому +20

    CB: the theme for today is failure
    Me: that sounds like my life

  • @bryceboukater4618
    @bryceboukater4618 4 роки тому +25

    I love how many voice cracks he has, it makes him seem so much more human and relatable then these other youtubers with over 1 mil subs