[Mod] Another Knockback Mod [knockback]

User avatar
Lone_Wolf
Member
 
Posts: 2201
Joined: Sun Apr 09, 2017 05:50
Location: Hopefully very far from yours, snoop :P
GitHub: LoneWolfHT
IRC: Lone_Wolf
In-game: Lone_Wolf

[Mod] Another Knockback Mod [knockback]

by Lone_Wolf » Wed May 29, 2019 16:04

Knockback
A knockback mod that uses RayCast() and move_to() to fling the player backwards. No entities


View on Github: https://github.com/LoneWolfHT/knockback
Downloads: Latest Stable

Current 'Bugs':
  • Movement looks a little jerky to the player being hit. The fix would be pretty laggy

A few test players were harmed a couple hundred times during the making of this mod
Last edited by Lone_Wolf on Wed May 29, 2019 23:11, edited 1 time in total.
 

User avatar
Joseph16
Member
 
Posts: 308
Joined: Tue Dec 06, 2016 05:35
In-game: Joseph16

Re: [Mod] Another Knockback Mod [knockback]

by Joseph16 » Wed May 29, 2019 16:06

A few test players were harmed a couple hundred times during the making of this mod.....
Me and my brother tested this and I can confirm this to be true
Testin' mines since 1989
 

User avatar
Joseph16
Member
 
Posts: 308
Joined: Tue Dec 06, 2016 05:35
In-game: Joseph16

Re: [Mod] Another Knockback Mod [knockback]

by Joseph16 » Wed May 29, 2019 16:43

setting dir.y to 0 has no effect. Also, it is set to 0 by default when you get the mod.
Testin' mines since 1989
 

User avatar
Lone_Wolf
Member
 
Posts: 2201
Joined: Sun Apr 09, 2017 05:50
Location: Hopefully very far from yours, snoop :P
GitHub: LoneWolfHT
IRC: Lone_Wolf
In-game: Lone_Wolf

Re: [Mod] Another Knockback Mod [knockback]

by Lone_Wolf » Wed May 29, 2019 18:48

Joseph13 wrote:setting dir.y to 0 has no effect. Also, it is set to 0 by default when you get the mod.

Replace lines 9 to 11 with dir.y = 0

https://github.com/LoneWolfHT/knockback ... nit.lua#L9
 

User avatar
Joseph16
Member
 
Posts: 308
Joined: Tue Dec 06, 2016 05:35
In-game: Joseph16
 

User avatar
Lone_Wolf
Member
 
Posts: 2201
Joined: Sun Apr 09, 2017 05:50
Location: Hopefully very far from yours, snoop :P
GitHub: LoneWolfHT
IRC: Lone_Wolf
In-game: Lone_Wolf
 

User avatar
Joseph16
Member
 
Posts: 308
Joined: Tue Dec 06, 2016 05:35
In-game: Joseph16

Re: [Mod] Another Knockback Mod [knockback]

by Joseph16 » Wed May 29, 2019 21:36

Already tried that and it has barely any effect at all. If I set it to 0 it makes the player go under the ground by a block.
Testin' mines since 1989
 

User avatar
Lone_Wolf
Member
 
Posts: 2201
Joined: Sun Apr 09, 2017 05:50
Location: Hopefully very far from yours, snoop :P
GitHub: LoneWolfHT
IRC: Lone_Wolf
In-game: Lone_Wolf

Re: [Mod] Another Knockback Mod [knockback]

by Lone_Wolf » Wed May 29, 2019 21:48

Joseph13 wrote:Already tried that and it has barely any effect at all. If I set it to 0 it makes the player go under the ground by a block.

It worked for me
Changing the y movement to 0 won't fix the jerkiness. The player is being teleported a small distance away from their attacker
 

User avatar
Joseph16
Member
 
Posts: 308
Joined: Tue Dec 06, 2016 05:35
In-game: Joseph16

Re: [Mod] Another Knockback Mod [knockback]

by Joseph16 » Wed May 29, 2019 22:48

Yeah, I will just leave it as it is. Hopefully when the devs make knockback an official thing it will be less jerky.
Testin' mines since 1989
 

User avatar
Joseph16
Member
 
Posts: 308
Joined: Tue Dec 06, 2016 05:35
In-game: Joseph16

Re: [Mod] Another Knockback Mod [knockback]

by Joseph16 » Thu May 30, 2019 13:02

Would It be possible to get the velocity of the puncher and also use that for knockback? Like if the puncher is walking towards the player getting hit then it does a lot more knockback?
Testin' mines since 1989
 

User avatar
Lone_Wolf
Member
 
Posts: 2201
Joined: Sun Apr 09, 2017 05:50
Location: Hopefully very far from yours, snoop :P
GitHub: LoneWolfHT
IRC: Lone_Wolf
In-game: Lone_Wolf

Re: [Mod] Another Knockback Mod [knockback]

by Lone_Wolf » Thu May 30, 2019 15:27

Joseph13 wrote:Would It be possible to get the velocity of the puncher and also use that for knockback? Like if the puncher is walking towards the player getting hit then it does a lot more knockback?

I don't think that would work too well. In PvP players are usually always moving. So I might as well just increase the knock back a little
 

User avatar
Joseph16
Member
 
Posts: 308
Joined: Tue Dec 06, 2016 05:35
In-game: Joseph16
 


Return to WIP Mods



Who is online

Users browsing this forum: No registered users and 12 guests