Raised This Month: $32 Target: $400
 8% 

Block player stopped when take damage.


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
FromTheFuture
Senior Member
Join Date: Jan 2013
Old 09-02-2014 , 14:41   Block player stopped when take damage.
Reply With Quote #1

Hi. How to block the stop when player take a damage?
I think about pev_maxspeed.
FromTheFuture is offline
zmd94
Veteran Member
Join Date: Nov 2013
Location: Malaysia (9w2zow).
Old 09-02-2014 , 19:50   Re: Block player stopped when take damage.
Reply With Quote #2

What do you mean? Do you want that when someone is taking a damage, he cannot stop? If he stop, he will automatically moving to somewhere?
zmd94 is offline
yokomo
Surprise Ascot!
Join Date: May 2010
Location: Malaysia
Old 09-03-2014 , 01:18   Re: Block player stopped when take damage.
Reply With Quote #3

This called painshock free. See ZP code on Ham_TakeDamage POST forward, you will find it method.
__________________
Team-MMG CS1.6 Servers:
✅ MultiMod -- 103.179.44.152:27016
✅ Zombie Plague -- 103.179.44.152:27015
✅ Zombie Escape -- 103.179.44.152:27017
✅ Klassik Kombat -- 103.179.44.152:27018
✅ Boss-Battle -- 103.179.44.152:27019

Last edited by yokomo; 09-03-2014 at 01:20.
yokomo is offline
FromTheFuture
Senior Member
Join Date: Jan 2013
Old 09-03-2014 , 15:34   Re: Block player stopped when take damage.
Reply With Quote #4

Quote:
Originally Posted by yokomo View Post
This called painshock free. See ZP code on Ham_TakeDamage POST forward, you will find it method.
Thank You, but I found it here https://forums.alliedmods.net/showpo...3&postcount=16
FromTheFuture is offline
colossus
Member
Join Date: Sep 2013
Old 09-03-2014 , 15:55   Re: Block player stopped when take damage.
Reply With Quote #5

PHP Code:
/* Plugin generated by AMXX-Studio */

#include <amxmodx>
#include <hamsandwich>

public plugin_init()
{
    
register_plugin("Block Damage Shock""1.0""colossus")
    
RegisterHam(Ham_TraceAttack"player""fw_TraceAttack")
}

public 
fw_TraceAttack(victimattackerFloat:damageFloat:direction[3], tracehandledamage_type)
    return (!(
<= victim <= get_maxplayers() && is_user_connected(victim))) ? HAM_IGNORED HAM_SUPERCEDE 
Test!!

Last edited by colossus; 09-03-2014 at 15:56.
colossus is offline
alan_el_more
Veteran Member
Join Date: Jul 2008
Location: amxmodx-es.com
Old 09-03-2014 , 17:35   Re: Block player stopped when take damage.
Reply With Quote #6

PHP Code:
#include <amxmodx>
#include <fakemeta>
#include <hamsandwich>

const OFFSET_PAINSHOCK 108
const OFFSET_LINUX 5

public plugin_init ()
{
register_plugin
"Pain Shock Free" "0.1" "alan_el_more" )
RegisterHam
Ham_TakeDamage "player" "fw_TakeDamage_Post" )
}

public 
fw_TakeDamage_Post
victim)
{
set_pdata_float
victimOFFSET_PAINSHOCK 1.0 OFFSET_LINUX )

__________________
alan_el_more is offline
Unkolix
Veteran Member
Join Date: Sep 2012
Old 09-05-2014 , 09:09   Re: Block player stopped when take damage.
Reply With Quote #7

Quote:
Originally Posted by zmd94 View Post
What do you mean? Do you want that when someone is taking a damage, he cannot stop? If he stop, he will automatically moving to somewhere?
Nope. You know that moment when you get hit by a bullet and you get slowed? That's what he wants to get rid of.
Unkolix is offline
zmd94
Veteran Member
Join Date: Nov 2013
Location: Malaysia (9w2zow).
Old 09-05-2014 , 09:48   Re: Block player stopped when take damage.
Reply With Quote #8

Quote:
Originally Posted by Unkolix View Post
Nope. You know that moment when you get hit by a bullet and you get slowed? That's what he wants to get rid of.
Now, I got it. ;)
zmd94 is offline
HamletEagle
AMX Mod X Plugin Approver
Join Date: Sep 2013
Location: Romania
Old 09-05-2014 , 11:25   Re: Block player stopped when take damage.
Reply With Quote #9

Then setting m_flPainShock offset to 0 is the best way to do it.
__________________
HamletEagle is offline
FromTheFuture
Senior Member
Join Date: Jan 2013
Old 09-05-2014 , 11:30   Re: Block player stopped when take damage.
Reply With Quote #10

I do it with set_pdata_float(id, m_flVelocityModifier, 1.0);
FromTheFuture is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 03:05.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode