TypeScript is better than C for this
ฝัง
- เผยแพร่เมื่อ 2 ต.ค. 2024
- Streamed Live on Twitch: / tsoding
Enable Subtitles for Twitch Chat
More Episodes: • Raycasting in TypeScript
References:
- Tsoding - Raycasting - github.com/tso...
- lodev.org/cgtu...
- tsoding.github...
- github.com/tso...
- mariusschulz.c...
Support:
- BTC: bc1qj820dmeazpeq5pjn89mlh9lhws7ghs9v34x9v9
- Pay for my VPS: zap-hosting.co...
32:08 looking forward to the Nuclear Reactor episode
Next video: We are developing nuclear reactor in Typescript
меня поражает твое трудолюбие и нескончаемый энтузиазм
I really still do not procees the fact that you are writing in ts. I am so used to see you writing c code.
Yeah and also his famous “C voice” contributes to the overall confusion
@@tianned I see you saw the last episode
@@tiannedI have yet to figure out tf a "C Voice" is?
@@blackbeard3449 You will soon C.
hmm, thats a weird looking C... whats going on here, a-mista a-Zozin?
The thumbnail of the video is really good!
I will see tha day where this guy will make a fucking audio driver in TypeScript.
59:00 lighting is actually very easy, at least for simple diffuse shading. Just take the cosine of the angle between the normal vector and the incoming light direction (a simple dot product with normalized vectors does the trick)
I recently (a few months ago) followed this exact raycasting guide for a 'school' project with a team mate, we did it in C, it was really cool.
I went a little further than the guide, I added transparency, where a ray could go through a cell if it was marked as transparent, it would record the depth etc then continue.
The renderer would then draw the walls furthest to closest.
Everything was single threaded, 960x960 30fps, ~30 million pixel read writes per second best case. (in reality a lot more)
We made "3D" doors that slowly open, we made an enemy that follows you, and we made mini-games you interact with (among us style).
My favorite part was the Event Trigger System, where entities can emit events and receive events, so you can wire up entities to interact with each other.
Say you have a task and a door, the door will only become unlocked if you complete the task, it was such a simple idea, but it takes the complexity of the map to the next level with so much customisation.
really cool project, did you put on github?
42 school?
@@Eldarlll yup
WAIT! WAT?! Zozz admits TS can be better than C?!?#@#$%
I do not believe you go comment comment copying it from the comments on twitch and pasting in the subtitles on you tube, can you share the script you used for that?
1:13:10 He wasn't clueless. He straight up posted documentation how to draw image to canvas from img element and also how to load it using url. Also you can use the drawImage function that you pass it to draw part of the image even one pixel which was part of the documentation that he posted.
Edit: I see you have gotten it later in the stream - that you can use img element + drawImage like that :D
Yes I really hate when he claims people are trolling when the page they posted exactly describe that.. but yeah it’s steaming and you can’t read everything, but then …
1:41:00 maybe dirty backbuffer?
If you don't need raw image data, maybe you don't need web server anymore, btw
Tsoding you posted this at the best time, I wanted to make a simple classic 1st person dungeon crawler but didn't know the algorithms or techniques used...and you just started doing it for me! Thank you sensei
54:26 you could use hsl() style. There is a whole science on dimming colors for human perception and also gradients (maybe using LCH color model)
Tsoding cheating on C 😔 with typescript
26:15 i guess it’s technically valid js but a number - undefined is NaN which is probably not what you want there?
Speaking about rendering using div's reminds me of threejs CSS render.
word, loving the subtitles being modded to chat, insane
No, nothing is better than C 😭
In the last bit of the video 2:19:56, you might to consider reverting u back to 1 - y but keeping the condition. Images were flipped when viewed from behind.
23:00 it is because of variable hoisting
const & let vs var & function
function is hoisted up before const/let ctx was declared. So the language server does not know if you are using something that does not exist yet, don't know if it would even work
Yup you got it, I came here to say the same thing
23:40 this is typescript fault, works in javascript if function is CALLED after variable definition
sirios beetboxing starts at 39:19
The difference between function expressions and function declarations in JS tends to bite.
Because lately your videos can no longer have subtitles in Spanish c:
1:13:05 the struggle is real lmao
JavaScript is a Messi language, TypeScript is just messy
56:07 HOLY SHIT THIS IS SO COOOOLLL!!
i want a nuclear tractor stream
It is more convenient control when the camera rotates to the right when A+S is pressed together.
Can someone tell me what color scheme he’s using? Thx
2:03:01 Its Unfinished!
I do not believe you go comment comment copying it from the comments on twitch and pasting in the subtitles on you tube, can you share the script you used for that?
It's part of the markut repo on his github
1:29:34 I like to aim the onload handler before triggering it (assign src after that)
Already caught this on Twitch. Great work!
56:40 it's the 'Fog of Pog' 🌫️
Thank you.....
tscoding
Holy shit cool!
Партизан!!
1:39:49 "Dirty Rectangles" are why the dirtyX, dirtyY, dirtyWidth, and dirtyHeight params are named as such. It's graphics programming terminology. Has nothing to do with web devs making weird naming decisions. Took me like 5 seconds of searching to find this out.
wOoooOOo000OoOoOoOOo
Typescript is a joke
no if you really want to learn how to program you need to start from the basics... writing html code
@@weekipi5813 No, start with C.
Where do ya get all these articles ?
From the Internet
dark web
XD
dread
How about making PHP statically type language. HeeHee ??
This tutorial also works in typescripttolua running in minetest hud system. I love it
DAS MANIFESTTTT
Oh no, that's Jordan4IBanez on my favourite channel!
Never expected to see you there.
32:27
2:09:49