All language subtitles for 006 Wall Slide Animation and Wall Jump[UdemyIran.Com]

af Afrikaans
ak Akan
sq Albanian
am Amharic
ar Arabic
hy Armenian
az Azerbaijani
eu Basque
be Belarusian
bem Bemba
bn Bengali
bh Bihari
bs Bosnian
br Breton
bg Bulgarian
km Cambodian
ca Catalan
ceb Cebuano
chr Cherokee
ny Chichewa
zh-CN Chinese (Simplified)
zh-TW Chinese (Traditional)
co Corsican
hr Croatian
cs Czech
da Danish
nl Dutch
eo Esperanto
et Estonian
ee Ewe
fo Faroese
tl Filipino
fi Finnish
fr French
fy Frisian
gaa Ga
gl Galician
ka Georgian
de German
el Greek
gn Guarani
gu Gujarati
ht Haitian Creole
ha Hausa
haw Hawaiian
iw Hebrew
hi Hindi
hmn Hmong
hu Hungarian
is Icelandic
ig Igbo
id Indonesian
ia Interlingua
ga Irish
it Italian
ja Japanese
jw Javanese
kn Kannada
kk Kazakh
rw Kinyarwanda
rn Kirundi
kg Kongo
ko Korean
kri Krio (Sierra Leone)
ku Kurdish
ckb Kurdish (Soranรฎ)
ky Kyrgyz
lo Laothian
la Latin
lv Latvian
ln Lingala
lt Lithuanian
loz Lozi
lg Luganda
ach Luo
lb Luxembourgish
mk Macedonian
mg Malagasy
ms Malay
ml Malayalam
mt Maltese
mi Maori
mr Marathi
mfe Mauritian Creole
mo Moldavian
mn Mongolian
my Myanmar (Burmese)
sr-ME Montenegrin
ne Nepali
pcm Nigerian Pidgin
nso Northern Sotho
no Norwegian
nn Norwegian (Nynorsk)
oc Occitan
or Oriya
om Oromo
ps Pashto
pl Polish
pt-BR Portuguese (Brazil)
pt Portuguese (Portugal)
pa Punjabi
qu Quechua
ro Romanian
rm Romansh
nyn Runyakitara
ru Russian
sm Samoan
gd Scots Gaelic
sr Serbian
sh Serbo-Croatian
st Sesotho
tn Setswana
crs Seychellois Creole
sn Shona
sd Sindhi
si Sinhalese
sk Slovak
sl Slovenian
so Somali
es Spanish
es-419 Spanish (Latin American)
su Sundanese
sw Swahili
sv Swedish
tg Tajik
ta Tamil
tt Tatar
te Telugu
th Thai
ti Tigrinya
to Tonga
lua Tshiluba
tum Tumbuka
tr Turkish
tk Turkmen
tw Twi
ug Uighur
uk Ukrainian
ur Urdu
uz Uzbek
vi Vietnamese
cy Welsh
wo Wolof
xh Xhosa
yi Yiddish
yo Yoruba
zu Zulu

Original subtitles

The wall slide is technically working now from a gameplay perspective, but it still doesn't look like

we're sliding down the wall because we have to play the animation.

And that's what we're going to do in this video, and also implement the actual wall jumping so we can

jump from one wall to the other.

Adding the animation is actually very easy, since in our logic for the wall sliding we already have.

This is wall sliding boolean, so we just have to use this in the animation blueprint.

In the content drawer, we go to Content Blueprints, Character player and ABP player.

And in here we already know we can only go into the wall slide while we are falling.

So the only place where we need to add transition is from falling, right?

So from fall we have another animation state and this is wall slide.

And we just double click to open it up.

And here we just play.

Wall slide.

But actually we also need to have the wall slide shooting because we can also shoot while we are sliding

down the wall.

So like for the other places like the fall for example, we also have the select animation by bool.

So we can just copy this, control C and go to the wall slide.

And instead of just connecting this here just the control V to paste this in here.

And yes, so if we are shooting we want to play the wall slide with the shooting.

But if we are not shooting we just want to play the wall slide.

Right.

So false is the wall slide and true is the wall slide shoot.

And again these are animations.

We registered on the animation source before.

And now back in the locomotion.

This is working.

We just need to set up the condition now.

So from the owning player we can just get this wall sliding.

And this is the condition.

If we are all sliding while we're falling, we can transition to this animation and we can just copy

this and put in a condition for going back to falling as well.

So here we just put in the opposite is not boolean.

Just put in the opposite and connect this here.

So if we can wall slide from falling we go in here.

And if the wall slide is going back we just go back to falling.

And from falling we can go back to idle to run to everything else.

Let's just try this out.

Compile and save and go here.

And I'm holding towards the wall.

I'm jumping and you can see where I'm playing the animation.

The position is not correct yet, but the animation is playing.

There is one more problem though is that the animation doesn't reset under certain circumstances.

And this is because in the logic, I have to add one more thing.

Sorry about that.

In the BP player here we set the is.all sliding to false.

This is correct, but we also in the drywall slide function.

And also here if the is descending or the is holding towards the wall is not true.

We also have to do this here.

So the if this is false we also set the is wall sliding back to false.

And this should fix the animation issue which we just had.

Right.

Let me try again I go in here.

Yeah I let go.

And now we can switch between the wall slide animation and not having the wall slide animation.

And the next thing we want to do is to just move the animation a little bit over to the side.

So we are right at the wall.

And this is actually something a little bit tricky for wall slide animations, because the person that

drew the animations doesn't know how thick your collision is, so they cannot actually center this for

you because it is dependent on the thickness of your collision capsule.

So we can actually adjust this in the engine.

To do this we go to our content draw to content paper assets, the characters player, and we need to

look at our frames.

And we can just look for a slide here.

And we have the wall slide.

This one right wall slide zero.

Just double click to open it up.

And we can set the pivot position here.

I think we talked about this before and how this can be useful.

Well now is the time where it comes in handy.

So instead of having center center which is this position, we actually want to move it over.

And none of these presets work for us.

So we actually want to go for custom.

And here on the X we want to change it.

But this one actually doesn't really update.

If we just do like this.

We actually have to let go of the button.

And I think we want to go closer to the wall.

Right.

So we want to go to the left here.

And I think during testing I found that 17 is the right value.

So this puts us closer to the wall.

And let's just try this out.

And this is all we have to do here.

This already applies to the flipbook to our animation graph.

Everything just changing this on the sprite.

And let's try this out.

And yes so now this aligns perfectly with the wall.

So how did I find this value.

Well I just saw that we are too far away from the wall.

I just made the pivot go over to the side and then I just tried until I found a value that makes sense.

And now we have to do the same for the shooting animation while sliding, right?

So if I go here and I shoot while sliding, we kind of pop off of the wall because we need to also adjust

this here.

So back here for the, uh, wall slide shoot.

We also need to go to custom, and I think here as well, we just try 17 of the same value works.

It should probably work and go in here and I shoot and.

Yes.

So you see the bullet is hitting the wall.

This is still a problem we have to take care of.

But the animation doesn't pop.

We are sliding down the wall.

It is in the correct position.

And now we can just save all.

Just save all.

We can close down these sprites and.

Yeah.

So the pivot mode can be very useful for things like this.

Let's quickly take care of the issue with the shooting.

So we are shooting to the left side now even though the gun is on the right side.

And we can just go to the player and we already have the shoot position here, right?

So we want to create a second shoot position that we can use.

First.

We just want to copy paste this so we can just right click and duplicate.

And I'm going to call this shoot POS wall slide like this.

And we now need to look at the wall slide animation so we can again use our trick from before.

Go to sprite.

And instead of the idle we just look for wall slide and actually wall slide shoot.

And we can see that it's looking towards the left.

And this is actually a trick I used because if you have the wall slide, look towards the right.

You actually have to flip the entire character when you wall slide, which again can cause issues with

physics and all those kind of things.

So I actually had the wall slide animation look towards the left in the sprite sheet because this makes

it a lot easier.

Now we just want to adjust this shoot pos wall slide.

Just drag it over here it is the same height, but we also need to change the rotation.

So here on the Z we can rotate like this right.

And I know the exact opposite is 180.

So we can just type in 180 here.

And you see the shooting should then follow this red arrow.

Yeah we are in the good position.

This is fine.

Right.

So these are in opposite directions now.

And this is working fine.

Now we just want to set the sprite back to idle player.

Player idle.

So this is working.

We have our two positions.

And now we simply need to pick between these two positions depending on if we're wall sliding or not.

And where do we pick this uh, when we are shooting.

So in the functions shooting we have the spawn projectile.

Right.

And here for the.

Yeah, the world location and rotation.

We get this from the shoot position and we can actually simplify this a little bit.

So instead of using world location and rotation, we can just drag off here and get World Transform

like this.

And here we can use a select.

So here select.

Utilities select and the condition is is wall sliding.

So get is wall sliding.

Or we can also grab it here from our variables and put this in as the condition.

So if we are not wall sliding false we want the position from the shoot position.

And if we are wall sliding we want it from the shoot position wall slide right.

And then from the transform we only want to use the location and rotation.

So here we can just split the struct pin and just put in the location the rotation.

And we don't want to use the scale like we talked about before multiple times.

And this is just a simple select with branching logic.

So we can flip between these two positions.

And let's check this out.

Compile and save I shoot it still works.

I shoot while wall sliding and it shoots to the other side.

And this is how we fix this problem.

Now that the animations are working, let's work on the jump itself.

If we go to the beep player and we have our IA jump, well, we can just look for it here.

IA jump to find it quicker.

And here we have the IA jump.

So what happens here is if we press the button we jump.

But one thing that is very important, if I press jump again while in the air, we cannot jump again.

One thing about this jump note is that it actually behind the scenes checks for can jump, which is

another function in the character.

And this is false if we try to jump again while being airborne.

And the thing is that with our sliding we count as airborne.

So even if we want to jump here again, we cannot jump.

So what we need to do here is instead of jumping, use the launch character like we did for the knockback

because this one also works while we are airborne.

Now there are a couple of tricks to implement double jumps and those kind of things, but I think in

this case the launch character is a cleaner and better solution.

So now we want to implement some branching logic here.

So here from start it very important make a branch like this.

And we can simply check for is wall jumping.

Is wall sliding?

Is wall sliding right.

And if this is true then we actually want to do this the opposite way.

So just hold Ctrl and pull this here.

So if we are not wall sliding we just want to jump normally this is fine.

And if we are wall sliding then we want to use our launch character node instead.

So here just launch character.

Like this and just drag it over.

And for now, just, uh, split this up, split this drug bin, and at first, just put in the upward,

uh, velocity.

So this 1500, maybe upward.

And let's just try how this works.

Go here.

Right.

So I can jump.

Normally I cannot jump in the air, but if I'm wall sliding I can jump again.

And in some games this is all the wall jumping does, right?

You can just jump straight.

But I think in our game and in a lot of games, you actually want to jump away from the wall.

So up and away, because otherwise a wall jumping is just a bit trivial.

Right.

So everybody can do this.

There's not much skill involved.

It is a lot of fun still.

And if you want to make your game that way, that is fine.

But I actually want to implement a jumping up and away from the wall.

So back in the BP player this is fine.

The launch velocity upward is fine, but we also want to have a launch velocity on x in the opposite

direction of where we are looking, right.

So we can get actor forward vector.

Again.

This gives us the forward direction.

And again we only care about the x.

So we can split the struct pin.

And the x is going to give us minus one for left and one for right.

But since we want to go in the opposite direction, we want to multiply this.

So multiply by minus one.

So this is always going to flip it around.

But this will only give us the direction.

So we actually want to multiply again by the power of the jump.

So let's just say 5000 something crazy just to try it out and put this in for the X.

Right.

So this gives us the direction it's going to flip the direction around.

And this just adds the power of the jump in the x direction.

So it is compiled safe.

Check this out.

And yes so we jump to the other side.

But actually it is not as strong as you would think.

And the problem with this is again we have the lateral falling friction.

So on the character movement component the lateral the falling lateral friction again is kind of causing

issues with this.

So again we have to put in a little bit of a workaround here.

So here, before the launch character again, we just set our lateral falling friction on the character

movement component.

Set lateral falling friction to zero.

Open up some space here like this.

And connect this here.

Right?

So this is gonna solve our problem on first glance, right?

So we properly jump to the other side.

And 5000 is actually a little bit of a crazy value, as you can see, because we get bounced around.

But this solved the problem with the falling ladder friction.

We of course also have to set it back to the original value again after a set amount of time, but this

is one step in the right direction.

So first we want to implement the delay.

So here we put in a retrigger delay again.

Like this.

And first just yeah, leave it at 0.2 and we set the lateral falling friction back to our base value.

And we saved this before and begin play.

We have the base lateral friction value.

And we can just drag this in here right.

So I go like this.

Now I do the wall jump once and we get flung away.

But now I'm back to my regular value.

And I have the air control that we set up right in the beginning.

But the value for the wall jump is way too high, right?

So 5000 is crazy.

So just put it at 1000.

For now, put it at 1000 and see how this feels.

And.

Yeah, this is really nice, right?

These are the kind of wall jumps you see in these games.

Right.

And it makes sure that if we set the lateral friction, it also lets us fly long in the direction we

cannot steer against it so hard.

And it has kind of a fixed direction, which is really nice.

But we also want to make sure it's always the same.

So x, y, z override.

Uh, turn this on just to make sure it's more consistent.

It's not affected by the momentum we already have.

And this just makes it a little bit more consistent.

And now all of this is working.

We just want to clean it up a little bit.

So stop the gameplay and a couple of these variables.

Right.

So this is the horizontal jump power for wall jumping right.

So we can promote the variable and just call it wall jump power.

Port.

For voice and power.

Horizontal compound safe.

And the default value is 1000.

Right?

This is correct.

This is minus one.

This doesn't need to be a variable.

This is kind of obvious what is happening here.

We just flip this around.

And here the 1500, the upward velocity.

We can also do this and promote the variable and call the wall jump power vert.

And put this here compile and save.

And this is just best practice.

So you can just easily update this.

You don't have to just like look through your code every time.

And the last thing I want to put into a variable is the retrigger delay.

So here.

Promote the variable and just call this wall jump.

Lock.

Like this.

And this is all it takes to make the wall jump work.

But let's just collapse these nodes now, right?

We cannot collapse this to a function because we have a delay in here.

So we can just select these.

And just collapse the nodes.

Collapse nodes and just called wall jump.

And now this is again very easy to understand.

We just check for is wall jumping.

Is wall sliding?

If yes, then we can wall jump.

If not, just try to jump regularly.

And then in here we have all of our logic encapsulated.

So congrats!

You just created a wall slide and a wall jump, which is a somewhat advanced, uh, gameplay ability.

And I hope the problem solving skills, the blueprint skills that you learned here, you will be able

to apply them to other things as well.

Next up is the ground slide.

Can't find what you're looking for?
Get subtitles in any language from opensubtitles.com, and translate them here.