Why you should clean your code with Extension Methods!

preview_player
Показать описание

-------

Extension methods can make your code dramatically easier to read and understand, all while removing unnecessary duplication. Learn how to create your own along with a few very useful examples of extension methods I use every day.

Рекомендации по теме
Комментарии
Автор

+Unity3d College, Your expertise in computer science and game development clearly shows in every video. I haven't seen this level of competence in any other tutorial/educational series for game development. Thanks so much for sharing years of hard work and knowledge with those of us just starting out =).

KirbyGC
Автор

Nullable & assignable parameters? Cool, thanks. Had no idea.

thinkofwhy
Автор

Though it may be a very long time before I can afford your course, I'm glad you have so much useful content on youtube for free.

Really saves people like me who want to get into game dev but just don't have spare cash. Thank you a ton.

pj-wille
Автор

Very useful! It is this basic-to-intermediate stuff which I find most helpful as I am still learning C# and Unity. That transform.position.y = someFloat was the perfect example I could relate to! Big thanks!

woodenfences
Автор

This is amazing!

I've come from JS and I'm losing a lot of stuff to learn in my way to Unity3D and C#. Your videos are helping me a lot, keeping apart the basics and diving into good practices, game dev patterns and a lot of medium and senior stuff I couldn't find anywhere else.

Thanks a lot for your videos.

AlbertoFdzM
Автор

For a total coding beginner like me, that was really helpful. Explained very clear and presented with easy to follow examples. Thank you very much, it will be put to good use.

Frank_G_Finster
Автор

Nullable & assignable parameters? I was like magic code' :D you're standing above the crowd of all tutorials I've ever seen in each videos

ludovicmahieu
Автор

Wow, this is quite a few things I did not know about C# Thanks a lot!

Defectoms
Автор

I always learn so much watching your videos! Thank you

baroquedub
Автор

This is so cool! Now I shudder at all the refactoring I probably should be doing..

deepshipalpha
Автор

I have watched several of your videos now and am really liking stuff like this. Always wanted to know how to do this because using multiple classes / extension methods / state managers to split my code up has always been my biggest weak point.

digitalconsciousness
Автор

Thank you so much! I've been coding for like a decade and never learned about nullable parameters. Extension methods are pretty cool too.

brandobin
Автор

Been looking for something like this since I started my game development journey.. Thank you so much!!

youcancallmedoggie
Автор

A lot of useful little tools in one video. Thank you!

stefano
Автор

Learned a lot of new things here. Thanks!!

kuraikage
Автор

Thank you very much. I hope u release more video like this. It's very helpful

victorlee
Автор

You deserve a lot more subs & views than you already have!!!

piyushmayekar
Автор

Once again, an awesome vid on a subject that's on my 'To Study' list. Thank you so much! XD

TsetTsyung
Автор

thanks this was totally new to me. Very cool

TChrisBaker
Автор

Here is a similar extension directly for Transform class: You can basically do the same thing in the video with only writing transform.With(y:0); instead of transform.position = transform.position.With(y:0);

public static class TransformExtension
{


public static void With(this Transform original, float? x = null, float? y = null, float? z = null)
{
original.position = new Vector3(x ?? original.position.x, y ?? original.position.y, z ?? original.position.z);
}
}

furkankocak