-
Nepoate, așa bine am dormit! Am așteptat episodul de astăzi. Mai ales finalul lui. Să mă întorc la somn.
-
Deci azi vom mișca personajul și vom face animație 3D. De obicei, animația 3D necesită să facem un Armature cu Bones, adică oase. Însă personajul nostru e așa de simplu încât nu are nevoie de metode așa complicate pentru a-l anima.
-
Deci, Nepoate, nu avem nevoie de Bones? Nu că m-aș plânge. Fără oase cred că dormi nemișcat!
-
pthlptlhpt!
-
Yoohpey! Petrecerea gelatinelor!
-
Înainte de orice, trebuie să unim toate obiectele pentru a le putea deforma împreună și vom face asta selectând fiecare obiect cu click stânga în timp ce ținem apăsat de [SHIFT], iar apoi vom apăsa tastele [CTRL] + [J] pentru a le uni.
-
Acum că avem un singur obiect, trebuie să îi poziționăm originea, vom face asta mergând la meniul de sus al Editorului 3D și vom apăsa pe butonul Object - Set Origin - Origin to 3D cursor.
-
Mai avem nevoie și să mergem în Editorul Properties la butonul Modifiers, unde vom da click pe [+ Add Modifier] și vom scrie "subdivision", îl setăm pe Simple și punem cele două valori undeva de la 3 la 5, în funcție de cât de performant e calculatorul, pentru a crea mai multe fețe ca deformările să fie mai corecte.
-
Nepoate, de ce trebuie să aibă personajul mai multe fețe, nu e de ajuns doar una? Deși mai multe fețe înseamnă mai mult somn. Doar să nu-mi zici că ne mai trebuie mai multe mâini și picioare, că s-a zis cu somnul, e de domeniul visului!
-
pthlptlhpt!
-
Yoohpey! Petrecerea fețelor gelatinoase!
-
Acum că personajul e pregătit, putem să îl mișcăm, adăugând încă un modifier, de data asta "simple deform", și vom face asta de două ori pentru a avea o mișcare de umblat, unde personajul nostru se va turti pe verticală, deci pentru prima alegem Stretch pe axa Z, și se va îndoi în față, iar pentru a doua alegem Bend pe axa X. Acum, dacă punem amândouă valorile la 0, personajul va fi în poziția de început, iar dacă apăsăm click pe una dintre valori și tragem în stânga sau dreapta, vom vedea personajul nostru că se turtește și se îndoaie.
-
Nepoate, așa fac și eu când dorm! Numai că am ochii închiși. Și sforăi. Și nu mă mișc atâta. Și nu tare fac așa.
-
pthlptlhpt!
-
Yoohpey! Petrecerea adormită nedormită!
-
Acum că personajul se poate mișca, trebuie să îi "înregistrăm" mișcarea în keyframe-uri și pentru asta avem nevoie să vedem mai bine Editorul Timeline, așa că vom trage de laterala de sus pentru a-l mări și vom vedea că avem un cursor temporal pe care îl putem mișca cu click stânga sau dând play, apăsând butonul de pe ecran sau tasta [Space] pe tastatură. Atunci când dăm play, cursorul nu se va opri la final, ci va reîncepe animația de la început pentru a putea vedea dacă se repetă corect, ceea ce e util pentru noi când facem animații pentru un joc. Însă noi nu avem nevoie de o animație așa de lungă, așa că în meniul de sus al Editorului Timeline vom da click pe End și vom trece 24, care este echivalentul unei secunde.
-
Pentru a pune un keyframe, prima dată trebuie să poziționăm cursorul temporal la Frame-ul dorit, iar noi vom începe de la primul, după care trebuie să apăsăm tasta [I] deasupra valorii pe care vrem să o salvăm, o dată ce am modificat-o, ceea ce va face câmpul valorii galben pentru a ne arăta că avem un keyframe la Frame-ul prezent. Deci, la Frame 1, punem valorile să fie la 0 și le dăm keyframe.
-
Nepoate, keyframe-ul ăsta 1 nu face nimic! Nu că m-ar deranja, că e mai ușor de dormit atunci când nu te miști. Dar nu trebuia să se și miște?
-
Ba da, Bunicule! De aceea vom mai pune mai multe keyframe-uri, pentru ca Blender să miște personajul între ele. Mergem la jumătatea perioadei de timp, adică la Frame 12, unde vom înclina personajul în față și îl vom turti pentru un keyframe,
-
iar pentru ultimul keyframe la Frame 24 vom reveni la valorile 0.
-
Dacă vrem să ștergem un keyframe, putem da click stânga pe el în Editor și apăsa tasta [Delete] pe tastatură pentu a-l șterge. Pentru a corecta animația de turtire, mai putem adăuga un obiect Empty, care îl poziționăm la mijlocul personajului și, mergând înapoi la Editorul Properties cu personajul selectat, putem schimba câmpul Origin pentru Stretch modifier, unde vom trece numele acelui Empty. Acest lucru va face mai fluidă animația de turtire, însă acum personajul se va ridica de pe podea.
-
Acum și sare personajul, Nepoate?! Deja era multă mișcare când doar umbla, dar acum mai face și sărituri? Parcă îmi aduce aminte de cineva... oare de cine?...
-
pthlptlhpt!
-
Yoohpey! Petrecere săritoare! Îmi plac petrecerile săritoare! Îmi plac! Îmi plac! Îmi plac!
-
Pentru a pune personajul înapoi pe podea, trebuie să îi punem niște keyframe-uri la poziție și putem face asta mergând la primul Frame, iar dacă dăm click dreapta pe personaj va apărea un meniu în care apăsăm opțiunea Insert Keyframe, lucru pe care îl vom repeta și la frame 12 și 24, după ce îl poziționăm corect cu ajutorul uneltei Move. Aceeași metodă e folosită și pentru a pune keyframe și la Scale și la Rotate, fapt pe care îl putem folosi pentru a putea face animații diferite, cum ar fi rotirea unei monezi.
-
Păi, Nepoate, eu unul voi folosi ce am învățat ca să animez personajul meu cum doarme, că e mai simplu. Nu tu sărituri și învârtiri. Doar liniște și sforăit.
-
pthlptlhpt!
-
Yoohpey! Petrecerea sforăitului zgomotos liniștit!
-
Un pas care nu e obligatoriu, însă poate fi urmat pentru a stiliza personajul nostru, e să îi adăugăm un contur din meniul de sus al Editorului 3D, de la Add - Grease Pencil - Empty.
-
În Editorul Properties vom adăuga un modifier, la fel ca și la mișcarea cubului, și vom căuta "Line Art". Trebuie să îi schimbăm setările pe Object, după care putem alege personajul nostru folosind pipeta și dând click pe el, apoi la Layer și Material vom alege opțiunile pe care ni le oferă. Grosimea liniei poate fi schimbată de la slider-ul Line Thickness. Mai jos, sub meniul Edge Types, putem bifa mai multe căsuțe, iar pentru a obține doar conturul personajului, vom debifa toate căsuțele, mai puțin prima, căruia îi vom schimba modul pe Silhouette.
-
Hei, Nepoate! Personajul tău seamănă acum cu unul din desenele pe care le face Nepoata la grădiniță! Mereu am vrut să aflu de la cine a învățat să le facă... că așa de repede le face încât nici nu mai am loc pe frigider unde să le pun!
-
pthlptlhpt!
-
Yoohpey! Petrecerea frigiderului artistic!
-
Pentru a termina animația personajului nostru, trebuie prima dată să poziționăm camera într-un unghi bun, la jocul nostru având nevoie de unul din lateral. Pentru a folosi aceeași perspectivă ca și în GDevelop, trebuie să selectăm camera și să mergem la Editorul Properties, unde vom pune camera pe Type Orthographic. Valoarea de sub Type, Orthographic Scale, e folosită pentru a micșora sau mări unghiul de vedere al camerei, pentru că în tipul de cameră Orthographic obiectele sunt de aceiași mărime indiferent de distanța camerei, astfel având nevoie de această valoare pentru a încadra corect personajul.
-
Tot din Editorul Properties vom alege rezoluția imaginilor, iar pentru jocul nostru avem nevoie de x: 170 și y: 118. Mai jos în listă putem alege unde să fie exportate pozele pe care le vom face când randăm animația apăsând pe butonul de Folder, iar apoi trebuie să verificăm că opțiunea RGBA e selectată pentru a putea avea fundal transparent.
-
Acum că setările sunt pregătite, putem alinia camera și luminile așa cum ne dorim, asigurându-ne că personajul nu e centrat, ci e mai în partea stângă a pozei, apoi dăm Save pentru a nu ne pierde munca și putem să mergem în meniul principal de sus ca să dăm Render - Render animation! Acum tot ce a mai rămas e să aștepți până e gata.
-
În sfârșit, Nepoate! Acum pot și eu să mă duc să mă culc până ce e gata randarea.
-
pthlptlhpt!
-
Yoohpey! Petrecerea randării sărite și adormite!
-
În episodul următor vom vedea cum să terminăm peronajul, creându-i fața, dar până atunci mai avem nevoie și de alte obiecte, cum ar fi pietre, tufe, monezi, copaci...
-
Nepoate, putem face și o căpiță de fân? Că pe pietre e mai greu să dormi, iar în tufișuri nu prea merge.
-
pthlptlhpt!
-
Yoohpey! Petrecere de dormit în copaci!
-
Așa că exersați-vă talentul! Făceți-o de plăcere! Creați mai multe animații în fișiere diferite pentru personajul nostru, de sărit și de a se feri, pentru că vom avea nevoie de ele în joc și distrați-vă în timp ce faceți asta! Eu știu că o voi face!
-
pthlptlhpt!
-
Yoohpey! Petrecere plăcută!
-
I slept so well, Nephew! I've been awaiting today's episode. Especially the end of it. So I can go back to sleep.
-
So, today we will get to moving the caracter and make some 3D animation! Usually 3D animation is done using an Armature with Bones, but our character is so simple that it doesn't need such complicated methods to make animations with.
-
So, Nephew, we don't need bones? Not that I'm complaining. I think without bones you can sleep without moving at all!
-
pthlptlhpt!
-
Yoohpey! Sleepy jelly party!
-
Before we do anything, we need to join all our objects together so we can deform them all at once. We will do this by selecting every object with left click while holding down SHIFT and then press [CTRL] + [J] to join them all together.
-
Now that we have a single object, we need to position its origin, the orange dot, which we can do by going to the menu at the top of the 3D Editor under Object - Set Origin - Origin to 3D cursor, setting the origin to the centre of the floor.
-
We also need to go to the Properties Editor, where we will go to the Modifiers tab, clicking the [+ Add Modifier] button and then writing "subdivision", adding the modifier and then setting it to simple, as well as changing the values to somewhere between 3 and 5, depending on how much your computer can handle, the more faces it has making the object look smoother.
-
Nephew, why does it need to have more faces, isn't one enough? Though, more faces means more sleep... Just don't tell me we need more arms and legs too, cause then it's over with the sleeping, that's in dream territory!
-
pthlptlhpt!
-
Yoohpey! Jelly face party!
-
Now that our character's ready, it's time to move it! We will add another modifier, this time searching for "simple deform", which we will add in twice to make the walking motion. The first one will be a Stretch on the Z axis, squashing it vertically, and the second one will be Bend on the X axis so it can lean forward. Now, if we set both of the modifier's values to 0, the character will return to the starting position, and if we click and drag either of the values left and right, we will see it squashing, stretching and leaning.
-
Nephew, that's exactly what I do when I sleep! Except I have eyes, and they are closed. And I'm snoring. And I don't really do that at all.
-
pthlptlhpt!
-
Yoohpey! Unsleepy sleep party!
-
Now that the character can move, let's "record" it in some keyframes, and for that we will need to make the Timeline Editor a bit bigger, so we will pull the top of it higher. We can now see a time cursor which we can move left and right through time by using left click, or let it cycle through the animation by pressing the play button or [Space] on our keyboard, looping from the beginning once it reaches the end which is useful for something like our walk animation to see if it can keep going properly. We do not need an animation as long as the current timeline, so we can change its length by going to the top menu of the Timeline Editor on the right and clicking the field for the End value, where we can type 24, the number of individual frames that make up a second in Blender by default.
-
To put down a keyframe, first we need to align the time cursor to the frame we want, in our case going to frame 1, and then we can insert a keyframe by hovering over the value and pressing [I] on the keyboard after we've modified it to be in the right position, which will turn the field yellow to show us there is a keyframe on the present frame.
-
Nephew, this keyframe on frame 1 doesn't do anything! Not that I'm complaining, it's easier to sleep when you're not moving. But... wasn't it supposed to move?
-
Yes, Grandpa! That's what we'll need multiple keyframes for, so Blender can handle moving the character in the frames between. We will now go to the halfway mark of the animation, frame 12, where we will adjust the values so the character is leaning forward and gets squished a little bit,
-
then go to the end, frame 24, where we will bring the values back to 0, making sure to put keyframes for both.
-
If we want to delete a keyframe, we can left click any of the dots in the timeline and press the [Delete] key on our keyboard to remove it. To fix the squish animation, which doesn't look very natural right now, we need to go to the Add button and select Empty, which we will position at the centre of the character's body. Back in the Properites Editor, with the character selected, we can change the Origin field of the Stretch modifier to be the Empty object we just added. This way, the squish motion will be more natural, but we can notice the character being lifted off the floor because of it.
-
It's jumping now too?! Nephew, there was already enough movement when it was simply walking, now it also does jumps? I think it reminds me of someone... I wonder who?...
-
pthlptlhpt!
-
Yoohpey! Jumping party! I like jumping parties! I like! I like! I like!
-
To get the character back on the ground, we can keyframe its position, which we will do at the first frame by putting it into position with the Move tool and then right clicking on it, selecting Insert keyframe from the menu that opens up, steps that we will repeat for frames 12 and 24. This same method is also used to keyframe rotation and scale of the objects, allowing you to make diverse animations, like the spinning of a coin.
-
Well, Nephew, I will use what I've learnt to animate my character sleeping, because it's easier. No jumping or spinning. Just silence and snoring.
-
pthlptlhpt!
-
Yoohpey! Silently loud snoring party!
-
A step that's not mandatory, but can be done to further stylise your characer, is to give the character an outline by going to the menu at the top of the 3D Editor, and click on Add - Grease Pencil - Empty
-
In the Properties Editor we will add a modifier, just like we did for the deforming of the cube, and we will search "Line Art". We need to change the settings of the modifier to Object, and then we can select the cube by clicking on the eyedropper tool and then using it on the character. For Layer and Material we just have to select the only options it shows us, and we can change the Line Thickness to our liking. Since we only want the outline of our character, we need to untick all boxes from Edge Types except the first, for which we will change the option to Silhouette.
-
Hey, Nephew! This character of yours now looks like one of the drawings Niece makes at kindergarten! I always wanted to know who she learned how to do that from... because she draws them so fast I'm running out of space for them on the fridge!
-
pthlptlhpt!
-
Yoohpey! Artistic fridge party!
-
To finish the animation of our character, we need to first put the camera in a good position, which will be a view from the side to suit the game we will be making. To use the same perspective as GDevelop, we need to select the camera and go to the Properties Editor, where we will change the camera Type to Orthographic. The value below the Type, Orthographic Scale, is used to grow or shrink the viewing angle of the camera, because in Orthographic mode the distance to the camera does not make objects appear bigger or smaller, thus needing this value to properly frame our character into the camera.
-
We will also change the resolution of the exported images from the Properties Editor, setting it to x: 170 și y: 118 for our game. Further down the same page we will find the Output section where we can set the location of the images by clicking on the folder button and then choosing a suitable location. Once we confirm it and close the window, we also need to check that the option RGBA is selected for a transparent background.
-
With all the settings ready, all we need to do is line up the camera, adjust the lights to look pretty, making sure our character is not centered, instead a bit towards the left, and then remember to Save so our work is not lost before going to the main menu at the top and hitting Render - Render Animation! All that's left to do now is wait until it is finished.
-
Finally, Nephew! I can go get some sleep until the rendering is finished.
-
pthlptlhpt!
-
Yoohpey! Sleepy jumping render party!
-
In the next episode we will see how to finish the character, making a face for it, but until then we will also need other objects, like rocks, bushes, coins, trees...
-
Nephew, can we also make a haystack? It's kind of hard to sleep on rocks, and sleeping in bushes doesn't really do it either.
-
pthlptlhpt!
-
Yoohpey! Sleeping in trees party!
-
So, practice your talent! Enjoy yourself! Create multiple animations in separate files for our character, for jumping and ducking, because we will need them in the game we will make, and have fun while you work! I know I will!
-
pthlptlhpt!
-
Yoohpey! Pleasant party!