i've never made a snake game ever in my life, and seeing somebody make it with such ease puzzles me, and gives me a earthshattering migraine
@badatvideogames-XD3 күн бұрын
nice game engine
@Nascho_Neese6 күн бұрын
Here's a piece of JavaSh!t: let x = y + x; let y = x + y;
@ajreukgjdi946 күн бұрын
I never have captions on. I never know why they magically turn themselves on sometimes, but I'm so glad they did for this video.
@bleqy305710 күн бұрын
honestly how do you avoid the first one?
@nikolakosanovic993111 күн бұрын
I would like to know how to make first one differently
@nikolakosanovic993111 күн бұрын
What is wrong with fizz buzz program? Do you think enters or curly brackets Or do you mean you shouldn't use else if but return
@usemorewood318416 күн бұрын
I use alert(“Fuck”) all the time to debug my code
@Raigmund.A.Solvgrim21 күн бұрын
1:01 ancient programmers be like:
@PC-coolant-pipe-sucker21 күн бұрын
the -rf is a good reminder that linux is for lesser creatures
@chrisalex8225 күн бұрын
The thumbnail.pztrified me
@chrisalex8225 күн бұрын
You know, sometimes you get to a point where you arent scared anymore, but just fascinated
@stunnnsemerald26 күн бұрын
My favorite is the if (!false) { } Because there's nothign wrong with it but it infuriates me
@ivanmeotto427126 күн бұрын
Okay the even/odd one is actually kinda smart
@d2aio26 күн бұрын
1:04 german versions: `"ungerade"[2*(num&1^1):]` or `"un"*(num&1)+"gerade"`
@matthewlloyd325528 күн бұрын
I actually find one of those code examples useful from time to time. F(a,b) = return f(a,b) is sometimes useful where you're porting code from mixed languages and sometimes the only difference between the two languages is the case sensitivity of the functions...and someone's gone and named things a certain way in their libraries.
@supremepvp210929 күн бұрын
0:13 it is !false that i died laughing, because I returned true
@gormsterАй бұрын
It’s a big patch Expensive patch This patch had better fix some bloo-oo-oody bugs
@nuirejuvini9951Ай бұрын
salsa no peas
@chipproductions1510Ай бұрын
War… war never changes..
@32thАй бұрын
1:31 if you were using the Windows API there, you could do Sleep(0), which basically just tells the OS's scheduler to give time to a different process without specifying an amount of time the scheduler should NOT try to give time to the current process. This is great if you need to check something like this in an infinite loop, and don't want your program to have 100% CPU usage. Or you can use FindFirstChangeNotification (or whatever it's equivalent in the filesystem API of your choice is)
@fusion.studioXАй бұрын
that aint programming that progaming
@linuxguy1199Ай бұрын
0:22 That is in no way shape or form a cursed SQL query, I've seen FAR FAR worse in production code.
@TheRhalfАй бұрын
wait, what would you do instead of that big ass switch in the beginning tho?
@axoodleАй бұрын
0:52 java scripture
@TheMohawkNinjaАй бұрын
0:46 If anyone tried to give you shit about it, just point out that you are assigning "children" to it, meaning that "coloredChildren" is equal to "children".
@Blonder_StudioАй бұрын
1:38 oh boy im an indie game dev making a game in Unreal Engine and ho boy this hits close to heart man hahahaha
@JayaTemara-oq5fqАй бұрын
0:42 I thought it was Hymnos
@Palmtop_UserАй бұрын
In ti basic i made a snake game that was 402 bytes counting the name "snake". I had to abuse financial variables and arrays while using the difference between the left and right keys and an imaginary number based variable to control direction. Believe it or not the imaginary number was the smallest way to handle control as it was just math. It works but even i struggle to understand it years later
@lucasgreer1736Ай бұрын
how???
@Palmtop_UserАй бұрын
@lucasgreer1736 so left and right are 24 and 26 respectively. You get the key and subtract by 25, meaning all that its left is -1 or 1: this will be K (all single numerical variables in ti basic are just single capital letters). D will store direction as an imaginary number you do "KDi->D" so D=K*D*i in most any other language (ti basic lets you write functions as you would in math, anything next to eachother is multiplied). This will basically update what direction you turned in by making it imaginary if its not imaginary or vice versa with K modifying if it becomes negative or not. Then "real(D{4i,6->L1" will basically shove only whatever is real into L1 (a list) leaving the other as zero setting which way you move in the process. Remember i*i=-1. 4 and 6 are there just to tell later code how far horizontal or vertical it should move. Just those two lines after handling the keys alone handle the direction you turn towards. The math just works out
@Palmtop_UserАй бұрын
@lucasgreer1736 so the code (omitting a bunch of stuff) is 1->D While 1 repeat Ans ... //the game getkey end ans-25 DiAns->D real(Ans{4i,6->L1 end Firstly lets remember i*i == -1. Secondly TI-BASIC is weird, "->" is how you set variables, with the variable on the right of the arrow being the one set. All normal number variables are single capital letters, you have no choice in their name, A-Z (with exceptions) is all you get. Also it lets you write expressions like you do in math: anything written together is multiplied. "Ans" is a variable that is always the result of the last expression, its technically faster (and smaller since you dont set anything) which is why its written this way. "Repeat" is basically a "do {} while(not(x))" loop if youre familiar with C. It will basically always enter that loop at least once and exit that loop if the thing, in our case the Ans of getkey, isnt zero. You can multiply to all elements of arrays, ex. 2*{3,4} == {6,8} Anyways the meat on "how". Essentially the left and right keys return 24 and 26 respectively, so subtracting 25 will return -1 and 1. "DiAns->D" will therefore return 1, i, -1, and -i, in order if Ans is 1 and 1, -i, -1, and i if Ans is -1 each time it handles the key. Its processed further in "real(Ans{4i,6->L1" to be set in a list that makes any imaginary part of the expression zero, therefore only resulting in one element having a value that isnt zero, separating horizontal from vertical. 4 and 6 are there to tell the program how far to move per cycle horizontally and vertically.
@Palmtop_UserАй бұрын
@lucasgreer1736 basically taking advantage of the fact the left and right keys can simply be subtracted by 25 to result in -1 and 1 and that i*i=-1