Learn how to make a Roblox Game - Roblox combat system Knockbacks and Endlag (episode 7)

Learn How To Make A Roblox Game - Roblox Combat System Knockbacks And Endlag (Episode 7)

Hey guys welcome back to the Roblox Combat series. Today we're going to be making locking and unlock case so we're gonna be making an app first

I can't if not if not combo able to defy them then else CASP so it's gonna be so it's gonna change so it's going to change on how long the attacking attribute is going to be removed. If the combo is not five, then it's going to be removed in quantity five seconds, the attacking attribute is the combo is five then the delay the amount of time where the attribute gets deleted is much longer. So I'm going to make the cooldown two seconds. So basically it checks your funk ejection combo and if your combo isn't five and the cooldown will be normal function function function function okay then God should work one oh if not try if although is smaller than five See, that's wrong wrong something smaller than five. Okay, let's see if this works. Yeah, and once it gets it gets to five the cooldown gets longer so there's a lag equals on this one okay. Okay. I want it so my character gets slowed down um humanoid, humanoid Walk Speed it was was not defined. Let's define the local humanoid to that humanoid robot speed equals five and we're gonna change this to 16 once once the analog is run once the cooldown is over 16 Since the default speed is 16

so yeah

take it slow down. Okay. But I don't know I don't want to get slowed down immediately. So what I'm going to do is I'm going to wait like task dot wait point 16 seconds and then I can slow down since it's mostly done reading fast I mean make it so it's point 20 seconds for punching Okay, that's perfect now so once you start attacking, it's going to check you for combo is smaller than five. If it is then the cooldown will be normal. If it's not then the cooldown will be longer and you're going to get slower. Okay. I'm going to try to make it so it seems your default was speeding. me let me try to a fault speed equals humanoid speed. Change Okay

12345 I guess slow down and then it should turn to sunny again. Yeah, it works. Okay, that's nice. Let's move on with the print key now we're gonna be making the knockbacks so we're gonna be using what it vlocity But first let me know how to work slightly by adding the body velocity manually. So we're going to be adding the body philosophy if you read before, but if glossy this was about looking into body glossy, okay, we're gonna make the Maxforce a lot like 800 1000 but someone said that the best Max mapsource Use the smoothest use is like eight ie five I don't know why they said so. So I'm going to stress them and

then change the velocity to drop them in what is not working or is it anchored? Okay, so this is what's happening, but it's not going to be

okay, so what we're going to do is we're going to put this but it was three insert module and then it's going to get them moved like in 1.1 second let me change the world it was complete a try so I'm gonna simulate what's gonna happen in the script wouldn't water Colossi inbox and it's going to get so that's my that's going to be that's what I'm going to recreate that inside the script we're going to add the blood of glossy jeans to Maxforce into eight EFI and then change the velocity to the direction on your character spacing. And we're gonna multiply it by the symbol right so once you get happy we're gonna make um, we're gonna we're going to add one o'clock but what I want to do is I want to make the knock back photo, if it's the last one. So I think I'm gonna make a function for this. Yeah, I think I'm gonna make a function does local function so so the script is

local function not the target target humanoid in the velocity okay. Local BV equals concern starting last week we're gonna be making the border crossing body velocity. So we're going to be doing the same thing as I did earlier.

Like when I added buddy velocity manually and what's going to happen, then change the max force Max force. But if you don't you eat a fight. Someone said it's the best Maxforce because it feels good. I'm not sure if it's true, but I'm going to interesting down we're going to change the velocity to philosophy because philosophy then we're going to remove the body velocity in one second give it to be an item. But if last one so this is going to move the body glossy input one second. Okay, then we check if the combo is 500 to check the combo if combo is more than five, and Rawson was smoking Five, then we're going to be making the velocity back. Issue issue, we're going to be making the velocity lower. Key when I are here, right? After I think we have we already have a variable for our part. Actually, no, we don't. Okay, you might have looked at them. So it's the direction the character is facing. We're going to be using the our direction. Now we're going to multiply it. So it's basically are the velocities. And it's relative to the direction. Okay, if it's not 10, it says, if the combo is fine, then we're going to be making the velocity into 10. Point I mean it's going to use our direction and it's gonna make the velocity 100. Less let's see if this works. If that's not an OT, O error. Let's see. Look, Dr. E o, on it's put in a C frame supposed to meet up to par dot c frame C frame the look at

basically carrying the direction and then most people by chance I think they should work now. Okay, we're gonna meet non blocking. Okay. Oh, yeah, the human is on the unencrypt it should work now. Let's see if this works Oh, it doesn't work. Why isn't it working? All you haven't counted it? Oh, yeah, we haven't changed. Oh, my bad, my bad. It's a plum to parent.

Parent equals target him, doctor. Now they won't send the parent so they should. I hope it's not anchored. It is. It works. I don't know why it's a bit like works. Someone said that. It's going to be laggy in the studio, but it's not going to be like Indian. I don't know if it's true. I haven't tested on it. I haven't tested it in game I have only tested into what if it doesn't work then you should probably use C framing a kinking the C free manual. That's going to be really hard because it's going to go through walls. So you're going to have to check if the humanoid is eating or not was going to be a huge pain. Body velocity is way easier

okay, it was pretty fun to play for fun. Blocking books. The animation is good stuff was fine, fine, I guess. If this is for this video, it's a pretty short view. I hope you understand see you next time...